Using mbed with generic STM32 boards from eBay
Using mbed with generic STM32 boards
Overview
There's nothing amazing here, just some notes about how you would go about using mbed to compile programs that you can run on those generic STM32 boards you can find all over the Internet. Step one obviously, is to buy one. Here, I'm, using an old revision 1.1 version of Guan Fu Wang's STM32 digital camera development board. Originally meant to mate with various Omnivision camera modules, it also features a MicroSD card slot and a 2.8" TFT display on the back of the board, connected to the MCU in 8-bit mode, and the touchpanel is interfaced via an XPT2046 touchpanel controller. It has one user push button switch and one user controllable LED. The board is powered via USB.
As it happens, it would seem that nearly all the low cost STM32 board on eBay seem to use the same MCU - the STM32F103RBT6. This is brilliant news because it means you can use the STM Nucleo F103RB platform as your selected compile target. If your particular board doesn't have this specific MCU, you'll have to see if it has a similar MCU to any of the other Nucleo boards.
Step 2 is you need the schematic for the board you intend to use of course.
Finally, you need a JTAG or SWD programmer like this one from Olimex or perhaps the ST-Link programmer built into any STM32 Discovery board, and of course you will need to use regular, JTAG/SWD programming procedures, and you will not have mbed's unique drag and drop programming facility, but it won't be a big issue.
Programmer Settings
Need to use a starting address of 0x8000000.
Generic GPIO Pin Names
In order to interface your vanilla STM32F103 board with something, you won't be able to use the Arduino-style labelled pin names on the Nucleo board. You can instead use the original pin names on the STM32 which are as follows:
- Port A: PA_0 .. PA_15
- Port B: PB_0 .. PB_15
- Port C: PC_0 .. PC_15
- Port D: PD_0 .. PD_2
3 comments on Using mbed with generic STM32 boards from eBay:
Please log in to post comments.
Thanks for sharing the tip. These cheap STM32 boards are really convenient nowadays! :)