Skip to content

Latest commit

 

History

History

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 

STM32 Board Development

The onboard embedded systems in the Gen 5 solar car is done using the STM32F4 Discovery Boards. To develop on these boards, two tools are necessary. The the STM32 System Workbench and the STM32CubeMX, the first is an IDE that comes with the toolchain to compile for the STM32 boards, the second is a code generator for initialization code on STM32 boards.

STM32CubeMX

You can download the STM32CubeMX code generator here. The download link is at the bottom.

  1. Unzip the file and run the installer for your OS, in some linux distributions you will need to run the windows installer using java -jar

  2. In the installer hit next for everything, all the defaults are fine

  3. Create a new project

  4. Go to the Board Selector tab

  5. Under Vendor select STMicroElectronics

  6. Under Type of Board select Discovery

  7. Under MCU Series select STM32F4

  8. Then select the STM32F4DISCOVERY board

  9. At the top go to Project→Generate Code

  10. Pick a project name, and select the toolchain SW4STM32 Toolchain, then click OK

  11. Click yes to download the firmware

You have now generated the code, you can now copy the source and header files into a STM32 System Workbench project. Do not use the generated project from STM32CubeMX. You will need to delete the MSP template file and add mxconstants.h to main.c.