chore: Remove unused keyboard code from rp mouse example

The usb mouse example included code copied from the keyboard example to set up
a button, which is not used in the mouse example. Remove it, to make the
example clearer.
This commit is contained in:
James Bowes 2024-08-26 10:33:13 -03:00
parent 86ca664655
commit d4ab9fc247
No known key found for this signature in database
GPG Key ID: D35BF226D806175B

View File

@ -8,7 +8,6 @@ use embassy_executor::Spawner;
use embassy_futures::join::join;
use embassy_rp::bind_interrupts;
use embassy_rp::clocks::RoscRng;
use embassy_rp::gpio::{Input, Pull};
use embassy_rp::peripherals::USB;
use embassy_rp::usb::{Driver, InterruptHandler};
use embassy_time::Timer;
@ -75,12 +74,6 @@ async fn main(_spawner: Spawner) {
// Run the USB device.
let usb_fut = usb.run();
// Set up the signal pin that will be used to trigger the keyboard.
let mut signal_pin = Input::new(p.PIN_16, Pull::None);
// Enable the schmitt trigger to slightly debounce.
signal_pin.set_schmitt(true);
let (reader, mut writer) = hid.split();
// Do stuff with the class!