Upcoming maintenance
Dear Customers and Partners.
This website will be undergoing scheduled maintenance on June 14, 2023. Please be aware there may be disruption to the developer portal website and associated services during the scheduled maintenance period.
This upgrade is essential to ensure the continued performance, reliability, and security of Developer World.
We apologize for any inconvenience.
How to access registers through Arduino IDE
-
Hi,
I am working with the sony spresense mainboard. In the datasheet of the CXD5602 there are several registers. For example: {0x5680} PWM_TIMER01. Cited from the datasheet "When the PWM is not used, PWM generator can be used as a timer. In this case, counter values within the timer can be read."
Is it possible to access the registers like the example through the Arduino IDE?
Thanks in advance
-
Hi @Jamu
You can try to access the registers like here: https://github.com/sonydevworld/spresense-arduino-compatible/blob/665fca0d36f435813f42590328c809a6a83476ab/Arduino15/packages/SPRESENSE/hardware/spresense/1.0.0/cores/spresense/wiring_digital.c#L122
You can use
getreg32()
andputreg32()
functions for this.Best Regards,
Kamil Tomaszewski -
@KamilTomaszewski Thank you, I will give it a try and will edit the post with the result!