lancaster-university / microbit-v2-samples

CODAL build tools and sample programs for the micro:bit v2.x
MIT License
69 stars 89 forks source link

Help with accessing ADC registers #51

Closed keble6 closed 2 years ago

keble6 commented 2 years ago

I'm struggling with setting up pointers etc to access the V2 (nRF52833) ADC registers.

The V1 has an ADC example here.

How can I find out the equivalent "defines" (such as NRF_ADC->CONFIG) for the V2?

microbit-carlos commented 2 years ago

Hi @keble6,

The register names can be found in the nRF52833 datasheet:

And you should be able to find the structure definitions in the nrfx library (which is included in CODAL via codal-nrf52):

keble6 commented 2 years ago

Thanks Carlos! Rob

On 10 Aug 2022, 17:38, at 17:38, Carlos Pereira Atencio @.***> wrote:

Hi @keble6,

The register names can be found in the nRF52833 datasheet:

https://infocenter.nordicsemi.com/index.jsp?topic=%2Fstruct_nrf52%2Fstruct%2Fnrf52833.html

And you should be able to find the structure definitions in the nrfx library (which is included in CODAL via [codal-nrf52]):

-- Reply to this email directly or view it on GitHub: https://github.com/lancaster-university/microbit-v2-samples/issues/51#issuecomment-1210970627 You are receiving this because you were mentioned.

Message ID: @.***>

microbit-carlos commented 2 years ago

If that helped I think I'll close this as resolved, but let us know if you have any other questions.