stm32: Add support for stm32f070x6 mcus

This mcu has smaller memory and may require remapping of PA11/PA12.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
This commit is contained in:
Kevin O'Connor
2025-01-28 18:37:29 -05:00
parent bf5c4daf86
commit 1fc6d214f4
2 changed files with 13 additions and 9 deletions

View File

@@ -186,10 +186,8 @@ armcm_main(void)
hsi14_setup();
// Support pin remapping USB/CAN pins on low pinout stm32f042
#ifdef SYSCFG_CFGR1_PA11_PA12_RMP
if (CONFIG_STM32_USB_PA11_PA12_REMAP || CONFIG_STM32_CANBUS_PA11_PA12_REMAP)
SYSCFG->CFGR1 |= SYSCFG_CFGR1_PA11_PA12_RMP;
#endif
SYSCFG->CFGR1 |= 1<<4; // SYSCFG_CFGR1_PA11_PA12_RMP
sched_main();
}