Beware that this post is related to an SDK in maintenance mode
More Info: Consider nRF Connect SDK for new designs

Where can I find the actual API documentation that talks about how to write against the nRF Connect SDK?

I've googled all over, and I'm having a hard time finding any documentation that digs into how to use the nRF Connect SDK.  Most documents point to examples, however the wealth of examples come from the pre-connect SDK.  I've found the docs for the actual functions, but not a "if you want to use the ADC, here are the steps you need to take" type of documentation.  

In my case, I want to figure out the most efficient way to continuously from 8 adc channels and transmit the data plus associated timestamps via bluetooth and/or uart in a way that's non-blocking (i.e. samples can get dropped).  I've come across some discussion on using the PPI, but not sure if I can use PPI with higher level bluetooth calls.  Can I implement continuous sampling to write to a ringbuffer and have the bt and/or uart read from that ringbuffer?  where can I find docs on how to do that?  Also, if I want to dynamically change the ADC channels that i'm sampling from (i.e. different pos/neg inputs) - what's the best way to do that and avoid using the overlays?

I've only seen one trivial ADC example that doesn't help me much.  

Thanks!

Reza

Parents Reply Children
  • Kenneth,

    Thank you so much for pointing me at some relevant docs.  I've been spending some time trying to understand all the parts - please let me know if i'm on the right or wrong track.

    So the NRFX codebase lets me use peripherals without having to use the overlays? If so, this example seems the most relevant that I've found so far (github.com/.../nRF52-ADC-examples).  

    I then configure a timer to trigger adc conversions of a sequence of channels to a FIFO.  

    I would also configure a different timer to read from the fifo and send data to the BT stack?

    Is this the best approach?  Is there any way to get the ADC to just run and write to a FIFO without the cpu interacting?  And I'm assuming this will work with SDK Connect?  

    In looking at PPIs, I've only really seen examples where they are used to connect an i/o change to an interrupt or visa-versa.  Not sure how they can be used with the ADC or BT -- can they be?   In the nrfx_saadc_multi_channel_ppi example, it seems that the PPI is only used to initiate an ADC conversion from the timer -- I'm not sure how this is better than having an timer ISR start the ADC conversion itself.

    I think I picked a bad time to start using the Nordic ICs -- the older SDK seemed so much more straightforward and so much better documented.  Are people still coding against it or is the use of the Connect highly recommended?

    Thanks in advance,

    Reza

  • Hi again,

    the_reza said:
    Is this the best approach?  Is there any way to get the ADC to just run and write to a FIFO without the cpu interacting?  And I'm assuming this will work with SDK Connect?  

    It's possible to setup timers, ppi and adc to execute an ADC measurement without MCU interaction at given intervals, but the handling (e.g. copying to a different buffer) must be done by the MCU. This is a good approach.

    the_reza said:
    I think I picked a bad time to start using the Nordic ICs -- the older SDK seemed so much more straightforward and so much better documented.  Are people still coding against it or is the use of the Connect highly recommended?

    The nRF Connect is the one that is recommended and preferred yes. The old nRF5 SDK only get critcal fix updates, all new development is on the nRF Connect SDK.

    Best regards,
    Kenneth

Related