Dear Team,
what is the way to do it in Zephyr?
I have a signal up-to 10kHz, what is the best way to keep the counter in the background?
Thank you and best
Oleh
Dear Team,
what is the way to do it in Zephyr?
I have a signal up-to 10kHz, what is the best way to keep the counter in the background?
Thank you and best
Oleh
Hi.
Here is the code I used to count pulses. It does not calculate the frequency, but that should be easy to do if you see how many pulses you get per unit of time.
Best regards,
Didrik
Hi, thank you!
Just a short confirmation question: can I use Gpiote/PPI in Zephyr with nrf91?
Best
Oleh
Yes, you can use GPIOTE and DPPI on the nRF91.
It looks like Zephyr's GPIO driver uses GPIOTE internally.
The PPI trace sample works with both nRF91 and nRF52 and might be a good starting point on how to use DPPI.
thanks for the hint! I'm trying it out...
first blocker was: https://devzone.nordicsemi.com/f/nordic-q-a/49657/how-to-link-nrfx-gpiote-and-ppi-in-zephyr/198090#198090 when adding the config -- it picked up.
second blocker is "GPIOTE_IRQn undeclared" for nRF9160 (there are two: GPIOTE0_IRQn/GPIOTE0_IRQn defined in \zephyr\ext\hal\nordic\nrfx\mdk\nrf9160.h)
am I missing something? Or was the ppi_trace never configured+tested on nRF9160?
Thanks!
The ppi_trace sample worked for me.
I did not get any build errors.
However, I did have to change the pins used to 10, 11, and 12. You can do this in the Kconfig file in the sample, or by adding the relevant configurations in the prj.conf file.
Also, the sample should be built as a secure application (use target nrf9160_pca10090, no ns).