Using Photon as SPI master to control STM32F051(ARM-m0)

Hi I got a STM32F0 discovery board to play with. I connected it(slave) to photon(master) and was trying to use SPI to turn on an LED that was connected to PC6 of STM32. The STM is not connected to any IDE so the only way to talk to it is through SPI from photon.

I understand in order to do that I need to configure a bunch of registers of STM but question is how to do that through SPI messages?

Here’s the reference manual for STM32F0xx.

Do you know what firmware is running on that dev kit?
How would you send SPI messages to a device that’s not posing as SPI slave?

While we can definetly help you with the Photon side of your question, the STM32F051 is not really the focus of this community. While we might be able to find out how you’d flash custom firmware to that STM32F0 board or what the default firmware provides to achieve what you want, we still have to “investigate” that the same way as you’d need to.

Thanks for the reply. The STM32 is posing as a slave. After lots of research I decided to change to another approach. That is coding on STM32 using its own IDE so that it will execute certain commands depends on the data it receives from photon, instead of trying to use SPI to control literally everything. Still testing but hopefully it will work out.