Mercurial > pt1
annotate driver/pt1_tuner.h @ 64:98a92ce5382e
added fake support code for PT2. the PT2 part is not expected to work. be careful!
author | Yoshiki Yazawa <yaz@honeyplanet.jp> |
---|---|
date | Thu, 22 Oct 2009 02:18:12 +0900 |
parents | 07b2fc07ff48 |
children | 272a8fba970b |
rev | line source |
---|---|
0 | 1 #ifndef __PT1_TUNER_H__ |
2 #define __PT1_TUNER_H__ | |
3 /***************************************************************************/ | |
4 /* チューナ状態定義 */ | |
5 /***************************************************************************/ | |
64
98a92ce5382e
added fake support code for PT2. the PT2 part is not expected to work. be careful!
Yoshiki Yazawa <yaz@honeyplanet.jp>
parents:
9
diff
changeset
|
6 // SLEEPモード設定 |
0 | 7 enum { |
8 TYPE_SLEEP, | |
9 TYPE_WAKEUP | |
10 }; | |
11 | |
64
98a92ce5382e
added fake support code for PT2. the PT2 part is not expected to work. be careful!
Yoshiki Yazawa <yaz@honeyplanet.jp>
parents:
9
diff
changeset
|
12 // チューナパワーモード設定 |
0 | 13 enum { |
14 BIT_TUNER, | |
15 BIT_LNB_UP, | |
16 BIT_LNB_DOWN, | |
64
98a92ce5382e
added fake support code for PT2. the PT2 part is not expected to work. be careful!
Yoshiki Yazawa <yaz@honeyplanet.jp>
parents:
9
diff
changeset
|
17 BIT_RESET, |
98a92ce5382e
added fake support code for PT2. the PT2 part is not expected to work. be careful!
Yoshiki Yazawa <yaz@honeyplanet.jp>
parents:
9
diff
changeset
|
18 BIT_FRONTEND |
0 | 19 }; |
20 | |
21 // LNBパワー設定 | |
22 enum{ | |
23 LNB_OFF, // LNB OFF | |
24 LNB_11V, // +11 V | |
25 LNB_15V // +15 V | |
64
98a92ce5382e
added fake support code for PT2. the PT2 part is not expected to work. be careful!
Yoshiki Yazawa <yaz@honeyplanet.jp>
parents:
9
diff
changeset
|
26 }; |
0 | 27 |
28 enum{ // 電源/ハードウェアリセット | |
29 TUNER_POWER_OFF, // オフ/イネーブル | |
30 TUNER_POWER_ON_RESET_ENABLE, // オン/イネーブル | |
31 TUNER_POWER_ON_RESET_DISABLE // オン/ディセーブル | |
32 }; | |
64
98a92ce5382e
added fake support code for PT2. the PT2 part is not expected to work. be careful!
Yoshiki Yazawa <yaz@honeyplanet.jp>
parents:
9
diff
changeset
|
33 |
98a92ce5382e
added fake support code for PT2. the PT2 part is not expected to work. be careful!
Yoshiki Yazawa <yaz@honeyplanet.jp>
parents:
9
diff
changeset
|
34 enum { |
98a92ce5382e
added fake support code for PT2. the PT2 part is not expected to work. be careful!
Yoshiki Yazawa <yaz@honeyplanet.jp>
parents:
9
diff
changeset
|
35 PT1 = 0, |
98a92ce5382e
added fake support code for PT2. the PT2 part is not expected to work. be careful!
Yoshiki Yazawa <yaz@honeyplanet.jp>
parents:
9
diff
changeset
|
36 PT2, |
98a92ce5382e
added fake support code for PT2. the PT2 part is not expected to work. be careful!
Yoshiki Yazawa <yaz@honeyplanet.jp>
parents:
9
diff
changeset
|
37 }; |
98a92ce5382e
added fake support code for PT2. the PT2 part is not expected to work. be careful!
Yoshiki Yazawa <yaz@honeyplanet.jp>
parents:
9
diff
changeset
|
38 |
0 | 39 /***************************************************************************/ |
40 /* チューナ状態定義 */ | |
41 /***************************************************************************/ | |
42 #define MAX_BS_TS_ID 8 // TS-ID取得最大値 | |
43 #define MAX_ISDB_T_INFO 3 // 地デジ階層情報数 | |
44 #define MAX_ISDB_T_INFO_LEN 2 // 地デジ階層情報数 | |
45 /***************************************************************************/ | |
46 /* ISDB-S状態定義 */ | |
47 /***************************************************************************/ | |
48 typedef struct _ISDB_S_CH_TABLE{ | |
49 int channel ; // 入力チャンネル番号 | |
50 int real_chno ; // 実際のテーブル番号 | |
51 int slotno ; // スロット番号 | |
52 }ISDB_S_CH_TABLE ; | |
53 | |
54 /***************************************************************************/ | |
55 /* ISDB-S状態定義 */ | |
56 /***************************************************************************/ | |
57 typedef struct _ISDB_S_TS_ID{ | |
58 __u16 ts_id ; // TS-ID | |
59 __u16 dmy ; // PAD | |
60 __u8 low_mode ; // 低階層 モード | |
61 __u8 low_slot ; // 低階層 スロット数 | |
62 __u8 high_mode ; // 高階層 モード | |
63 __u8 high_slot ; // 高階層 スロット数 | |
64 }ISDB_S_TS_ID; | |
65 typedef struct _ISDB_S_TMCC{ | |
66 ISDB_S_TS_ID ts_id[MAX_BS_TS_ID]; // 相対TS番号nに対するTS ID情報 | |
67 #if 0 | |
68 __u32 indicator; // 変更指示 (5ビット) | |
69 __u32 emergency; // 起動制御信号 (1ビット) | |
70 __u32 uplink; // アップリンク制御情報 (4ビット) | |
71 __u32 ext; // 拡張フラグ (1ビット) | |
72 __u32 extdata[2]; // 拡張領域 (61ビット) | |
73 #endif | |
74 __u32 agc ; // AGC | |
75 __u32 clockmargin ; // クロック周波数誤差 | |
76 __u32 carriermargin ; // キャリア周波数誤差 | |
77 }ISDB_S_TMCC; | |
78 | |
79 // 階層情報 | |
80 typedef struct _ISDB_T_INFO{ | |
81 __u32 mode; // キャリア変調方式 (3ビット) | |
82 __u32 rate; // 畳込み符号化率 (3ビット) | |
83 __u32 interleave; // インターリーブ長 (3ビット) | |
84 __u32 segment; // セグメント数 (4ビット) | |
85 }ISDB_T_INFO; | |
86 | |
87 typedef struct _ISDB_T_TMCC { | |
88 #if 0 | |
89 __u32 sysid; // システム識別 (2ビット) | |
90 __u32 indicator; // 伝送パラメータ切り替え指標 (4ビット) | |
91 __u32 emergency; // 緊急警報放送用起動フラグ (1ビット) | |
92 #endif | |
93 ISDB_T_INFO info[MAX_ISDB_T_INFO]; | |
94 #if 0 | |
95 // カレント情報 | |
96 __u32 partial; // 部分受信フラグ (1ビット) | |
97 __u32 Phase; // 連結送信位相補正量 (3ビット) | |
98 __u32 Reserved; // リザーブ (12ビット) | |
99 #endif | |
100 __u32 cn[2] ; // CN | |
101 __u32 agc ; // AGC | |
102 __u32 clockmargin ; // クロック周波数誤差 | |
103 __u32 carriermargin ; // キャリア周波数誤差 | |
104 }ISDB_T_TMCC; | |
105 /***************************************************************************/ | |
106 /* チューナ状態定義 */ | |
107 /***************************************************************************/ | |
64
98a92ce5382e
added fake support code for PT2. the PT2 part is not expected to work. be careful!
Yoshiki Yazawa <yaz@honeyplanet.jp>
parents:
9
diff
changeset
|
108 extern void settuner_reset(void __iomem *, int, __u32, __u32); |
0 | 109 extern int tuner_init(void __iomem *, struct mutex *, int); |
110 extern void set_sleepmode(void __iomem *, struct mutex *, int, int, int); | |
111 | |
112 extern int bs_tune(void __iomem *, struct mutex *, int, int, ISDB_S_TMCC *); | |
113 extern int ts_lock(void __iomem *, struct mutex *, int, __u16); | |
114 | |
115 extern int isdb_t_tune(void __iomem *, struct mutex *, int, int, ISDB_T_TMCC *); | |
116 extern int isdb_t_frequency(void __iomem *, struct mutex *, int, int, int); | |
9
07b2fc07ff48
updated to current driver to support signal strength.
Yoshiki Yazawa <yaz@honeyplanet.jp>
parents:
0
diff
changeset
|
117 extern int isdb_s_read_signal_strength(void __iomem *, struct mutex *, int); |
07b2fc07ff48
updated to current driver to support signal strength.
Yoshiki Yazawa <yaz@honeyplanet.jp>
parents:
0
diff
changeset
|
118 extern int isdb_t_read_signal_strength(void __iomem *, struct mutex *, int); |
07b2fc07ff48
updated to current driver to support signal strength.
Yoshiki Yazawa <yaz@honeyplanet.jp>
parents:
0
diff
changeset
|
119 |
0 | 120 #endif |