static INT32 win_otaupg_reboot(void) { ota_proc_ret = 0; ota_user_stop = 0; //ota_proc_step = OTA_STEP_BURNFLASH; osal_flag_clear(g_ota_flg_id,OTA_FLAG_PTN); key_pan_display("OFF ",4); osal_task_sleep(500); power_off_process(); sys_data_factroy_init(); sys_data_set_factory_reset(TRUE); sys_data_set_cur_chan_mode(TV_CHAN); power_on_process(); while(1) ; }
static void reset_factory_setting() { UINT8 bID, back_saved; win_popup_choice_t choice; UINT32 chunk_id, default_db_addr, default_db_len; CONTAINER *factory_msg_con; factory_msg_con = &fac_msg_con; TEXT_FIELD *factory_msg_txt; factory_msg_txt = &factoryset_msg; MULTISEL *factory_multisel; factory_multisel = &factory_state; api_stop_play(1); epg_reset(); OSD_SetTextFieldContent(factory_msg_txt, STRING_ID, (UINT32)RS_FACTORY_RESTORING); OSD_DrawObject((POBJECT_HEAD)factory_msg_txt, C_UPDATE_ALL); OSD_DrawObject((POBJECT_HEAD)factory_msg_con, C_UPDATE_ALL); //老版本弹出恢复出厂信息 //win_compopup_init(WIN_POPUP_TYPE_SMSG); //win_compopup_set_msg(NULL, NULL, RS_FACTORY_RESTORING); //win_compopup_open_ext(&back_saved); sys_data_factroy_init(); sys_data_set_factory_reset(TRUE); sys_data_set_cur_chan_mode(TV_CHAN); sys_data_save(TRUE); sys_data_load(); chunk_id = STB_CHUNK_DEFAULT_DB_ID; api_get_chuck_addlen(chunk_id, &default_db_addr, &default_db_len); set_default_value(DEFAULT_ALL_PROG, default_db_addr + 16); reset_search_param(); /*reset the local static param in full_band_search*/ if (GetMuteState()) SetMuteOnOff(FALSE); if (GetPauseState()) SetPauseOnOff(FALSE); #if(defined(MIS_AD) || defined(MIS_AD_NEW)) MIS_SetOSDAlpha(0x00); #endif #ifdef MULTI_CAS #if (CAS_TYPE == CAS_DVN) ap_cas_set_messageID(0); cas_flags_reset(); #elif(CAS_TYPE==CAS_IRDETO) setFirstIn(1); #elif (CAS_TYPE == CAS_CDCA) api_mcas_stop_transponder(); #endif #endif setMtxt(0); //win_compopup_smsg_restoreback();消除完成恢复出厂设置后出现的小黑框现象---#JingJin OSD_SetTextFieldContent(factory_msg_txt, STRING_ID, (UINT32)RS_FACTORY_DONE); OSD_DrawObject((POBJECT_HEAD)factory_msg_txt, C_UPDATE_ALL); OSD_SetTextFieldContent(factory_msg_txt, STRING_ID, (UINT32)RS_FACTORY_USER_SURE); OSD_SetMultiselSel(factory_multisel, 0); OSD_TrackObject((POBJECT_HEAD)factory_multisel, C_DRAW_TYPE_HIGHLIGHT); //老版本弹出恢复出厂信息 //win_compopup_init(WIN_POPUP_TYPE_SMSG); //win_compopup_set_msg(NULL, NULL, RS_FACTORY_DONE); //win_compopup_open_ext(&back_saved); }