Hi guys:
I encoutered a issue:
A: I flashed a APP from SDK(SDK-location\nRF5_SDK_15.0.0_a53641a\nRF5_SDK_15.0.0_a53641a\examples\ble_peripheral\ble_app_uart.)
B: I found there defined the function of button1: ,you can find this snippet in location: SDK\nRF5_SDK_15.0.0_a53641a\nRF5_SDK_15.0.0_a53641a\components\libraries\bsp\bsp_btn_ble.c
/**@brief Function for configuring the buttons for advertisement.
*
* @retval NRF_SUCCESS Configured successfully.
* @return A propagated error code.
*/
static uint32_t advertising_buttons_configure()
{
uint32_t err_code;
err_code = bsp_event_to_button_action_assign(BTN_ID_DISCONNECT,
BTN_ACTION_DISCONNECT,
BSP_EVENT_DEFAULT);
RETURN_ON_ERROR_NOT_INVALID_PARAM(err_code);
err_code = bsp_event_to_button_action_assign(BTN_ID_WHITELIST_OFF,
BTN_ACTION_WHITELIST_OFF,
BSP_EVENT_WHITELIST_OFF);
RETURN_ON_ERROR_NOT_INVALID_PARAM(err_code);
err_code = bsp_event_to_button_action_assign(BTN_ID_SLEEP,
BTN_ACTION_SLEEP,
BSP_EVENT_SLEEP);
RETURN_ON_ERROR_NOT_INVALID_PARAM(err_code);
return NRF_SUCCESS;
}
C: The problem is : when i pressed button1.the app didn't enter sleep mode. why?