aboutsummaryrefslogtreecommitdiff
path: root/stmhal/usrsw.h
diff options
context:
space:
mode:
authorDamien George2014-03-30 00:00:15 +0000
committerDamien George2014-03-30 00:00:15 +0000
commit038df4318362325b5b6b77f7582fb6373a240f3c (patch)
tree412143786f23fc67681f44f0673ee72f2a6a7f0d /stmhal/usrsw.h
parentd40d8f1e168c5bc3cf52f51d9592425574e7e6a9 (diff)
stmhal: Implement selector for USB device mode; improve boot up.
Can now choose at boot up whether the USB device is CDC+MSC or CDC+HID. Choice is made by an option in boot.py, with default being CDC+MSC. HID+MSC is not currently supported, but should be easy to implement. Boot up now has ability to change the reset mode: hold down USR switch while booting and LEDs will count from 1 to 7 to indicate the boot mode. Release USR when correct mode is selected. Current modes are 1 (normal boot), 2 (safe mode), 3 (reset FS mode).
Diffstat (limited to 'stmhal/usrsw.h')
-rw-r--r--stmhal/usrsw.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/stmhal/usrsw.h b/stmhal/usrsw.h
index 2da8f069b..b1b838653 100644
--- a/stmhal/usrsw.h
+++ b/stmhal/usrsw.h
@@ -1,3 +1,4 @@
+void switch_init0(void);
void switch_init(void);
int switch_get(void);