wiki:TBR/BSP/STM32F105

Version 1 (modified by Jmfriedt, on Aug 17, 2014 at 9:10:43 PM) (diff)

Created page with "The STM32F105 BSP, based on the STM32F4 BSP, is compiled according to http://alanstechnotes.blogspot.fr/2013/03/setting-up-rtems-development.html Having compiled the toolcha..."

STM32F105

The STM32F105 BSP, based on the STM32F4 BSP, is compiled according to http://alanstechnotes.blogspot.fr/2013/03/setting-up-rtems-development.html

Having compiled the toolchain, RTEMS is compiled for the STM32F105 BSP following http://s937484.blogspot.fr/2013/10/rtems-stm32f407-discovery-board-posted.html

We run the example on Qemu supporting the STM32 architecture as described at: https://github.com/beckus/qemu_stm32

The trick is that, as indicated at ftp://ftp.rtems.eu/pub/rrr/RRR_Quick_Start_Guide_en.pdf, the console is connected to UART3. Qemu as found on the previous GIT site only implements UART2: edit hw/arm/stm32_p103.c to add both UART1 and UART3 by including

DeviceState? *uart1 = DEVICE(object_resolve_path("/machine/stm32/uart[1]", NULL)); DeviceState? *uart3 = DEVICE(object_resolve_path("/machine/stm32/uart[3]", NULL)); assert(uart1); assert(uart3); stm32_uart_connect((Stm32Uart *)uart1,serial_hds[0],STM32_USART1_NO_REMAP); stm32_uart_connect((Stm32Uart *)uart3,serial_hds[2],STM32_USART3_NO_REMAP);

having compiled Qemu with these updates, and RTEMS for the STM32F105 BSP, the example is loaded using

qemu-system-arm -M stm32-p103 -serial stdio -serial stdio -serial stdio -kernel hello.bin

(three times -serial stdio to indicate that all three UARTs outputs are displayed on stdout). The result is VNC server running on `::1:5900' LED Off

  • BEGIN OF TEST HELLO WORLD *

Hello World

  • END OF TEST HELLO WORLD *