summaryrefslogtreecommitdiff
path: root/firmware/target/sh/archos/ondio/usb-ondio.c
diff options
context:
space:
mode:
Diffstat (limited to 'firmware/target/sh/archos/ondio/usb-ondio.c')
-rw-r--r--firmware/target/sh/archos/ondio/usb-ondio.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/firmware/target/sh/archos/ondio/usb-ondio.c b/firmware/target/sh/archos/ondio/usb-ondio.c
index c856f3ae2c..b370fec3d9 100644
--- a/firmware/target/sh/archos/ondio/usb-ondio.c
+++ b/firmware/target/sh/archos/ondio/usb-ondio.c
@@ -23,10 +23,11 @@
23#include "cpu.h" 23#include "cpu.h"
24#include "hwcompat.h" 24#include "hwcompat.h"
25#include "system.h" 25#include "system.h"
26#include "usb.h"
26 27
27bool usb_detect(void) 28int usb_detect(void)
28{ 29{
29 return (adc_read(ADC_USB_POWER) <= 512) ? true : false; 30 return (adc_read(ADC_USB_POWER) <= 512) ? USB_INSERTED : USB_EXTRACTED;
30} 31}
31 32
32void usb_enable(bool on) 33void usb_enable(bool on)