I got an STM32L discovery board that contains an stm32l152rb microprocessor. I try to program that board in assembly without any library at all. So far I succeeded in writing linker scripts and a basic routine that copies the .data section into the RAM and zeroes out the bss section. But apart from that I am a little bit lost.
As a tiny experiment to understand how configuring GPIo works, I want to make a program for the board that lights the green LED connected to GPIO port B, pin 7. Reading the datasheet, I conclude that I need to do the following two things:
- Configure GPIO port B, pin 7 as an output pin
- Set said pin to high
But at this place, I figuratively don't see the forest for the trees. I am not sure which of the multiple IO modes avaible I should choose and all these acronyms confuse me. I would really appreciate somebody giving me detailed information, instruction and possibly example assembly on how to do this.