Posts

Showing posts with the label STM32 code for beginners

Writing code for the STM32

Writing Code for the STM32F Introduction Following my previous post on setting a project and all the necessary files for an STM32F, I will now guide you to setup the code that needs to be written. In case you get lost in the steps below please refer to the following post Introduction to STM32F   All the code will be placed in the files which were created in Introduction to STM32F  will be reused here. Before we start writing any code, first you need to understand how everything will be structured. Below is a summary of how the code will be organized:   Preparing to write the code In order to code the STM32F C programming language will be used. In C programming language we don't write all the code in a continuous set of lines in a single file. This makes the code difficult to maintain and re-use. The proper way to proceed is to first decide what the microcontroller needs to do. For this post I will keep things simple I just want to make pin PB8 an output and then ma