setting.h 3.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119
  1. #ifndef __SETTING__H_
  2. #define __SETTING__H_
  3. #define APN_SEGMENT_MAX_LEN (30+1)
  4. #define IMEI_SIZE 15
  5. typedef enum{
  6. SERVER_HZ,
  7. SERVER_SD,
  8. SERVER_FENFA,
  9. SERVER_JIQUN,
  10. SERVER_UR,
  11. }SERVER_ENUM;
  12. #pragma pack(push)
  13. #pragma pack(1)
  14. typedef struct{
  15. char pip[40];
  16. char gip[40];
  17. }SERVER_DEF;
  18. typedef struct{
  19. unsigned char defaultuse;//默认使用哪一个�务 0 zh 1 sd
  20. SERVER_DEF zh;
  21. SERVER_DEF sd;
  22. SERVER_DEF ur;
  23. char ipFenFa[40];
  24. char jiqun[40];
  25. }SERVER_LISTTYPE;
  26. typedef struct{
  27. char account[APN_SEGMENT_MAX_LEN];
  28. char pass[APN_SEGMENT_MAX_LEN];
  29. }APN_NAMEDEF;
  30. typedef struct{
  31. unsigned char defaultuse;//默认使用哪一个APN
  32. unsigned char apnShowFlag;//是�显示出APN��
  33. char APN_Name[APN_SEGMENT_MAX_LEN];
  34. APN_NAMEDEF apnList[4];
  35. }APN_LISTTYPE;
  36. typedef struct{
  37. unsigned short proID;//�域ID
  38. unsigned short CityID;//市域ID
  39. unsigned char Manufacturers[5];//制造商
  40. unsigned char TerMod[20];//终端型�
  41. unsigned char TerID[7];//终端ID
  42. unsigned char PlateColor;//车牌颜色
  43. char Plate[8];//车辆标识
  44. }AUTH_REGDEF;
  45. typedef struct{
  46. unsigned char authCode[7];
  47. AUTH_REGDEF registerPara;
  48. }AUTH_TYPEDEF;
  49. typedef struct{
  50. unsigned char ConfigFlag;//0 表示刷新了代��第一次�行
  51. unsigned char Mode;//�置文件所属机型
  52. ///////////////////////////////////////
  53. unsigned char spkVol; //�接耳机时SPK音�
  54. unsigned char micGain;//接耳机时MIC耳机增益
  55. unsigned char itemShowType;//0 开机显示 公网集群对讲 注册�显示三大��商 1 一直显示公网集群对讲
  56. unsigned char spkGain;//接耳机时SPK耳机增益
  57. unsigned char lockType;//键盘�类型 1 全� 0 ��正�三键
  58. unsigned char BleEnable; //À¶ÑÀ״̬
  59. unsigned char BleSpkLv;
  60. unsigned char BleMicLv;
  61. unsigned char Xinbiao_station;
  62. unsigned char Xinbiao_LiveUpdate;
  63. unsigned char Xinbiao_SendMode;
  64. unsigned char Xinbiao_Time;
  65. unsigned char Xinbiao_IpEnable;
  66. unsigned char menu_tts; //²Ëµ¥TTS
  67. unsigned char Poc_sound; //
  68. unsigned char Shake;
  69. unsigned char sidekey01_func;
  70. unsigned char sidekey02_func; //01
  71. unsigned char SpkMode; //场景模�
  72. unsigned char MicMode; //MIC模� 高中低
  73. unsigned char reversed[50-20];//�留段
  74. ///////////////////////////////////////
  75. char ttsMessage[20*4];//开机TTS,空则�播放
  76. unsigned char ttsCodeType;//TTS编�类型
  77. unsigned char serverMenuPass[6];//�务器��密�
  78. unsigned char messageResetFlag;//'R'表示��文件消�
  79. unsigned int messageNewAddr;//新消�的地�
  80. unsigned short lcdParaList[5];//LCD�显时间�数
  81. unsigned char lcdParaDefaultIndex;//LCD当�使用的�显索引
  82. unsigned char authType;//鉴�类型 3GPP
  83. SERVER_LISTTYPE serList;
  84. APN_LISTTYPE apnList;
  85. unsigned char netMode;//网络模�
  86. unsigned char SoundMode;//0室内 1 室外
  87. unsigned char KeySound;//�示音打开状� 0关闭 1打开
  88. unsigned char gpsTimeIndex;//GPS上传时间索引
  89. AUTH_TYPEDEF authPara;//部标�数
  90. unsigned short gpsPort;//GPS�务器端�
  91. unsigned char pwrMode;//功耗模�
  92. unsigned char lvl;//公网室内模�喇�音�
  93. unsigned char boardLayout;//�层数
  94. unsigned char outDoorLvl;//公网室外模�喇�音�
  95. unsigned char gpsEnable;//�支�,则默认�开GPS,且GPS��(�显示),如果支�,则自动强制bubiaoEnable支�
  96. unsigned char bubiaoEnable;//�支�,则无GPS,且无文本消���(�显示)
  97. unsigned int defaultPsn;
  98. }SYSINI_HS191X_DEF;
  99. #pragma pack(pop)
  100. extern SYSINI_HS191X_DEF newPara;
  101. extern char showPIP[40];
  102. extern char showGIP[40];
  103. void sysIniSave(char *reason);
  104. void sysIniRead(void);
  105. void readInfoNow(void);
  106. void setPocPara(char *pocPara,int len);
  107. char *getPIPAddr(void);
  108. char *getGIPAddr(void);
  109. char *getDOMAINAddr(void);
  110. char *getMenuKey(void);
  111. void cmdSetting(char *msg);
  112. void ModemSetZZDPocPara();
  113. #endif