mirror of
https://github.com/firestar5683/StarPilot.git
synced 2026-11-06 20:43:46 +08:00
22a8575199
Keep official openpilot ancestry and dependency licenses. Store resources directly in Git, remove LFS setup requirements, and leave the downloadable big model outside the source tree.
19 lines
365 B
C
19 lines
365 B
C
#pragma once
|
|
|
|
#include "board/sys/sys.h"
|
|
|
|
// ********************* Critical section helpers *********************
|
|
uint8_t global_critical_depth = 0U;
|
|
|
|
static volatile bool interrupts_enabled = false;
|
|
|
|
void enable_interrupts(void) {
|
|
interrupts_enabled = true;
|
|
__enable_irq();
|
|
}
|
|
|
|
void disable_interrupts(void) {
|
|
interrupts_enabled = false;
|
|
__disable_irq();
|
|
}
|