summaryrefslogtreecommitdiff
path: root/firmware/export/usb.h
diff options
context:
space:
mode:
authorTorne Wuff <torne@wolfpuppy.org.uk>2010-06-05 20:43:30 +0000
committerTorne Wuff <torne@wolfpuppy.org.uk>2010-06-05 20:43:30 +0000
commit2eb01425877347f601b1f8b03e07dcb2d690d6d9 (patch)
tree0a589ee0321956d95548261fe2bddfa101356b06 /firmware/export/usb.h
parent47181b8b9b0e3e914243a463ad02a2eceab61c6e (diff)
downloadrockbox-2eb01425877347f601b1f8b03e07dcb2d690d6d9.tar.gz
rockbox-2eb01425877347f601b1f8b03e07dcb2d690d6d9.zip
New USB charging system, part 2 - "Force" charging mode
Enable support for the "force" mode of USB charging. This should work on Gigabeat S and Nano2g (and any other future target which has a RB usb stack and supports charging) - if a host connection is not detected within 10 seconds of USB insertion, assume that the connected device is an AC charger and charge anyway, if the user has specified "force" as the mode. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26594 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware/export/usb.h')
-rw-r--r--firmware/export/usb.h10
1 files changed, 8 insertions, 2 deletions
diff --git a/firmware/export/usb.h b/firmware/export/usb.h
index d544f5cab1..55b5f2cffb 100644
--- a/firmware/export/usb.h
+++ b/firmware/export/usb.h
@@ -52,6 +52,9 @@ enum {
52 USB_REQUEST_REBOOT, /* Event */ 52 USB_REQUEST_REBOOT, /* Event */
53#endif 53#endif
54 USB_QUIT, /* Event */ 54 USB_QUIT, /* Event */
55#if defined(HAVE_USB_CHARGING_ENABLE) && defined(HAVE_USBSTACK)
56 USB_CHARGER_UPDATE, /* Event */
57#endif
55}; 58};
56 59
57#ifdef HAVE_USB_POWER 60#ifdef HAVE_USB_POWER
@@ -156,8 +159,11 @@ enum {
156 * or target-specific code on others 159 * or target-specific code on others
157 */ 160 */
158void usb_charging_enable(int state); 161void usb_charging_enable(int state);
159#endif 162#ifdef HAVE_USBSTACK
160#endif 163void usb_charger_update(void);
164#endif /* HAVE_USBSTACK */
165#endif /* HAVE_USB_CHARGING_ENABLE */
166#endif /* HAVE_USB_POWER */
161#ifdef HAVE_USBSTACK 167#ifdef HAVE_USBSTACK
162void usb_signal_transfer_completion( 168void usb_signal_transfer_completion(
163 struct usb_transfer_completion_event_data *event_data); 169 struct usb_transfer_completion_event_data *event_data);