OpenCR Port manipulation in Arduino

I would like to access the registers of the microcontroller. I have gone through the datasheet and tried to access the pins in opencr board.

I used - GPIOA_BASE -> BSRR = 0b1<<3;

This gives an error "base operand of ‘->’ is not a pointer"
Kindly inform me how to rectify this error. Also inform is it possible to access the pins of opencr by registers in Arduino IDE.

Thanks for your help

Hopefully someone from Robotis will give you a better answer.

It has been awhile since I played with the openCR. I believe most all of this is buried in the Hardware Abstraction Layer.

And for example in their source file for doing things like digitalWrite… There is a comment near the top of the file:

the HAL drivers for STM32 do no access the registers directly
opaque structures are used to abstract the functions needed

existing STM examples show this defined locally a static
‘static GPIO_InitTypeDef GPIO_InitStruct;’

value which we set here. This is different than the
way maple and sam set the pins as they use a global
array that contains device specific register setting values

Not sure how easy it would be to get around the HAL or if that is possible.

Good Luck

You can get the list of available ports from below.

Also you may want to refer the example that directly accesses the register.