Loading src/arch/stm32f446re-nucleo/Makefile.inc +6 −4 Original line number Diff line number Diff line Loading @@ -8,6 +8,9 @@ SERIAL_PORT ?= ttyACM0 cpu_freq ?= 168000000 # counter runs at cpu_freq/2 counter_freq ?= 84000000 INCLUDES += -Iext/libopencm3/include COMMON_FLAGS += --static -nostartfiles -g3 -Os -fno-common Loading Loading @@ -118,7 +121,7 @@ arch_clean: ${QUIET}rm -f ${OBJECTS} cat: ${QUIET}script/cat.py /dev/${SERIAL_PORT} 115200 ${cpu_freq} 65536 ${QUIET}script/cat.py /dev/${SERIAL_PORT} 115200 ${counter_freq} 65536 ${MAKE_CAT_TIMEOUT} monitor: ${QUIET}screen /dev/${SERIAL_PORT} 115200 Loading @@ -130,9 +133,8 @@ arch_help: arch_info: @echo "CPU Freq: ${cpu_freq} Hz" @echo "Timer Freq: ${timer_freq} Hz -> $(shell src/arch/stm32f446re-nucleo/model.py f_timer "${cpu_freq}" "${timer_freq}")" @echo "I2C Freq: ${i2c_freq} Hz" @echo "Counter Overflow: 4294967296/255" @echo "Count Freq: ${counter_freq} Hz" @echo "Counter Overflow: 4294967296/4294967295" @echo "Monitor: /dev/${SERIAL_PORT} 115200" attributes: build/system.elf Loading src/arch/stm32f446re-nucleo/arch.cc +2 −1 Original line number Diff line number Diff line Loading @@ -27,7 +27,7 @@ void Arch::setup(void) #error Unsupported F_CPU #endif // counter #ifdef CONFIG_arch_stm32f446re_nucleo_driver_counter rcc_periph_clock_enable(RCC_TIM2); nvic_enable_irq(NVIC_TIM2_IRQ); rcc_periph_reset_pulse(RST_TIM2); Loading @@ -38,6 +38,7 @@ void Arch::setup(void) timer_continuous_mode(TIM2); timer_set_period(TIM2, 4294967295); timer_enable_irq(TIM2, TIM_DIER_UIE); #endif #ifdef CONFIG_loop rcc_periph_clock_enable(RCC_TIM3); Loading Loading
src/arch/stm32f446re-nucleo/Makefile.inc +6 −4 Original line number Diff line number Diff line Loading @@ -8,6 +8,9 @@ SERIAL_PORT ?= ttyACM0 cpu_freq ?= 168000000 # counter runs at cpu_freq/2 counter_freq ?= 84000000 INCLUDES += -Iext/libopencm3/include COMMON_FLAGS += --static -nostartfiles -g3 -Os -fno-common Loading Loading @@ -118,7 +121,7 @@ arch_clean: ${QUIET}rm -f ${OBJECTS} cat: ${QUIET}script/cat.py /dev/${SERIAL_PORT} 115200 ${cpu_freq} 65536 ${QUIET}script/cat.py /dev/${SERIAL_PORT} 115200 ${counter_freq} 65536 ${MAKE_CAT_TIMEOUT} monitor: ${QUIET}screen /dev/${SERIAL_PORT} 115200 Loading @@ -130,9 +133,8 @@ arch_help: arch_info: @echo "CPU Freq: ${cpu_freq} Hz" @echo "Timer Freq: ${timer_freq} Hz -> $(shell src/arch/stm32f446re-nucleo/model.py f_timer "${cpu_freq}" "${timer_freq}")" @echo "I2C Freq: ${i2c_freq} Hz" @echo "Counter Overflow: 4294967296/255" @echo "Count Freq: ${counter_freq} Hz" @echo "Counter Overflow: 4294967296/4294967295" @echo "Monitor: /dev/${SERIAL_PORT} 115200" attributes: build/system.elf Loading
src/arch/stm32f446re-nucleo/arch.cc +2 −1 Original line number Diff line number Diff line Loading @@ -27,7 +27,7 @@ void Arch::setup(void) #error Unsupported F_CPU #endif // counter #ifdef CONFIG_arch_stm32f446re_nucleo_driver_counter rcc_periph_clock_enable(RCC_TIM2); nvic_enable_irq(NVIC_TIM2_IRQ); rcc_periph_reset_pulse(RST_TIM2); Loading @@ -38,6 +38,7 @@ void Arch::setup(void) timer_continuous_mode(TIM2); timer_set_period(TIM2, 4294967295); timer_enable_irq(TIM2, TIM_DIER_UIE); #endif #ifdef CONFIG_loop rcc_periph_clock_enable(RCC_TIM3); Loading