#ifndef ARCH_H_ #define ARCH_H_ #ifndef ARCH_STM32L4 #define ARCH_STM32L4 #endif #define CORTEX_M4 #define enable_interrupts() \ asm volatile(" cpsie i ") #define DMA1_BASE (0x40020000) #define DMA2_BASE (0x40020400) #define USART1_BASE (0x40013800) #define USART2_BASE (0x40004400) #define GPIOA_BASE (0x48000000) #define GPIOB_BASE (0x48000400) #define GPIOC_BASE (0x48000800) #define SRAM1_BASE (0x20000000) #define SRAM2_BASE (0x2000C000) #define SYSTEM_CONFIG_BLOCK_BASE (0xE000E008) #include #ifndef DRY_RUN _Static_assert(sizeof(void*) == sizeof(uint32_t), "Pointers must be 32 bits"); #endif #endif /* ARCH_H_ */