diff options
author | Dave Chapman <dave@dchapman.com> | 2006-02-13 13:48:08 +0000 |
---|---|---|
committer | Dave Chapman <dave@dchapman.com> | 2006-02-13 13:48:08 +0000 |
commit | 9581ad39ec15cf20350d01d2787dea0c7db6074d (patch) | |
tree | 28ead339e852346eb9f4e947e3494353cb687d72 /firmware/export/wm8758.h | |
parent | b55f20a12d6b68d0f4f53ab19db76e8b5388d8bb (diff) | |
download | rockbox-9581ad39ec15cf20350d01d2787dea0c7db6074d.tar.gz rockbox-9581ad39ec15cf20350d01d2787dea0c7db6074d.zip |
iPod: Audio driver for iPod Video/5G. Rename wm8971_* functions to wmcodec_* to enable unification of the audio code for WM codecs
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@8676 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware/export/wm8758.h')
-rw-r--r-- | firmware/export/wm8758.h | 74 |
1 files changed, 74 insertions, 0 deletions
diff --git a/firmware/export/wm8758.h b/firmware/export/wm8758.h new file mode 100644 index 0000000000..adc17f86d7 --- /dev/null +++ b/firmware/export/wm8758.h | |||
@@ -0,0 +1,74 @@ | |||
1 | /*************************************************************************** | ||
2 | * __________ __ ___. | ||
3 | * Open \______ \ ____ ____ | | _\_ |__ _______ ___ | ||
4 | * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ / | ||
5 | * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < < | ||
6 | * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \ | ||
7 | * \/ \/ \/ \/ \/ | ||
8 | * $Id$ | ||
9 | * | ||
10 | * Copyright (C) 2005 by Dave Chapman | ||
11 | * | ||
12 | * All files in this archive are subject to the GNU General Public License. | ||
13 | * See the file COPYING in the source tree root for full license agreement. | ||
14 | * | ||
15 | * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY | ||
16 | * KIND, either express or implied. | ||
17 | * | ||
18 | ****************************************************************************/ | ||
19 | |||
20 | #ifndef _WM8758_H | ||
21 | #define _WM8758_H | ||
22 | |||
23 | extern void wmcodec_reset(void); | ||
24 | extern int wmcodec_init(void); | ||
25 | extern void wmcodec_enable_output(bool enable); | ||
26 | extern int wmcodec_set_master_vol(int vol_l, int vol_r); | ||
27 | extern int wmcodec_set_mixer_vol(int channel1, int channel2); | ||
28 | extern void wmcodec_set_bass(int value); | ||
29 | extern void wmcodec_set_treble(int value); | ||
30 | extern int wmcodec_mute(int mute); | ||
31 | extern void wmcodec_close(void); | ||
32 | extern void wmcodec_set_nsorder(int order); | ||
33 | extern void wmcodec_set_sample_rate(int sampling_control); | ||
34 | |||
35 | extern void wmcodec_enable_recording(bool source_mic); | ||
36 | extern void wmcodec_disable_recording(void); | ||
37 | extern void wmcodec_set_recvol(int left, int right, int type); | ||
38 | extern void wmcodec_set_monitor(int enable); | ||
39 | |||
40 | #define RESET 0x00 | ||
41 | #define PWRMGMT1 0x01 | ||
42 | #define PWRMGMT2 0x02 | ||
43 | #define PWRMGMT3 0x03 | ||
44 | #define AINTFCE 0x04 | ||
45 | #define CLKCTRL 0x06 | ||
46 | #define SRATECTRL 0x07 | ||
47 | #define DACCTRL 0x0a | ||
48 | #define OUTCTRL 0x31 | ||
49 | #define LOUTMIX 0x32 | ||
50 | #define ROUTMIX 0x33 | ||
51 | |||
52 | #define LOUT1VOL 0x34 | ||
53 | #define ROUT1VOL 0x35 | ||
54 | #define LOUT2VOL 0x36 | ||
55 | #define ROUT2VOL 0x37 | ||
56 | |||
57 | #define PLLN 0x24 | ||
58 | #define PLLK1 0x25 | ||
59 | #define PLLK2 0x26 | ||
60 | #define PLLK3 0x27 | ||
61 | |||
62 | /* Register settings for the supported samplerates: */ | ||
63 | #define WM8758_8000HZ 0x4d | ||
64 | #define WM8758_12000HZ 0x61 | ||
65 | #define WM8758_16000HZ 0x55 | ||
66 | #define WM8758_22050HZ 0x77 | ||
67 | #define WM8758_24000HZ 0x79 | ||
68 | #define WM8758_32000HZ 0x59 | ||
69 | #define WM8758_44100HZ 0x63 | ||
70 | #define WM8758_48000HZ 0x41 | ||
71 | #define WM8758_88200HZ 0x7f | ||
72 | #define WM8758_96000HZ 0x5d | ||
73 | |||
74 | #endif /* _WM8758_H */ | ||