Merge pull request #43 from jannic/issue-42

Add a comment regarding the LED pin
This commit is contained in:
Jan Niehusmann 2023-02-24 09:32:48 +01:00 committed by GitHub
commit 7e80af2744
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -53,6 +53,11 @@ fn main() -> ! {
&mut pac.RESETS, &mut pac.RESETS,
); );
// This is the correct pin on the Raspberry Pico board. On other boards, even if they have an
// on-board LED, it might need to be changed.
// Notably, on the Pico W, the LED is not connected to any of the RP2040 GPIOs but to the cyw43 module instead. If you have
// a Pico W and want to toggle a LED with a simple GPIO output pin, you can connect an external
// LED to one of the GPIO pins, and reference that pin here.
let mut led_pin = pins.led.into_push_pull_output(); let mut led_pin = pins.led.into_push_pull_output();
loop { loop {