summaryrefslogtreecommitdiffstats
path: root/firmware
diff options
context:
space:
mode:
authorAidan MacDonald <amachronic@protonmail.com>2022-01-02 13:09:08 +0000
committerAidan MacDonald <amachronic@protonmail.com>2022-01-02 20:11:03 +0000
commit83c23983841fd363a5a2c0e5cbd194110025226c (patch)
tree84fc753c07d29b9e8edc68d9d77665be885cc6dd /firmware
parentaf872b54ec3f8f7ad6ec111e4fe80dd2c7ac9946 (diff)
downloadrockbox-83c23983841fd363a5a2c0e5cbd194110025226c.tar.gz
rockbox-83c23983841fd363a5a2c0e5cbd194110025226c.zip
x1000: Fix USB connection problems in bootloader
This problem actually had nothing to do with USB boot; it's because the cable is plugged in when the USB mode menu item is selected. The USB thread detected the select button press and went into charge-only mode (as it usually does when you hold down a key in Rockbox). This is fixed by having the USB thread ignore most keys in the bootloader. USB connect events are delivered via the button queue, and there were also cases where the connection could be missed if the event happened within another UI screen. This should also be fixed. Change-Id: I077d705a6ac845c8713219eee45d26aa6addfa61
Diffstat (limited to 'firmware')
-rw-r--r--firmware/export/config/erosqnative.h5
-rw-r--r--firmware/export/config/fiiom3k.h5
-rw-r--r--firmware/export/config/shanlingq1.h5
3 files changed, 15 insertions, 0 deletions
diff --git a/firmware/export/config/erosqnative.h b/firmware/export/config/erosqnative.h
index 17a2b250f2..a76e8f6426 100644
--- a/firmware/export/config/erosqnative.h
+++ b/firmware/export/config/erosqnative.h
@@ -122,6 +122,11 @@
#define USB_WRITE_BUFFER_SIZE (128 * 1024)
#endif
+#ifdef BOOTLOADER
+/* Ignore on any key can cause surprising USB issues in the bootloader */
+# define USBPOWER_BTN_IGNORE (~(BUTTON_PREV|BUTTON_NEXT))
+#endif
+
/* Rockbox capabilities */
#define HAVE_VOLUME_IN_LIST
#define HAVE_FAT16SUPPORT
diff --git a/firmware/export/config/fiiom3k.h b/firmware/export/config/fiiom3k.h
index 558ff41dd7..45c2150208 100644
--- a/firmware/export/config/fiiom3k.h
+++ b/firmware/export/config/fiiom3k.h
@@ -123,6 +123,11 @@
#define USB_WRITE_BUFFER_SIZE (128 * 1024)
#endif
+#ifdef BOOTLOADER
+/* Ignore on any key can cause surprising USB issues in the bootloader */
+# define USBPOWER_BTN_IGNORE (~(BUTTON_VOL_UP|BUTTON_VOL_DOWN))
+#endif
+
/* Rockbox capabilities */
#define HAVE_FAT16SUPPORT
#define HAVE_ALBUMART
diff --git a/firmware/export/config/shanlingq1.h b/firmware/export/config/shanlingq1.h
index 18786e9a4b..1355c1824e 100644
--- a/firmware/export/config/shanlingq1.h
+++ b/firmware/export/config/shanlingq1.h
@@ -113,6 +113,11 @@
#define USB_WRITE_BUFFER_SIZE (128 * 1024)
#endif
+#ifdef BOOTLOADER
+/* Ignore on any key can cause surprising USB issues in the bootloader */
+# define USBPOWER_BTN_IGNORE (~(BUTTON_PREV|BUTTON_NEXT))
+#endif
+
/* Rockbox capabilities */
#define HAVE_FAT16SUPPORT
#define HAVE_ALBUMART