openpilot is an open source driver assistance system. openpilot performs the functions of Automated Lane Centering and Adaptive Cruise Control for over 200 supported car makes and models.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

15 lines
502 B

// Early bringup
extern void *g_pfnVectors;
extern uint32_t enter_bootloader_mode;
void early_initialization(void) {
SystemInit();
// after it's been in the bootloader, things are initted differently, so we reset
if ((enter_bootloader_mode != BOOT_NORMAL) &&
(enter_bootloader_mode != ENTER_SOFTLOADER_MAGIC)) {
enter_bootloader_mode = BOOT_NORMAL;
NVIC_SystemReset();
}
// setup interrupt table
SCB->VTOR = (uint32_t)&g_pfnVectors; // TODO: check if SystemInit is enough!
}