tizen 2.4 release
[profile/mobile/platform/kernel/u-boot-tm1.git] / arch / arm / include / asm / arch-sc8810 / cmddef.h
1 /******************************************************************************
2  ** File Name:      cmddef.h                                                  *
3  ** Author:         Richard Yang                                              *
4  ** DATE:           20/09/2001                                                *
5  ** Copyright:      2001 Spreatrum, Incoporated. All Rights Reserved.         *
6  ** Description:    This file includes some common message type defines for   *
7  **                 other files.                                              * 
8  ******************************************************************************
9
10  ******************************************************************************
11  **                        Edit History                                       *
12  ** ------------------------------------------------------------------------- *
13  ** DATE           NAME             DESCRIPTION                               *
14  ** 20/09/2001     Richard.Yang     Create.                                   *
15  ** 25/12/2001     Lliu             Add LOG_FILTER_F and log filter cmd set   *
16  ** 01/06/2003     Eric.zhou        Add Channel server CMD and Time update    *
17  **                                     CMD.                                                              *     
18  ** 16/09/2003     Xueliang.Wang    Add a mode RESET_MODE to MCU_MODE_E       *
19  ** 20/05/2004     Zhemin.Lin       Add RPC cmd for digital camera(CR9397)    *
20  ******************************************************************************/
21 #ifndef _CMDDEF_H
22 #define _CMDDEF_H
23 #include "sci_types.h"
24 #include "tasks_id.h"
25 /**---------------------------------------------------------------------------*
26  **                         Compiler Flag                                     *
27  **---------------------------------------------------------------------------*/
28 #ifdef __cplusplus
29     extern   "C"
30     {
31 #endif
32 // This is the communication frame head
33 typedef struct msg_head_tag
34 {
35     uint32  seq_num;      // Message sequence number, used for flow control
36         uint16  len;          // The totoal size of the packet "sizeof(MSG_HEAD_T)
37                           // + packet size"
38         uint8   type;         // Main command type
39         uint8   subtype;      // Sub command type
40 } MSG_HEAD_T;
41
42 #define CM_COPY_MSG_HEAD(msg, num, total_len, main_type, sub_type) \
43 ((MSG_HEAD_T *) msg)->seq_num = num;  \
44 ((MSG_HEAD_T *) msg)->len     = total_len;\
45 ((MSG_HEAD_T *) msg)->type    = main_type;\
46 ((MSG_HEAD_T *) msg)->subtype = sub_type;
47
48 //Message Type define start
49 #define     MSG_REQ_REP_START   0
50 #define     DIAG_COMMAND_OFFSET 0
51 typedef enum
52 {
53     // Query commands
54     DIAG_SWVER_F             = 0,  // Information regarding MS software
55
56     DIAG_SOFTKEY_F           = 1,  // Soft key command
57     DIAG_LOG_F               = 2,
58     DIAG_AT_F                = 3,
59     DIAG_GET_SYS_INFO_F      = 4,  // Get system information.
60     DIAG_SYSTEM_F            = 5,
61
62     DIAG_CHIP_TEST_F         = 6,  // Direct chip test operation 
63     DIAG_POWER_F             = 7,  // Power on/off MS
64     DIAG_SIM_F               = 8,  // Sim card command
65     DIAG_PS_F                = 9,
66     DIAG_RF_F                = 10,
67     DIAG_MCU_F               = 11,
68     DIAG_CHANGE_MODE_F       = 12, // Set MCU mode: normal, test or calibration
69     DIAG_NVITEM_F            = 13,
70     DIAG_AT_CHLSRV_F         = 14, // AT Command from channel server
71       
72     DIAG_ADC_F               = 15, // read ADC result      
73     DIAG_PIN_TEST_F          = 16, // for Auto pin-test      
74     DIAG_CURRENT_TEST_F      = 17,
75     DIAG_SIM_CARD_TEST_F     = 18, // Test sim card
76     DIAG_AUDIO_TEST_F        = 19, // test audio part
77     DIAG_KEYPAD_TEST_F       = 20, // test keypad
78     DIAG_LCM_TEST_F          = 21, // test lcd module
79     DIAG_VIBRATOR_TEST_F     = 22, // test vibrator
80
81     DIAG_RPC_EFS_F           = 23,
82     DIAG_RPC_DC_F            = 24,
83     DIAG_PRODUCTION_TEST_EXTEND_F = 25,     // Product Test Extend Command.
84     DIAG_FORCE_ON_CELLS_F    = 26,
85     DIAG_RPC_FFS_F           = 27,
86     DIAG_GET_MCU_MODE_F      = 28, //query mcu mode
87     DIAG_CALIBRATION_NOISE_F = 29, // calibration noise check
88     DIAG_POWER_SUPPLY_F      = 30, 
89     DIAG_RF_QUERY_F          = 31,
90     DIAG_CALIBRATION         = 32,  
91     DIAG_CALIBRATION_BT_F    = 33, // Bluetooth test
92     DIAG_TP_F                = 34, 
93     DIAG_GPS_F               = 35,
94     DIAG_TD_NV               = 36, //DIAG_TD_NV=36, read/write the TD calibration parameter
95     DIAG_TV_PARAM            = 37, // add for TV chip 08-03-07
96     DIAG_READ_ASSERT_F       = 40, //read assert info from NV item. 
97
98     DIAG_LAYER1_F            = 50, // Read or write paramter by Layer1
99     DIAG_WIFI_TEST_F     = 54,      //wifi test
100       
101     DIAG_SENSOR_REG_F        = 90, // sensor register w/r tool
102     DIAG_FUN_CALL_F          = 92,
103     DIAG_DIRECT_NV           = 94,
104     DIAG_DIRECT_PHSCHK       = 95,   
105     DIAG_ENDIAN_CHECK_F      = 97,
106     DIAG_AP_F                = 98,
107     REQ_MAX_F                = 99                 
108 } diag_cmd_code_enum_type;
109
110
111 //yujun.ke add for layer1 to diag signals
112 typedef enum
113 {
114     L1_DIAG_RD_CALI_PARAM_CNF = DIAG<<8,
115     L1_DIAG_WR_CALI_PARAM_CNF
116 }SIGNALS_TO_DIAG_E;
117
118
119
120         #define     MSG_REG         99
121         #define     MSG_UNREG       100
122 #define     MSG_REQ_REP_END     100
123
124 #define     MSG_REQ_START       101
125         typedef enum
126         {
127           PS_REQ_F    = 101,     // Protocol stack request message.
128       ATC_CMD_R,             // ATC command to ATC module
129           IP_PACKET_R = 103,
130           PPP_PACKET_R,          // PPP packet request for ppp link!
131           DIAG_AT_R 
132         } bs_env_cmd_enum_type;
133 #define     MSG_REQ_END         150
134
135 #define     MSG_ANONY_START     151
136 #define     MSG_LINK_IND        0       // Added by Leo.Feng
137                                             // Notify ChannelServer Connect / Disconnect with MS
138         typedef enum
139         {
140         DIAG_LOG_A             = 152,   // log message
141         PS_L2_A,                        // L2 layer anonymous message.
142 //              L1_IND_A,                       // L1 anonymous message.
143                 IP_PACKET_A            = 154,
144                 DIAG_AT_A                          = 155,   // AT Command message
145                 PPP_PACKET_A,
146                 DIAG_MOBILETV_DSP_LOG_F = 157, 
147                 DIAG_AUTOTEST_INFO_F    = 158   // For Autotest INFORMATION             
148         } anony_enum_type;
149
150 #define     MSG_CONSOLE_A       159
151 #define     DIAG_CONSOLE_MS     159
152
153 #define     MSG_TOOLS_RESERVED  209
154 #define     MSG_ANONY_END       210
155 #define     MSG_TIME_OUT        211
156 #define     MSG_BUF_FULL        212
157 #define     MSG_SEND_OK         213
158 #define     MSG_CRC_ERROR       214
159 #define     MSG_LINK_ERROR      215
160 #define     MSG_UNKNOWN_STRUCT  216
161
162 // 
163 #define     MSG_BOARD_ASSERT    255
164 typedef enum
165 {
166     // Normal assert information, subtype of ASSERT message.
167     NORMAL_INFO,
168     // Dump memory data.
169     DUMP_MEM_DATA,
170     // Dump memory end.
171     DUMP_MEM_END,
172     // Dump sme buff memory end
173     DUMP_SME_BUFF_MEM_END
174 } ASSERT_DATA_TYPE_E;
175
176
177 /* Log filter command sets  */
178 typedef enum
179 {
180     //LOG_GET_INFO,
181     LOG_GET_FILTER = 1,
182     LOG_SET_FILTER,
183     LOG_SET_FLOW_LOG,
184     ARM_LOG_ENABLE,
185     ARM_LOG_DISABLE,
186     DSP_LOG_ENABLE,
187     DSP_LOG_DISABLE
188 } log_cmd_set_enum_type;
189
190 /* PS related command sets  */
191 typedef enum
192 {
193     CELL_INFO_F,
194     CAMP_STATUS_F
195 } PS_CMD_SET_ENUM_TYPE;
196
197 typedef enum
198 {
199         DIAG_STACK_INFO_F,
200         DIAG_MEMORY_INFO_F,
201         DIAG_BACKTRACE_F,
202     DIAG_MEM_ALLOC_INFO_F,
203     DIAG_ASSERT_MS
204 } system_info_cmd_set_enum_type;
205
206 typedef enum
207 {
208         DIAG_NORMAL_KEY_MSG_INFO_F,             // both send key down and up msg
209         DIAG_KEY_MSG_DOWN_INFO_F,               // only send key down msg
210         DIAG_KEY_MSG_UP_INFO_F                  // only send key up msg
211 } softkey_cmd_set_enum_type;
212
213 /* BATTERY related command type sets*/
214 typedef enum
215 {
216     BATT_VOLTAGE_F
217 }POWER_SUPPLY_TYPE;
218
219 /* AT Like Command ERROR type sets  */
220 #define         ATCMD_ERROR_TYPE_BASE   0
221 typedef enum
222 {
223         ATCMD_SUCCESS           = ATCMD_ERROR_TYPE_BASE,
224         ATCMD_BADCOMMAND,
225         ATCMD_BADPARAMETER,
226     ATCMD_BADADDRESS,
227     ATCMD_BADLENGTH,
228     ATCMD_BADADDRLEN,
229     ATCMD_REPOWERON,
230     ATCMD_REPOWEROFF
231 } ATCMD_ERROR_TYPE_E;
232
233 typedef enum
234 {
235     MCU_READB,
236     MCU_READW,
237     MCU_READD,
238     MCU_WRITEB,
239     MCU_WRITEW,
240     MCU_WRITED
241 } DIRECT_CHIP_TEST_TYPE_E;
242
243 typedef enum
244 {
245     NVITEM_READ,                                /*0*/
246     NVITEM_WRITE,
247     NVITEM_PRODUCT_CTRL_READ,
248     NVITEM_PRODUCT_CTRL_WRITE,
249     NVITEM_PRODUCT_CTRL_ERASE,
250     NVITEM_GETLENGTH,                   /*5*/
251     NVITEM_DELETE
252 } NVITEM_ACCESS_E;
253
254 #define MAX_WRITE_SIZE 100
255
256 typedef struct
257 {
258     int * addr;
259 } CHIP_READ_T;
260
261 typedef struct
262 {
263     int * addr;
264     int buffer[MAX_WRITE_SIZE];
265 } CHIP_WRITE_T;
266 /* Message type define end*/
267
268 typedef enum
269 {
270     POWER_ON, 
271     POWER_OFF
272 } POWER_SET_E;
273
274 typedef enum
275 {
276     NORMAL_MODE                         = 0,
277     LAYER1_TEST_MODE                    = 1,
278     ASSERT_BACK_MODE                    = 2,
279     CALIBRATION_MODE                    = 3,
280     DSP_CODE_DOWNLOAD_BACK              = 4,
281     DSP_CODE_DOWNLOAD_BACK_CALIBRATION  = 5,
282     BOOT_RESET_MODE                     = 6,
283     PRODUCTION_MODE                     = 7,
284     RESET_MODE                          = 8,
285     CALIBRATION_POST_MODE               = 9,
286     PIN_TEST_MODE                       = 10,
287     IQC_TEST_MODE                       = 11,
288     WATCHDOG_RESET_MODE                 = 12,
289
290     CALIBRATION_NV_ACCESS_MODE          = 13,
291     CALIBRATION_POST_NO_LCM_MODE        = 14,
292
293     TD_CALIBRATION_POST_MODE            = 15,
294     TD_CALIBRATION_MODE                 = 16,
295     TD_CALIBRATION_POST_NO_LCM_MODE     = 17,
296     AUTO_TEST_MODE                      = 18,
297     
298     MODE_MAX_TYPE,
299
300     MODE_MAX_MASK                       = 0x1f  
301     
302 } MCU_MODE_E;
303
304 /*
305 *indicate that current is usb mcft mode
306 *maybe used only when changmode by pc tools
307 */
308 #define MCU_MODE_USB  0x80
309
310 typedef enum
311 {
312     MISC_TM_UPDATE =1,
313     MISC_RESERVED 
314 } MISC_CMD_E;
315
316
317 typedef enum
318 {
319     ADC_0  = 0x1,
320     ADC_1  = 0x2,
321     ADC_2  = 0x3,
322     ADC_3  = 0x4,    
323     ADC_4  = 0x5,
324     ADC_5 = 0x6, 
325     ADC_6 = 0x7,
326     ADC_0_HIGH_VOLTAGE = 0x81,
327     ADC_1_HIGH_VOLTAGE = 0x82,
328     ADC_2_HIGH_VOLTAGE = 0x83,
329     ADC_3_HIGH_VOLTAGE = 0x84, 
330     ADC_4_HIGH_VOLTAGE = 0x85, 
331     ADC_5_HIGH_VOLTAGE = 0x86,
332     ADC_6_HIGH_VOLTAGE = 0x87
333 }ADC_SOURCE_E;
334
335 // @lin.liu (2003-08-25), CR: ms4267 
336 typedef struct
337 {
338     MSG_HEAD_T   msg_head;
339     uint16       result;     // the result that sent back to PC
340 }MSG_ADC_T;
341
342 #define MAX_TEST_PIN_NUM       292
343
344 //#define PIN_STATE_UNDEFINED      0x0
345 //#define PIN_STATE_PASS           0x1
346 //#define PIN_STATE_FAIED          0x2
347 //#define PIN_STATE_NOT_CHECKED    0x3
348
349 // We use 2bits for one pin.
350 // state[n][1:0] :  state of pin 4*n + 0
351 // state[n][3:2] :  state of pin 4*n + 1
352 // state[n][5:4] :  state of pin 4*n + 2
353 // state[n][7:6] :  state of pin 4*n + 3
354 //
355 typedef struct
356 {
357     MSG_HEAD_T   msg_head;
358     uint16       pin_num;           // the pin number of the module.( include PASS, FAILED, NOT_CHECKED )
359     uint8        pin_state[ (MAX_TEST_PIN_NUM) / 4 + 2]; // pin state.
360 }MSG_PIN_TEST_T;
361 // End. @lin.liu
362
363 typedef struct
364 {
365     MSG_HEAD_T   msg_head;     // type is DIAG_CALIBRATION_NOISE_F
366     union
367     {
368         struct{
369                 uint32       EAR_noise_count;
370                 uint32       speaker_noise_count;
371         }result;
372         struct{
373             uint32       check_time;  // the time to check the noise count( ms )
374             uint32       reserved;
375         }input;
376     }param;
377 }MSG_CALIBRATION_NOISE_T;
378
379 typedef enum
380 {
381     CURRENT_TEST_STOP                   = 0,
382     CURRENT_TEST_RF_CLOSED              = 1,
383     CURRENT_TEST_DEEP_SLEEP             = 2,
384     CURRENT_TEST_LED_ON                 = 3,
385     CURRENT_TEST_VIBRATOR_ON            = 4,
386     CURRENT_TEST_RX_MIN_PEAK_VALUE      = 5,
387     CURRENT_TEST_TX_MAX_PEAK_VALUE      = 6,
388     CURRENT_TEST_CHARGING               = 7,
389     CURRENT_TEST_LED_OFF                = 8,
390     CURRENT_TEST_VIBRATOR_OFF           = 9,
391      CURRENT_TEST_DEEP_GET_SLEEP_FLAG   = 0xA,
392     CURRENT_TEST_DEEP_SLEEP_FLAG_ENABLE = 0xB,
393     CURRENT_TEST_DEEP_SLEEP_FLAG_DISABLE= 0xC,
394     CURRENT_TEST_DEEP_SLEEP_WAKEUP      = 0xF // Be careful that the higer 8 bit is used for parameter of how long it sleeps
395     
396 }CURRENT_TEST_E;
397
398 typedef enum
399 {
400     REG_READ, 
401     REG_WRITE
402 } REG_RW_E;
403
404 typedef enum
405 {
406         UNIT8_TYPE=1,
407         UNIT16_TYPE, 
408         UINT32_TYPE
409 } REG_TYPE_MODE_E;
410
411 typedef enum
412 {
413         REG_READ_SUCCESS,    // successful
414         REG_READ_ADDR_ERR,   // address cann't access 
415         REG_READ_OTHER_ERR  // other error
416 }READ_RESULT_MODE_E;
417
418 typedef enum
419 {
420         REG_WRITE_SUCCESS,   // successful
421         REG_WRITE_ADDR_ERR,  // address cann't access 
422         REG_WRITE_VALUE_ERR, // value error 
423         REG_WRITE_OTHER_ERR // other error
424 } WRITE_RESULT_MODE_E;
425
426 typedef struct
427 {
428         uint32       mode;     // MODE_ENUM
429         uint32       addr;     // register address
430         uint32       value;    // register value
431 }MSG_REG_T, *MSG_REG_PTR;
432
433 typedef struct
434 {
435         uint32       func_id;     //
436
437 }MSG_FUNC_CALL_T, *MSG_FUNC_CALL_PTR;
438
439 #define MAX_FAILED_PIN_NUM    64
440 typedef struct
441 {
442     MSG_HEAD_T      msg_head;
443     uint16          result;
444     uint8           failed_pin[ MAX_FAILED_PIN_NUM + 4]; // +4 for overwrite check
445 }MSG_PRODUCT_TEST_T;
446
447
448
449
450 //@lin.liu(2004-05-09). CR8889
451 //#define the subtype of type(DIAG_RPC_EFS_R).
452 typedef enum
453 {
454     RPC_EFS_CLOSE,
455     RPC_EFS_GET_LENGTH,
456     RPC_EFS_CREATE,
457     RPC_EFS_SEEK,
458     RPC_EFS_READ,
459     RPC_EFS_WRITE,
460     RPC_EFS_DELETE,
461     RPC_EFS_RENAME,
462     RPC_EFS_CHECK_EXIST,
463     RPC_EFS_FIND_FIRST,
464     RPC_EFS_FIND_NEXT,
465     RPC_EFS_CREATE_DIR,
466     RPC_EFS_DELETE_DIR,
467     RPC_EFS_FOPEN,
468     RPC_EFS_FCLOSE,
469     RPC_EFS_FREAD,
470     RPC_EFS_FWRITE,
471     RPC_EFS_FSEEK,
472     RPC_EFS_FTELL,
473     RPC_EFS_FEOF
474 }RPC_EFS_FUNCTION_E;
475 //End CR8889
476
477 //@Zhemin.Lin(2004-05-20), CR9397
478 typedef enum
479 {
480         RPC_DC_OPEN = 0,
481         RPC_DC_CLOSE,
482         RPC_DC_SETBYPASSMODE,
483         RPC_DC_SETPOWERSAVEMODE,
484         RPC_DC_SETPREVIEWWINSIZE,
485         RPC_DC_MOVEPREVIEWIN,
486         RPC_DC_STARTPREVIEW,
487         RPC_DC_STOPPREVIEW,
488         RPC_DC_SNAPSHOT,
489         RPC_DC_DISPJPEG,
490         RPC_DC_LOADOSD,
491         RPC_DC_ZOOMIN,
492         RPC_DC_ZOOMOUT,
493         RPC_DC_SETSWIVELMODE,
494         RPC_DC_SETOVERLAYMODE,
495         RPC_DC_GETERRORID,
496         RPC_DC_SETJPEGSIZE,
497         RPC_DC_SETJPEGLEVEL,
498         RPC_DC_SETLIGHTSOURCE,
499         RPC_DC_SETLIGHTINTENSITY,
500         RPC_DC_BRIGTENOBJ,
501         RPC_DC_ENABLEANTIBANDING,
502         RPC_DC_ENABLESTROBE,
503         RPC_DC_SETIMGEFFECT,
504         RPC_DC_ADJUSTCONTRAST,
505         RPC_DC_ADJUST_CR,
506         RPC_DC_ADJUST_CB,
507         RPC_DC_ADJUST_BRIGHT
508 }RPC_DC_FUNCTION_E;
509
510 //End CR9397
511
512
513 typedef enum
514 {
515     RPC_FFS_CLOSE,
516     RPC_FFS_GET_LENGTH,
517     RPC_FFS_CREATE,
518     RPC_FFS_SEEK,
519     RPC_FFS_READ,
520     RPC_FFS_WRITE,
521     RPC_FFS_DELETE,
522     RPC_FFS_RENAME,
523     RPC_FFS_CHECK_EXIST,
524     RPC_FFS_FIND_FIRST,
525     RPC_FFS_FIND_NEXT,
526     RPC_FFS_CREATE_DIR,
527     RPC_FFS_DIR,
528     RPC_FFS_CD,
529     RPC_FFS_DELETE_DIR,
530     RPC_FFS_FOPEN,
531     RPC_FFS_FCLOSE,
532     RPC_FFS_FREAD,
533     RPC_FFS_FWRITE,
534     RPC_FFS_FSEEK,
535     RPC_FFS_FTELL,
536     RPC_FFS_FEOF,
537     RPC_FFS_FORMAT,
538     RPC_FFS_FREE_SPACE,
539     RPC_FFS_USED_SPACE
540 }RPC_FFS_FUNCTION_E;
541
542 //
543 // The subtype of DIAG_FORCE_ON_CELLS_F Command
544 //
545 typedef enum
546 {
547     FORCE_ON_CELLS          = 0,
548     CANCEL_FORCE_ON_CELLS   = 1
549 }FORCE_ON_CELLS_TYPE_E;
550
551
552 #define FORCE_ON_CELLS_NUM_MAX       6
553
554 typedef struct
555 {
556     MSG_HEAD_T      msg_head;
557     
558     // The param is valid when the subtype is FORCE_ON_CELLS
559     uint16          cell_number_and_status;
560     uint16          cell_list[ FORCE_ON_CELLS_NUM_MAX ];
561         uint16                  sim_no;
562 }MSG_FORCE_ON_CELLS_T;
563
564 typedef struct
565 {
566     MSG_HEAD_T      msg_head;
567     
568     uint32          batt_voltage;
569 }MSG_POWER_SUPPLY_T;
570
571
572 typedef enum _TOOL_TV_MSG_ID_E
573 {
574     TOOL_TV_SET_FREQ = 0,              // ÉèÖÃƵµã
575     TOOL_TV_GET_DEMODULATION,          // »ñµÃ½âµ÷ÎļþÐÅÏ¢
576     TOOL_TV_GET_FREQERROR,             // »ñµÃƵÂÊÆ«²î
577     TOOL_TV_GET_RSSI,                  // »ñµÃRSSI´óС
578     TOOL_TV_GET_BLOCKERROR,            // »ñµÃ½ÓÊÕµ½µÄ×Ü¿éÊý£¬³ö´íµÄ×Ü¿éÊý
579     TOOL_TV_SET_REGISTER,              // Ð´Èë¼Ä´æÆ÷Öµ
580     TOOL_TV_GET_REGISTER,              // ¶ÁÈ¡¼Ä´æÆ÷Öµ
581     TOOL_TV_GET_PLL,                   // ¶ÁÈ¡PLLµÄËø¶¨ÐÅÏ¢
582     TOOL_TV_RESET_MODE,                // ÉèÖÃSC6600Vģʽ
583     TOOL_TV_GET_MODE,                  // ²éѯµ±Ç°SC6600VµÄģʽ
584     TOOL_TV_BB_SHOW_PICTURE,           // ¿ØÖÆLCD
585     TOOL_TV_START_RAM_ROM_TEST,        // ²âÊÔRAM/ROM
586     TOOL_TV_DISPLAY_PICTURE,           // ÏÔʾͼƬ
587     TOOL_TV_PERIPHERAL_TEST,           // Peripheral²âÊÔ
588     TOOL_TV_START_AV_DECODE_TEST,      // ·¢ÆðAudio Vedio Decode²âÊÔ
589     TOOL_TV_GET_AV_DECODE_TEST_STATE,  // ²éѯ²âÊÔ״̬,È·ÈÏÊÇ·ñ²âÊÔÍê³É
590     TOOL_TV_GET_AV_DECODE_TEST_RESULT, // Audio Vedio Decode²âÊÔ½á¹û
591     TOOL_TV_START_CMMB_DEMOD,          // ·¢ÆðCMMB Demod²âÊÔ
592     TOOL_TV_START_DATA_DISPLAY,        // ¿ªÊ¼Êý¾Ý»Ø·Å
593     TOOL_TV_LCD_DISPLAY,               // LCDÏÔʾ¿ØÖÆ
594     TOOL_TV_READ_NV,                   // ¶ÁNV²ÎÊý
595     TOOL_TV_WRITE_NV,                  // Ð´NV²ÎÊý
596     TOOL_TV_GET_SERVICE_INFO,          // »ñȡƵµã¼°ÆµµÀÐÅÏ¢
597     TOOL_TV_PLAY_BY_PARAM,             // ¸ù¾Ý¸ø¶¨Æµµã¼°ÆµµÀÐÅÏ¢½øÐв¥·Å
598     TOOL_TV_SEARCH_NETWORK,            // ËÑË÷ƵµÀ
599     TOOL_TV_SMD_CHECK,                 // SMD¼ì²â
600
601     TOOL_TV_CLOSE_WAITING_WIN,         // ¹Ø±ÕµÈ´ý´°¿Ú(·Ç¹¤¾ßÃüÁî)
602     TOOL_TV_CMD_INVALID                // ÎÞЧÃüÁî
603 } TOOL_TV_MSG_ID_E;
604
605 typedef enum
606 {
607     DIAG_AP_CMD_ADC  = 0x0001,
608     MAX_DIAG_AP_CMD
609 } DIAG_AP_CMD_E;
610
611 typedef struct {
612     uint16  cmd;        // DIAG_AP_CMD_E
613     uint16  length;   // Length of structure 
614 } TOOLS_DIAG_AP_CMD_T;
615
616 typedef struct {
617     uint32 operate; // 0: Get ADC   1: Load ADC    2: Save ADC 
618     uint32 parameters[12];
619 }TOOLS_AP_ADC_REQ_T;
620
621 typedef struct {
622     uint16 status;   // ==0: success, != 0: fail
623     uint16 length;   // length of  result
624 } TOOLS_DIAG_AP_CNF_T;
625
626 /**---------------------------------------------------------------------------*
627  **                         Compiler Flag                                     *
628  **---------------------------------------------------------------------------*/
629 #ifdef __cplusplus
630     }
631 #endif
632 #endif      /*End cmddef.h*/