This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Disable nus_data_handler interrupt and enable it later again

Hello, 

I would like to disable and enable the nus_data_handler in my code to work with several interrupts, so I need to disable that handler and then reenable that again without loosing the BLE configuration nor the connections, only prevent to entering to that handler code, which is the best way to achieve this?

I want to disable the nus_init.data_handler = nus_data_handler so it won enter to execute the method "nus_data_handler" and then reenable the handler to execute the code/method again, if this is interrupt driven which is the right way to disable/enable this without messing up the BLE configuration? The project I'm working on is a free rtos based one.

Regards, 

Francisco Betancourt

Related