Starting to log progress of this project today.

I decided to use Eclipse and setup GCC as a compiler. I'm using openocd for debug. Some of the following links have been helpful in getting started:

http://www.carminenoviello.com/en/2014/12/28/setting-gcceclipse-toolchain-stm32nucleo-part-1/  (specific to Nucleo)

https://community.particle.io/t/tutorial-using-eclipse-st-link-v2-openocd-to-debug/10042 (more info about setting up the debugger)

http://www.carminenoviello.com/en/2015/01/07/setting-gcceclipse-toolchain-stm32nucleo-part-2/ — good debugger setup info (openocd)


Next I soldered on an 8MHz crystal and used STM32CubeMX software to generate the proper code to initialize the clock. Finding the right settings for a given crystal can take awhile, so I wrote a matlab program to find the correct settings for me (/code/clock_tree_calculation.m).

For an 8MHz crystal I found the following settings would give me an 84MHz clock: m,n,p,q = 5, 210, 4, 7

Update from the future: I have since learned that the STM32CubeMX software will  do this calculation automatically.


While I had STM32CubeMX opened I spent some time turning on different modules to see how I might want to layout the pin definitions. It was very helpful to see which modules have conflicts. This is the pin layout I ended up with:

Finally, I wired up the NUCLEO board to an SD card socket from a ferminator2000 board (only the sd card socket is populated). I used 10k pull-up resistors on each line and I kept each wire as short as possible. Below are my wiring notes: