(1)重新提供提示音数组,之前的太多0x0(2)增加重连时候提示音(3)重连提示音加上判断是否按键开机,否则开机会先报正在连接服务器再开机(4)开启睡眠仪的时候去掉ummap50等,这里延时1000ms会导致3轴出问题很奇怪
This commit is contained in:
parent
828f92af0b
commit
4123839c85
File diff suppressed because it is too large
Load Diff
@ -88,7 +88,7 @@ void app_event_asr_evt_callback(media_app_evt_type_t event, uint32_t param)
|
||||
currentWifiState = link_status.state;
|
||||
|
||||
bk_printf("currentWifiState = %d\n", currentWifiState);
|
||||
if (currentWifiState == WIFI_LINKSTATE_STA_DISCONNECTED)
|
||||
if (currentWifiState == WIFI_LINKSTATE_STA_DISCONNECTED )
|
||||
{
|
||||
|
||||
app_event_send_msg(APP_EVT_NETWORK_PROVISIONING_FAIL, 0);
|
||||
@ -349,7 +349,7 @@ static void led_blink(uint32_t *warning_state, uint32_t indicates_state)
|
||||
last_warning_state = *warning_state;
|
||||
}
|
||||
}
|
||||
|
||||
extern int ispoweron;
|
||||
static void app_event_thread(beken_thread_arg_t data)
|
||||
{
|
||||
int ret = BK_OK;
|
||||
@ -477,7 +477,10 @@ static void app_event_thread(beken_thread_arg_t data)
|
||||
indicates_state |= (1 << INDICATES_WIFI_RECONNECT);
|
||||
indicates_state &= ~(1 << INDICATES_POWER_ON);
|
||||
#if CONFIG_AUD_INTF_SUPPORT_PROMPT_TONE
|
||||
if(ispoweron == 1){
|
||||
bk_aud_intf_voc_play_prompt_tone(AUD_INTF_VOC_RECONNECT_NETWORK);
|
||||
}
|
||||
|
||||
#endif
|
||||
break;
|
||||
|
||||
|
@ -362,11 +362,8 @@ static void handle_system_event(key_event_t event)
|
||||
poweroff_voice();
|
||||
ws2812_led_clear_all();
|
||||
ispoweron = 0;
|
||||
<<<<<<< HEAD
|
||||
rtos_delay_milliseconds(400);
|
||||
=======
|
||||
rtos_delay_milliseconds(1000);
|
||||
>>>>>>> 055e7e84bd6a0e47612d1047b42c9c6184b187e9
|
||||
|
||||
bk_gpio_enable_output(51);
|
||||
bk_gpio_set_output_low(51);
|
||||
|
||||
|
@ -331,17 +331,16 @@ void sleep_helper_open(){
|
||||
LOGE("sleep_helper_open\n");
|
||||
bk_gpio_enable_output(44);
|
||||
bk_gpio_enable_output(45);
|
||||
gpio_dev_unmap(GPIO_50);
|
||||
bk_gpio_enable_input(GPIO_50);
|
||||
//bk_gpio_enable_pull(GPIO_50);
|
||||
|
||||
// bk_gpio_enable_pull(GPIO_50);
|
||||
//bk_gpio_pull_up(GPIO_50);
|
||||
|
||||
rtos_delay_milliseconds(1000);
|
||||
//rtos_delay_milliseconds(200);
|
||||
uint8_t insert_value = bk_gpio_get_input(GPIO_50);
|
||||
LOGE("sleep_helper insert_value %d \n",insert_value);
|
||||
LOGE("sleep_helper insert_valueccc %d \n",insert_value);
|
||||
socket_insert = insert_value;
|
||||
if(socket_insert == 1){
|
||||
LOGE("sleep_helper open fail!! battery charging... %d \n",insert_value);
|
||||
LOGE("sleep_helper open fail!! cable not insert %d \n",insert_value);
|
||||
return ;
|
||||
}
|
||||
|
||||
@ -487,6 +486,9 @@ void sleep_helper_init(){
|
||||
gpio_dev_unmap(GPIO_44);
|
||||
gpio_dev_unmap(GPIO_45);
|
||||
|
||||
|
||||
gpio_dev_unmap(GPIO_50);
|
||||
bk_gpio_enable_input(GPIO_50);
|
||||
// gpio_dev_unmap(GPIO_50);
|
||||
// bk_gpio_enable_input(GPIO_50);
|
||||
// bk_gpio_enable_pull(GPIO_50);
|
||||
|
Loading…
x
Reference in New Issue
Block a user