source: svn/newcon3bcm2_21bu/dst/dmw/src/EPG/DMW_EIA608B.h @ 22

Last change on this file since 22 was 22, checked in by phkim, 11 years ago
  1. phkim
  2. newcon3sk 를 kctv 로 브랜치 함
  • Property svn:executable set to *
File size: 6.6 KB
Line 
1#ifndef         _EIA608B_H_
2#define         _EIT608B_H_
3
4//#include "DMW_EpgStructsDef.h"
5#include "DHL_Types.h"
6
7#ifdef __cplusplus
8extern "C" {
9#endif
10
11typedef struct DescKeyword
12{
13        UINT8        hexCode;
14        const UINT8 *keyWord;
15}DescKeyword_t;
16
17/*Language for Audio Services*/
18typedef enum AudioLanguage
19{
20        AL_UNKNOWN = 0,
21        AL_AENGLISH = 1,
22        AL_SPANISH = 2,
23        AL_FRENCH =3,
24        AL_GERMAN = 4,
25        AL_ITALIAN = 5,
26        AL_OTHER = 6,
27        AL_NONE= 7
28}AudioLanguage;
29
30typedef enum AudioType1
31{
32        AT_UNKNOWN = 0,
33        AT_MONO = 1,
34        AT_SIMUL_STEREO = 2,
35        AT_TRUE_STEREO = 3,
36        AT_STEREO_SURROUND = 4,
37        AT_DATA_SERVICE = 5,
38        AT_OTHER = 6,
39        AT_NONE = 7,
40       
41        /*Second Audio Program Only*/
42       
43        AT_VIDEO_DESCRIPTION = 8,
44        AT_NON_PROGRAM_AUDIO = 9,
45        AT_SPECIAL_EFFECTS = 10,
46}AudioType1;
47
48
49#define programNameReceiveOk            0x01
50#define programTypeReceiveOk            0x02
51#define lengthTimeInShowReceiveOk       0x04
52#define programIdReceiveOk                      0x08
53#define allReceiveOk                            0x0f
54#define sosoOK                                          0x0D
55
56typedef struct NtscBasicEpgInfo {
57       
58        /*It is from ProgramIdentificationNumber : start time & date*/
59        UINT8   startMinute;
60        UINT8   startHour;     
61        UINT8   startDate;     
62        UINT8   startMonth;     
63        UINT8   bTapeDelay;             /*determine if an offest is necessary because of local station tape delay*/
64
65        /*It is from LengthTimeInShow : scheduled length of the program ,elapsed time*/ 
66        UINT8   minLength;             
67        UINT8   hourLength;
68        UINT8   minElapsed;     
69        UINT8   hourElapsed;
70        UINT8   secElapsed;
71       
72        /*It is from ProgramName*/
73        UINT8   programNameLength;
74        UINT8   programName[32];
75       
76        /*It is from ProgramType*/
77        UINT8   programType[32];
78       
79        struct NtscBasicEpgInfo         *pNext;
80        UINT8   receiveStatus;
81}NtscBasicEpgInfo;     
82
83typedef struct NtscEpgInfoHeader {
84        NtscBasicEpgInfo        *pNext;
85        int                                     iElemCount;
86        UINT8                           iInternalVersion;   
87} NtscEpgInfoHeader;
88
89typedef struct NtscCaptionInfo {
90               
91        /*It is from CaptionServices*/
92        UINT8 capLanguage[8];
93        UINT8 capServiceType[8];
94       
95} NtscCaptionInfo;     
96
97
98typedef struct NtscAudioInfo {
99       
100        /*It is from AudioServices*/
101        UINT8 mainAudioLanguage;
102        UINT8 mainAudioType;   
103        UINT8 sapLanguage;     
104        UINT8 sapType;
105       
106} NtscAudioInfo;
107
108
109typedef struct NtscCGMSA
110{
111        /*It is from CopyGenerationManagementSystemA*/
112        UINT8 CGMS_A;   /*Copy Generation Management System for Analog*/
113        UINT8 APS;              /*Analog Protection System*/
114        UINT8 ASB;              /*Analog Source Bit*/
115
116}NtscCGMSA;
117
118typedef struct NtscAspectRatioInfo {
119               
120        /*It is from AspectRatioInformation*/
121        UINT8 startLine;
122        UINT8 endLine;
123        UINT8 squeezed;
124       
125}NtscAspectRatioInfo;
126
127       
128typedef struct NtscTimeInfo {
129        /*It is from TimeOfDay*/
130        UINT8   iMinute;
131        UINT8   iHour; 
132        UINT8   iDate; 
133        UINT8   iMonth; 
134        UINT8   iDay;
135        UINT8   iYear;
136       
137        UINT8   bDaylightSaving;
138        UINT8   bFeb28or29;
139        UINT8   bSecondReset;
140        UINT8   bTapeDelay;
141       
142        /*It is from Local Time Zone & DST USE*/
143        UINT8 timeZoneOffset;
144        UINT8 daylightSaving;
145} NtscTimeInfo;
146       
147typedef struct NtscProgramDescription {
148        UINT8   row[8][32];
149} NtscProgramDescription;
150
151typedef struct NtscChannelInfo {
152       
153        /*It is from Network Name*/
154        UINT8   networkNameLength;
155        UINT8   networkName[32];
156       
157        /*It is from Call Letters.*/
158        UINT8   stationId[6];
159       
160        /*It is from Transmission Signal Identifier*/
161        UINT16 tsid;
162       
163        /*It is from Tape Delay*/
164        UINT8   tapeMinute;
165        UINT8   tapeHour;
166       
167} NtscChannelInfo;
168
169typedef enum {
170        xdsProgramIdentificationNumber=0,
171        xdsProgramName,
172        xdsNetworkName,
173        xdsContentAdvisory         
174} EpgNtscPacketType;
175
176
177typedef enum 
178{
179        US_Entire_Audience              = 0x0,
180        US_Children                             = 0x1,
181        US_MPAA                                 = 0x2,
182        CANADA_English                  = 0x3,
183        CANADA_French                   = 0x4,
184        /*reserved*/
185        /*reserved*/
186        NO_INFORMATION                  = 0x7
187       
188} rating_type_k;
189
190typedef struct
191{
192        rating_type_k   ratingType;
193        UINT8   ratingValue;            /*      : dimention 0 or 5 or 7*/
194        UINT8   FV;     /*Fantasy Violence      : dimention 6*/
195        UINT8   V;      /*Violence                      : dimention 4*/
196        UINT8   S;      /*Sex                           : dimention 3*/
197        UINT8   L;      /*Language                      : dimention 2*/
198        UINT8   D;      /*Dialogue                      : dimention 1*/
199
200} NtscRatingInfo;
201
202
203/*EIA608B API Declaration (for users)*/
204STATUS DMW_608B_GetCaptionInfo ( NtscCaptionInfo *pCaptionInfo );
205STATUS DMW_608B_GetChannelInfo ( NtscChannelInfo *pNtscChannelInfo );
206STATUS DMW_608B_GetProgramDescription( NtscProgramDescription *pDescription );
207STATUS DMW_608B_GetAudioInfo ( NtscAudioInfo *pAudioInfo );
208STATUS DMW_608B_GetTimeInfo( NtscTimeInfo *pTimeInfo );
209STATUS DMW_608B_GetAspectRatioInfo( NtscAspectRatioInfo *pAspectRatioInfo );
210STATUS DMW_608B_GetProgramDescription( NtscProgramDescription *pDescription );
211
212STATUS DMW_608B_GetRating( NtscRatingInfo *pRating );
213void DMW_608B_SetValidRatingTimeout(UINT32 timeout); /*the unit of timeout is msec.*/
214
215STATUS DMW_608B_InitNtscEpgDb();
216void DMW_608B_CloseNtscEpgDb();
217
218/*It will be used by Epg task..for constructing epg db.*/
219STATUS DMW_608B_GetProgramInfo ( NtscBasicEpgInfo **aNtscProgramInfo , int *iNtscProgramInfoCount , int iTimeOut );
220STATUS DMW_608B_FreeProgramInfo( NtscBasicEpgInfo *aNtscProgramInfo );
221
222
223/*EIA608B local function declaration.*/
224
225void ProgramIdentificationNumber( UINT8 *inBuff, UINT8 inSize);
226void LengthTimeInShow ( UINT8 *inBuff , UINT8 inSize);
227void ProgramName( UINT8 *inBuff , UINT8 inSize);
228const UINT8 * DescriptiveKeyword( UINT8 iHexCode );
229void ProgramType( UINT8 *inBuff , UINT8 inSize );
230void ContentAdvisory ( UINT8 *inBuff , UINT8 inSize );
231void AudioServices ( UINT8      *inBuff , UINT8 inSize );
232void CaptionServices ( UINT8 *inBuff , UINT8 inSize );
233void CopyGenerationManagementSystemA( UINT8 *inBuff , UINT8 inSize );
234void AspectRatioInformation( UINT8 *inBuff , UINT8 inSize);
235void CompositePacket1( UINT8 *inBuff , UINT8 inSize );
236void CompositePacket2( UINT8 *inBuff , UINT8 inSize );
237void NetworkName ( UINT8 *inBuff , UINT8 inSize );
238void CallLetters ( UINT8 *inBuff , UINT8 inSize );
239void TimeOfDay( UINT8 *inBuff , UINT8 inSize );
240void TransmissionSignalIdentifier ( UINT8 *inBuff , UINT8 inSize );
241void TimeOfDelay( UINT8 *inBuff , UINT8 inSize );
242void ImpulseCaptureID( UINT8 *inBuff , UINT8 inSize );
243void SupplementDataLocation (UINT8 *inBuff , UINT8 inSize);
244void LocalTimeZone_DSTUse (UINT8 *inBuff , UINT8 inSize );
245void OutOfBandChannelNumber( UINT8 *inBuff , UINT8 inSize );
246void ChannelMapPointer( UINT8 *inBuff , UINT8 inSize );
247void ChannelMapHeaderPacket( UINT8 *inBuff , UINT8 inSize );
248void ChannelMapPacket( UINT8 *inBuff , UINT8 inSize );
249void NationalWeatherServiceCode( UINT8 *inBuff , UINT8 inSize );
250void TapeDelay ( UINT8 *inBuff , UINT8 inSize );
251
252
253
254void ProgramDescription( UINT8 *inBuff , UINT8 inSize , UINT8 rowIndex );
255BOOLEAN DMW_608B_IsCurrentOnlyMode();
256
257#ifdef __cplusplus
258}
259#endif
260
261
262#endif
Note: See TracBrowser for help on using the repository browser.