This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts
This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Send data with BLE_LBS characteristic

Hi everyone, I took a nrf51-ble-app-lbs-throughput-test-5.1.0 example from github.com/NordicSemiconductor; I want to send data not only with the push button but even after I wrote 0x01 on LED characteristic. So led is light and data is send. All works fine but if I write 0x00, data don't stop and continue to send them. The led doesn't off. What's happen? I want to stop send data if I write 0x00, in led characteristic. I work with SDK S110 rel 7.0.0 and PCA10001. The only snippet code that I have modified is:

static void led_write_handler(ble_lbs_t * p_lbs, uint8_t led_state)
{
    if (led_state)
    {
        nrf_gpio_pin_set(LEDBUTTON_LED_PIN_NO);
			  m_is_sending_data = true;
			  
    }
    else
    {
        nrf_gpio_pin_clear(LEDBUTTON_LED_PIN_NO);
			  m_is_sending_data = false;
    }
		
		if (m_is_sending_data)
		{
       data_send();
		}			
}

Thank you for your help.

Parents Reply Children
No Data
Related