Commit FS#10413 by Michael Chicoine. Fixes upside down menu in mpegplayer when watch...
[kugel-rb.git] / firmware / target / arm / as3525 / ascodec-target.h
blob3464bbaa51f107a66095f8a728d997f2c405a4d1
1 /***************************************************************************
2 * __________ __ ___.
3 * Open \______ \ ____ ____ | | _\_ |__ _______ ___
4 * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
5 * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
6 * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
7 * \/ \/ \/ \/ \/
8 * $Id$
10 * Driver for AS3514 audio codec
12 * Copyright (c) 2007 Daniel Ankers
13 * Copyright (c) 2007 Christian Gmeiner
15 * This program is free software; you can redistribute it and/or
16 * modify it under the terms of the GNU General Public License
17 * as published by the Free Software Foundation; either version 2
18 * of the License, or (at your option) any later version.
20 * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
21 * KIND, either express or implied.
23 ****************************************************************************/
25 #ifndef _ASCODEC_TARGET_H
26 #define _ASCODEC_TARGET_H
28 #include "as3514.h"
30 /* Charge Pump and Power management Settings */
31 #define AS314_CP_DCDC3_SETTING \
32 ((0<<7) | /* CP_SW Auto-Switch Margin 0=200/300 1=150/255 */ \
33 (0<<6) | /* CP_on 0=Normal op 1=Chg Pump Always On */ \
34 (0<<5) | /* LREG_CPnot Always write 0 */ \
35 (0<<3) | /* DCDC3p BVDD setting 3.6/3.2/3.1/3.0 */ \
36 (1<<2) | /* LREG_off 1=Auto mode switching 0=Length Reg only*/\
37 (0<<0) ) /* CVDDp Core Voltage Setting 1.2/1.15/1.10/1.05*/
39 #define CVDD_1_20 0
40 #define CVDD_1_15 1
41 #define CVDD_1_10 2
42 #define CVDD_1_05 3
44 void ascodec_init(void);
46 int ascodec_write(unsigned int index, unsigned int value);
48 int ascodec_read(unsigned int index);
50 int ascodec_readbytes(int index, int len, unsigned char *data);
52 void ascodec_lock(void);
54 void ascodec_unlock(void);
56 #endif /* !_ASCODEC_TARGET_H */