Skip to content

Commit 210bd6d

Browse files
committed
Run the USB interrupt handler from RAM
1 parent c604b30 commit 210bd6d

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/bin/main.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -130,8 +130,10 @@ mod app {
130130
}
131131
}
132132

133+
#[inline(never)]
134+
#[link_section = ".data.usb_handler"]
133135
#[task(binds = OTG_FS, local = [producer, usb_dev, serial])]
134-
fn otg_fs(cx: otg_fs::Context) {
136+
fn usb_handler(cx: usb_handler::Context) {
135137
let producer: &mut bbqueue::Producer<'static, BUFFER_SIZE> = cx.local.producer;
136138
let usb_dev: &mut UsbDevice<UsbBusType> = cx.local.usb_dev;
137139
let serial: &mut SerialPort<UsbBusType> = cx.local.serial;

0 commit comments

Comments
 (0)