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

nRF52832 sleep mode issue

Req: from the cap-sense board, different tap will be done by user (like 2 times tap, 3 three times tap etc). so the Bluetooth board (nrf52) will receive these taps as interrupt connected to a gpio configured from cap-sense board. Profile Used in Bluetooth board: Proximity . For the requirement stated,

  1. firstly, i have added the interrupt functionality (pin_change_int code) into Proximity profile for checking the no of tap received through the gpio as interrupt.
  2. secondly, when the tap is made from cap-sense side, the Bluetooth board will read the tap through the gpio assigned as interrupt. Bluetooth board will to do fast adv , slow adv and goes to sleep (separate function buttons_led_init is there in Proximity code), but when interrupt functionality is added to the proximity profile, Bluetooth device is not going to sleep. so what change in code should be done in order avoid this conflict.
Parents
  • REQ: when both mobile and Bluetooth device is connected, character should be sent from Bluetooth device to mobile for doing some functionality in mobile side. Action Taken : I have used sd_ble_gatts_hvx() function for sending the character from device to mobile as below,
    memset(&params, 0, sizeof(params));
    params.type = BLE_GATT_HVX_NOTIFICATION;
    params.handle = p_char_send.char_handles.value_handle;
    params.p_data = data_to_send;
    params.p_len = &len;
    params.offset = 0;
    err_code = ble_ias_c_send_alert_level(&m_ias_c, two_press);
    but its not working for me. so, what change i have to do in in order to send character or number from device to mobile?

Reply
  • REQ: when both mobile and Bluetooth device is connected, character should be sent from Bluetooth device to mobile for doing some functionality in mobile side. Action Taken : I have used sd_ble_gatts_hvx() function for sending the character from device to mobile as below,
    memset(&params, 0, sizeof(params));
    params.type = BLE_GATT_HVX_NOTIFICATION;
    params.handle = p_char_send.char_handles.value_handle;
    params.p_data = data_to_send;
    params.p_len = &len;
    params.offset = 0;
    err_code = ble_ias_c_send_alert_level(&m_ias_c, two_press);
    but its not working for me. so, what change i have to do in in order to send character or number from device to mobile?

Children
No Data
Related