123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596 |
- #ifndef __APP_H_
- #define __APP_H_
- #include "lsapi_os.h"
- #define APP_TASK_SLEEP_TIME 10
- #define APP_SUB_DIV_TIME (APP_TASK_SLEEP_TIME*2) //��𧒄�芣��?
- typedef enum{
- ENCODE_USER_GBK=1,
- ENCODE_USER_UNICODE_BE=2,
- ENCODE_USER_ASCII=3,
- }ENCODE_USER_ENUM;
- typedef enum{
- ASLEEP_POC,//POC�臬炏隡𤑳�
- ASLEEP_ADC,//�喲��钅僼�臬炏敹?
- ASLEEP_KEY,//�桅�鐗EY�臬炏�臭誑隡𤑳�嚗峕��厰睸�臭誑隡𤑳�(��賒�劐�銝滢��?
- ASLEEP_MKEY,//�拚猐KEY
- ASLEEP_PWR,//�菜��臬炏�扯�鈭���?
- ASLEEP_LCD,//LCD�臬炏隡𤑳�
- ASLEEP_GGROUP,//�其��瑕�蝢斤��𡑒”�嗡�閬���?
- ASLEEP_GUSER,//�其��瑕��𣂼��𡑒”�嗡�閬���?
- }ASLEEP_ENUM;
- #pragma pack(push)
- #pragma pack(1)
- typedef struct{
- char psn[20];
- unsigned char OtherId[16];
- unsigned char OtherPassWord[20];
- unsigned char platform[20];
- unsigned char pFormatMark[20];
- unsigned char tnet;
- }USER_STOR_INFO;
- typedef struct{
- unsigned char guiStatus:1;//gui�臬炏�嘥��硋��?
- unsigned char pocInitStatus:1;//poc�臬炏�臬𢆡摰峕�
- unsigned char appStatus:1;//app�臬炏隡𤑳�
- unsigned char pocParaDone:1;//poc��㺭�臬炏璉�瘚见��?
- unsigned char cardStatus:1;//
- unsigned char Get_MicLv:1;
-
- unsigned char gtMode:1;//GT璅∪�
- unsigned char gtTMode:1;//TM璅∪�
- unsigned char pocPpp:1;
- unsigned char pwrLock:1;//�菜��臬炏���嚗�蘨�匧銁�菜��芷�摰𡁏𧒄嚗���箔��滚��?
- unsigned char enableKey:1;//撱嗆𧒄�屸𢒰�臬炏摰峕�嚗𣬚鍂鈭𡡞獈甇W辣�嗆��渡�甇X��格�雿?
- unsigned char keyLock:1;//�桃��臬炏鋡恍�鈭?
- unsigned char lockShow:1;//�曄內銝�銝贝圾���蝷箔縑�?
- unsigned char groupTTSEnable:1;//�嗅�86�臭誑�剜𦆮
- unsigned char startPoc:1;
- unsigned char earLev:1;
- unsigned char earPttReady:1;
- unsigned char lowPwrWarn:1;
- unsigned char lowPwrMsg:1;
- unsigned char forceUiFlash:1;//隡𤑳��埝䔉�荔�撘箏�UI�湔鰵銝�銝?
- unsigned char authReady:1;
- unsigned char lcdDlyLightUp:1;//LCD�日��𠬍��嘥��硋��滨�鈭?
- unsigned int lowPwrCnt;
- unsigned char earCnt;
- unsigned char pcant;
- unsigned int appSleepStatus;//APP�臬炏�臭誑隡𤑳�
- USER_STOR_INFO UserInfo;
- int g_iCSQ;
- int g_iBAT;
- char fotaVersion[10];
- char pocVersion[20];
- unsigned char simSel;//�∠鍂��糓�芯葵:0,1
- char modemVer[30];
- unsigned char key_f1_cnt;
- unsigned char key_f2_cnt;
- int copstype;
- // unsigned char VolMicLvCu;
- // unsigned char VolMicLvXi;
- unsigned char ICCID[21];
- unsigned short VailDay;
- unsigned char voluemUpdate;
- unsigned char LightStatus;
- unsigned char MenuToStandby; //粕等殿隙渾儂賜醱
- }APP_DEF;
- #pragma pack(pop)
- extern APP_DEF sutApp;
- void appRun(void);
- void dataInit(void);
- void keyCheck(unsigned short keyStatus);
- void threadSendEvent(LSAPI_OSI_Thread_t *threadID, unsigned int id, unsigned int param1,unsigned int param2,unsigned int param3);
- void usbCmdHandler(const char *data,unsigned int length);
- void subTask(void *param);
- void ttsPlay(ENCODE_USER_ENUM type, char *tts);
- void backLightReset(void);
- void backLightCb(void *param);
- void StrAsciiToHex(char *src, unsigned char *des);
- #endif
|