I am using STM32F103C8 board for learning ARM cortex M3. I am new to this MCU.
Till now I have worked directly on MCU registers, (PIC, ATMEL, ARM7) like if I have to set some value to port, then I have used GPIOx_ODR=0x0000; like wise.
To do same I need start up file for STM32F103C8 MCU.
I have downloaded projects from online. That are working, but not defined with GPIOx_ODR this type of register names.
I have to use register names that are given in datasheet directly.
Kindly help me.
I dont have to use HAL library.
Via CMSIS level includes/structures
GPIOC->ODR ^= (1 << 2); // Toggle PC2
You'd need to enable the GPIO clock in the RCC, and then configure it as an output first
RCC->APB2ENR |= (1 << 4); // Enable GPIOC clock
View all questions in Arm Development Studio forum