1 /***************************************************************************
3 * Open \______ \ ____ ____ | | _\_ |__ _______ ___
4 * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
5 * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
6 * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
10 * Copyright (C) 2005 by Linus Nielsen Feltzing
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.
15 * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
16 * KIND, either express or implied.
18 ****************************************************************************/
25 /* The following functions may either be implemented by an optimised driver
26 in the target tree, or by the generic drivers/pcf50606.c */
28 void pcf50606_init(void);
29 int pcf50606_write_multiple(int address
, const unsigned char* buf
, int count
);
30 int pcf50606_write(int address
, unsigned char val
);
31 int pcf50606_read_multiple(int address
, unsigned char* buf
, int count
);
32 int pcf50606_read(int address
);
33 void pcf50606_set_usb_charging(bool on
);
34 bool pcf50606_usb_charging_enabled(void);
36 /* internal low level calls used by the eeprom driver for h300 */
37 void pcf50606_i2c_init(void);
38 void pcf50606_i2c_recalc_delay(int cpu_clock
);
39 void pcf50606_i2c_start(void);
40 void pcf50606_i2c_stop(void);
41 void pcf50606_i2c_ack(bool ack
);
42 bool pcf50606_i2c_getack(void);
43 #if defined(IRIVER_H300_SERIES)
44 /* USB charging support */
45 void pcf50606_i2c_outb(unsigned char byte
);
46 unsigned char pcf50606_i2c_inb(bool ack
);
49 #if (defined(IAUDIO_X5) || defined(IAUDIO_M5)) && !defined (SIMULATOR)
50 void pcf50606_reset_timeout(void);
53 #endif /* PCF50606_H */