source: trunk/reader-common.h@ 1389

Last change on this file since 1389 was 1389, checked in by landlord, 12 years ago

Backport from ump trunk 1520

File size: 1.9 KB
Line 
1#define ADDRLEN 4 // Address length in EMM commands
2#define MAX_PROV 16
3#define SCT_LEN(sct) (3+((sct[1]&0x0f)<<8)+sct[2])
4#define MAX_LEN 256
5
6//Warning: OK = 0 and ERROR = 1 in csctapi !!!
7#define SKIPPED 2
8#define OK 1
9#define ERROR 0
10
11#include "atr.h"
12
13
14// reader-irdeto
15int irdeto_card_init(ATR atr);
16int irdeto_do_ecm(ECM_REQUEST *);
17int irdeto_do_emm(EMM_PACKET *);
18int irdeto_card_info(void);
19
20// reader-viaccess
21int viaccess_card_init(ATR atr);
22int viaccess_do_ecm(ECM_REQUEST *);
23int viaccess_do_emm(EMM_PACKET *);
24int viaccess_card_info(void);
25
26// reader-videoguard
27int videoguard_card_init(ATR atr);
28int videoguard_do_ecm(ECM_REQUEST *);
29int videoguard_do_emm(EMM_PACKET *);
30int videoguard_card_info(void);
31
32// reader-cryptoworks
33int cryptoworks_card_init(ATR atr);
34int cryptoworks_do_ecm(ECM_REQUEST *);
35int cryptoworks_do_emm(EMM_PACKET *);
36int cryptoworks_card_info(void);
37int CheckSctLen(const uchar *, int);
38
39// reader-seca
40int seca_card_init(ATR atr);
41int seca_do_ecm(ECM_REQUEST *);
42int seca_do_emm(EMM_PACKET *);
43int seca_card_info(void);
44
45// reader-nds
46int nds_card_init(ATR atr, int);
47int nds_do_ecm(ECM_REQUEST *);
48int nds_do_emm(EMM_PACKET *);
49int nds_card_info(void);
50
51// reader nagra2/3
52int nagra2_card_init(ATR atr);
53int nagra2_do_ecm(ECM_REQUEST *er);
54int nagra2_card_info(void);
55int nagra2_do_emm(EMM_PACKET *);
56void nagra2_post_process();
57
58// reader-conax
59int conax_card_init(ATR atr);
60int conax_do_ecm(ECM_REQUEST *);
61int conax_do_emm(EMM_PACKET *);
62int conax_card_info(void);
63
64// reader-dre
65int dre_card_init(ATR atr);
66int dre_do_ecm(ECM_REQUEST *);
67int dre_do_emm(EMM_PACKET *);
68int dre_card_info(void);
69
70#define get_atr \
71 unsigned char atr[64]; \
72 unsigned int atr_size; \
73 ATR_GetRaw(&newatr, atr, &atr_size);
74
75#define get_hist \
76 unsigned char hist[64]; \
77 unsigned int hist_size; \
78 ATR_GetHistoricalBytes(&newatr, hist, &hist_size);
79
Note: See TracBrowser for help on using the repository browser.