Hello everyone,
i need to increment a counter each time my button on the nrf534DK is pressed
i'm using sdk v 1.7.1 .
is there a simple way to do it or a function which supports this
do you have any example that can guide me through, so that i can implement and increment my counter each time the button is pressed .
i already have my button example running perfectly
i just need to implement a counter that increments by 1 each time the button is pressed
i did some researches and i saw that RTC counter need to be used
do you have an example on that or can you guide me through to get it done
the image below is showing how my button is pressed
1-button pressed ( printk("***************Button pressed at %" PRIu32 "\n", k_cycle_get_32()); k_cycle_get_32->Current hardware clock up-counter (in cycles) )
2-get bme data
3-get Mpu data
knowing the details can you help me please implement the counter
feel free to provide me with any example that can help me
i really appreciate your help in advance
very thankful
kindly,
Rihab