Rev 3 | Rev 1063 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
80 | pj | 1 | #include "ll/sys/cdefs.h" |
2 | |||
3 | __BEGIN_DECLS |
||
4 | |||
2 | pj | 5 | /* DSP Registers */ |
6 | #define RESET 0x06 |
||
7 | #define READDATA 0x0A |
||
8 | #define WRITEBUFFERSTATUS 0x0C |
||
9 | #define DATAAVAILABLE 0x0E |
||
10 | #define ACK8 0x0E |
||
11 | #define ACK16 0x0F |
||
12 | |||
13 | /* DSP Commands */ |
||
14 | #define DSPCMD_DIRECTOUT 0x10 |
||
15 | #define DSPCMD_DIRECTIN 0x20 |
||
16 | #define DSPCMD_SETOUTRATE 0x41 |
||
17 | #define DSPCMD_SETINRATE 0x42 |
||
18 | #define DSPCMD_16BITIO 0xb0 |
||
19 | #define DSPCMD_8BITIO 0xC0 |
||
20 | #define SBIO_FIFOON 0x02 |
||
21 | #define SBIO_AUTOINIT 0x04 |
||
22 | #define SBIO_OUT 0x00 |
||
23 | #define SBIO_IN 0x08 |
||
24 | #define IOMODE_UNSIGNED 0x00 |
||
25 | #define IOMODE_SIGNED 0x10 |
||
26 | #define IOMODE_MONO 0x00 |
||
27 | #define IOMODE_STEREO 0x20 |
||
28 | #define DSPCMD_GETVER 0xE1 |
||
29 | #define DSPCMD_SPKON 0xD1 |
||
30 | #define DSPCMD_SPKOFF 0xD3 |
||
31 | #define DSPCMD_EXIT8 0xDA |
||
32 | #define DSPCMD_EXIT16 0xD9 |
||
33 | |||
34 | /* Mixer I/O registers */ |
||
35 | #define MIXERREGISTER 0x04 |
||
36 | #define MIXERDATA 0x05 |
||
37 | |||
38 | /* Mixer Registers */ |
||
39 | #define MIXER_RESET 0x00 |
||
40 | #define MIXER_OUTCTR 0x3c |
||
41 | #define MIXER_INCTRLEFT 0x3d |
||
42 | #define MIXER_INCTRRIGHT 0x3e |
||
43 | #define MIXER_MICLEV 0x3a |
||
44 | #define MIXER_AGC 0x43 |
||
45 | #define MIXER_IGCLEFT 0x3F |
||
46 | #define MIXER_IGCRIGHT 0x40 |
||
47 | |||
48 | #define MIXER_IRQREG 0x80 |
||
49 | #define MIXER_DMAREG 0x81 |
||
50 | #define MIXER_INTSTATUS 0x82 |
||
51 | |||
52 | WORD sb_probe (void); |
||
53 | BYTE sbdsp_read (WORD base); |
||
54 | void sbdsp_write (WORD base, BYTE c ); |
||
55 | BYTE sbmixer_read(WORD base, BYTE index); |
||
56 | void sbmixer_write(WORD base, BYTE index, BYTE c); |
||
57 | BYTE sbdsp_reset(WORD base); |
||
58 | |||
59 | /* OKKIO!!!! vanno tolti da qui!!!! */ |
||
60 | BYTE inpb(WORD addr); |
||
61 | void outpb(WORD addr, BYTE val); |
||
62 | |||
80 | pj | 63 | __END_DECLS |
64 |