Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Teensy 3.5: do not restart USB stack after wakeup #19269

Merged
merged 1 commit into from
Dec 9, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions platforms/chibios/boards/PJRC_TEENSY_3_5/board/board.mk
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
include $(CHIBIOS_CONTRIB)/os/hal/boards/PJRC_TEENSY_3_5/board.mk

# List of all the board related files.
BOARDSRC += $(BOARD_PATH)/board/extra.c

# Required include directories
BOARDINC += $(BOARD_PATH)/board

# Shared variables
ALLCSRC += $(BOARDSRC)
ALLINC += $(BOARDINC)
7 changes: 7 additions & 0 deletions platforms/chibios/boards/PJRC_TEENSY_3_5/board/extra.c
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#include <hal.h>

void restart_usb_driver(USBDriver *usbp) {
// Do nothing. Restarting the USB driver on the Teensy 3.6 breaks it,
// resulting in a keyboard which can wake up a PC from Suspend-to-RAM, but
// does not actually produce any keypresses until you un-plug and re-plug.
}