1 | #ifndef __TDA9850_H__
|
---|
2 | #define __TDA9850_H__
|
---|
3 |
|
---|
4 | #include "xf86i2c.h"
|
---|
5 |
|
---|
6 | typedef struct {
|
---|
7 | I2CDevRec d;
|
---|
8 |
|
---|
9 | int mux;
|
---|
10 | int stereo;
|
---|
11 | int sap;
|
---|
12 | Bool mute;
|
---|
13 | Bool sap_mute;
|
---|
14 | } TDA9850Rec, *TDA9850Ptr;
|
---|
15 |
|
---|
16 | #define TDA9850_ADDR_1 0xB4
|
---|
17 |
|
---|
18 | TDA9850Ptr Detect_tda9850(I2CBusPtr b, I2CSlaveAddr addr);
|
---|
19 | Bool tda9850_init(TDA9850Ptr t);
|
---|
20 | void tda9850_setaudio(TDA9850Ptr t);
|
---|
21 | void tda9850_mute(TDA9850Ptr t, Bool mute);
|
---|
22 | void tda9850_sap_mute(TDA9850Ptr t, Bool sap_mute);
|
---|
23 | CARD16 tda9850_getstatus(TDA9850Ptr t);
|
---|
24 |
|
---|
25 | #define TDA9850SymbolsList \
|
---|
26 | "Detect_tda9850", \
|
---|
27 | "tda9850_init", \
|
---|
28 | "tda9850_setaudio", \
|
---|
29 | "tda9850_mute", \
|
---|
30 | "tda9850_sap_mute"
|
---|
31 |
|
---|
32 | #ifdef XFree86LOADER
|
---|
33 |
|
---|
34 | #define xf86_Detect_tda9850 ((TDA9850Ptr (*)(I2CBusPtr, I2CSlaveAddr))LoaderSymbol("Detect_tda9850"))
|
---|
35 | #define xf86_tda9850_init ((Bool (*)(TDA9850Ptr))LoaderSymbol("tda9850_init"))
|
---|
36 | #define xf86_tda9850_setaudio ((void (*)(TDA9850Ptr))LoaderSymbol("tda9850_setaudio"))
|
---|
37 | #define xf86_tda9850_mute ((void (*)(TDA9850Ptr, Bool))LoaderSymbol("tda9850_mute"))
|
---|
38 | #define xf86_tda9850_sap_mute ((void (*)(TDA9850Ptr, Bool))LoaderSymbol("tda9850_sap_mute"))
|
---|
39 | #define xf86_tda9850_getstatus ((CARD16 (*)(TDA9850Ptr))LoaderSymbol("tda9850_getstatus"))
|
---|
40 |
|
---|
41 | #else
|
---|
42 |
|
---|
43 | #define xf86_Detect_tda9850 Detect_tda9850
|
---|
44 | #define xf86_tda9850_init tda9850_init
|
---|
45 | #define xf86_tda9850_setaudio tda9850_setaudio
|
---|
46 | #define xf86_tda9850_mute tda9850_mute
|
---|
47 | #define xf86_tda9850_sap_mute tda9850_sap_mute
|
---|
48 | #define xf86_tda9850_getstatus tda9850_getstatus
|
---|
49 |
|
---|
50 | #endif
|
---|
51 |
|
---|
52 | #endif
|
---|