6 /* why someone has defined NUM someplace else is beyoung me.. */
10 CARD32 fcar
; /* 16 * fcar_Mhz */
11 CARD32 min_freq
; /* 16 * min_freq_Mhz */
12 CARD32 max_freq
; /* 16 * max_freq_Mhz */
14 CARD32 threshold1
; /* 16 * Value_Mhz */
15 CARD32 threshold2
; /* 16 * Value_Mhz */
26 /* all frequencies are in Mhz */
27 double f_rf
; /* frequency to tune to */
28 double f_if1
; /* first intermediate frequency */
29 double f_if2
; /* second intermediate frequency */
30 double f_ref
; /* reference frequency */
31 double f_ifbw
; /* bandwidth */
32 double f_step
; /* step */
48 void* afc_source
; /* The AFC source may be another chip like TDA988x */
51 CARD32 original_frequency
;
52 Bool afc_timer_installed
;
57 FI1236_parameters parm
;
58 int xogc
; /* for MT2032 */
65 CARD8 aux
; /* this is for MK3 tuners */
67 } FI1236Rec
, *FI1236Ptr
;
69 #define TUNER_TYPE_FI1236 0
70 #define TUNER_TYPE_FI1216 1
71 #define TUNER_TYPE_TEMIC_FN5AL 2
72 #define TUNER_TYPE_MT2032 3
73 #define TUNER_TYPE_FI1246 4
74 #define TUNER_TYPE_FI1256 5
75 #define TUNER_TYPE_FI1236W 6
76 #define TUNER_TYPE_FM1216ME 7
78 #define FI1236_ADDR(a) ((a)->d.SlaveAddr)
80 #define FI1236_ADDR_1 0xC6
81 #define FI1236_ADDR_2 0xC0
84 #define TUNER_JUST_BELOW 1
85 #define TUNER_JUST_ABOVE -1
87 #define TUNER_STILL_TUNING 5
90 FI1236Ptr
Detect_FI1236(I2CBusPtr b
, I2CSlaveAddr addr
);
91 void FI1236_set_tuner_type(FI1236Ptr f
, int type
);
92 void TUNER_set_frequency(FI1236Ptr f
, CARD32 frequency
);
93 void FI1236_tune(FI1236Ptr f
, CARD32 frequency
);
94 int FI1236_AFC(FI1236Ptr f
);
95 int TUNER_get_afc_hint(FI1236Ptr f
);
96 void fi1236_dump_status(FI1236Ptr f
);
98 #define FI1236SymbolsList \
100 "FI1236_set_tuner_type", \
101 "TUNER_set_frequency"
103 #define xf86_Detect_FI1236 ((FI1236Ptr (*)(I2CBusPtr, I2CSlaveAddr))LoaderSymbol("Detect_FI1236"))
104 #define xf86_FI1236_set_tuner_type ((void (*)(FI1236Ptr, int))LoaderSymbol("FI1236_set_tuner_type"))
105 #define xf86_TUNER_set_frequency ((void (*)(FI1236Ptr, CARD32))LoaderSymbol("TUNER_set_frequency"))
106 #define xf86_FI1236_AFC ((int (*)(FI1236Ptr))LoaderSymbol("FI1236_AFC"))
107 #define xf86_TUNER_get_afc_hint ((int (*)(FI1236Ptr))LoaderSymbol("TUNER_get_afc_hint"))
108 #define xf86_fi1236_dump_status ((void (*)(FI1236Ptr))LoaderSymbol("fi1236_dump_status"))