Determining the onboard LED for various RP2040 ports? #10531
-
I thought I had a way to lock in on the onboard LED pins for the Pico and PicoW that would work for other RP2040 boards but apparently not. Should I open a request that all RP2 ports implement "LED" the way the Raspberry Pi Pico RP2040 version does? There is a special LED construct for the Raspberry Pi Pico MicroPython that works for the wifi and non-wifi boards. It accepts a pin named/numbered as "LED" per the following snippet
So I tried the same code on the Pimoroni Micro RP2040 port and no love.
Notice that it is hard to use
My code was zeroing in on sysname but that won't work here. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 9 replies
-
The background here is that that Where did you get the firmware for the "Pimoroni Micro RP2040" from? I don't think we have a board definition for that, so did it come from Piomoroni instead? Your firmware is also a lot older (2022-06-18). I suspect it possibly doesn't have this feature. We just (like four days ago) merged general support for pin naming for the rp2 port, so going forward it will match the other ports, including the ability to write |
Beta Was this translation helpful? Give feedback.
-
I use this for code that may run on the Pico or Pico W
|
Beta Was this translation helpful? Give feedback.
The background here is that that
machine.Pin("LED")
was a special thing that was added for the Pico W because the LED pin is not a "real" pin. We made it possible to use "LED" on all the other boards too (as long as they definePICO_DEFAULT_LED_PIN
in their pico-sdk header).Where did you get the firmware for the "Pimoroni Micro RP2040" from? I don't think we have a board definition for that, so did it come from Piomoroni instead? Your firmware is also a lot older (2022-06-18). I suspect it possibly doesn't have this feature.
We just (like four days ago) merged general support for pin naming for the rp2 port, so going forward it will match the other ports, including the ability to write
m…