summaryrefslogtreecommitdiffstats
path: root/firmware/target/sh/archos/recorder/usb-recorder.c
diff options
context:
space:
mode:
Diffstat (limited to 'firmware/target/sh/archos/recorder/usb-recorder.c')
-rw-r--r--firmware/target/sh/archos/recorder/usb-recorder.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/firmware/target/sh/archos/recorder/usb-recorder.c b/firmware/target/sh/archos/recorder/usb-recorder.c
index 7ed237068e..dfa8462203 100644
--- a/firmware/target/sh/archos/recorder/usb-recorder.c
+++ b/firmware/target/sh/archos/recorder/usb-recorder.c
@@ -22,10 +22,11 @@
#include "cpu.h"
#include "hwcompat.h"
#include "system.h"
+#include "usb.h"
-bool usb_detect(void)
+int usb_detect(void)
{
- return (adc_read(ADC_USB_POWER) > 500) ? true : false;
+ return (adc_read(ADC_USB_POWER) > 500) ? USB_INSERTED : USB_EXTRACTED;
}
void usb_enable(bool on)