Once GPIO is pressed (shorted to ground), I want to change the value of UUID or Major/Minor number
If not, the device will continue to advertise the previous values
Once GPIO is pressed (shorted to ground), I want to change the value of UUID or Major/Minor number
If not, the device will continue to advertise the previous values
Hello,
You will need to detect the button press. You will find examples doing this. E.g. the examples found in:
SDK\examples\peripheral\pin_change_int
SDK\examples\peripheral\bsp
Then you need to change the advertising data. You can do this by using the sequence: Stop advertising -> advertising_init (with your new advertising data) --> start advertising
Unfortunately, we do not have any examples doing exactly this at this point in time.
Best regards,
Edvin
Thank you - works perfect!
I found that using the pin_change_int example, the current consumption is too high. Where can I find an example of using "Sense" approach?
I found the answer: Just change to false: nrf_drv_gpiote_in_config_t in_config = GPIOTE_CONFIG_IN_SENSE_TOGGLE(true);
to: nrf_drv_gpiote_in_config_t in_config = GPIOTE_CONFIG_IN_SENSE_TOGGLE(false);