← index #18411Issue #10205
Related · high · value 0.742
QUERY · ISSUE

EXT_GPIO1 on an RM2 module gets set to output high after setting WLAN interface active.

openby Lobo-Topened 2025-11-13updated 2026-03-16
enhancementport-rp2

Port, board and/or hardware

RP2 port, on self designed board with RP2350 and RM2 module.

MicroPython version

MicroPython v1.27.0-preview.386.g2762fe680a.dirty on 2025-11-07; Lobotronic Wifi IO V1 with RP2350

Reproduction

On an RPI Pico2 W the EXT_GPIO1 on the CYW43 is an output to control the DC-DC converter. But with an RM2 module all 3 EXT GPIOs ought to be able to use as either input or output.

It works when first booting, but after activating the wlan interface EXT_GPIO1 seems to switch to output high.

Running this after first power up:

from machine import Pin
s0 = Pin('EXT_GPIO0',Pin.IN)
print(f"S0: {s0.value()}")
s1 = Pin('EXT_GPIO1',Pin.IN)
print(f"S1: {s1.value()}")
s2 = Pin('EXT_GPIO2',Pin.IN)
print(f"S2: {s2.value()}")

Produces:
S0: 0
S1: 0
S2: 0

All three buttons are pulled down with external resistors.
When holding in the button connected to EXT_GPIO1:
S0: 0
S1: 1
S2: 0

But after running:

import network
wlan = network.WLAN(network.WLAN.IF_STA)
wlan.active(True)

The result will always be:
S0: 0
S1: 1
S2: 0
No matter the state of the S1 button.

Expected behaviour

Expect EXT_GPIO1s state to still be low after activating WLAN, when it is used as an input and pulled down.

Observed behaviour

EXT_GPIO1s state appears to always be HIGH.

Additional Information

No, I've provided everything above.

Code of Conduct

Yes, I agree

CANDIDATE · ISSUE

RPI Pico W: Pin("LED", Pin.OUT).on() crashes/hangs

closedby axxelopened 2022-12-12updated 2022-12-17
bugport-rp2

My Raspberry Pi Pico W worked for a day or so (on rp2-pico-w-20221209-unstable-v1.19.1-740-gbf49a087b.uf2). Then something happened and I don't know what. The following script makes it hang/crash:

from machine import Pin
led = Pin("LED", Pin.OUT)
# all good until here
led.on()
# never reaching this line and the led stays off

If I replace "LED" with 0 it does not crash and the GPIO_0 pin becomes high as expected.

Another hint that something with the wifi module is off:

wlan = network.WLAN(network.STA_IF)
wlan.active(True)
print(wlan.active()) # prints: 'False'

I saw #8904 but I concluded that I have another issue, since it is not related to it being connected to a Mac/Linux USB stack, the mentioned fix there does not help and I ran into it with the latest build.

For a lack of any other idea, a wild guess would be that my external power supply semi-fired it (although I examined it with an oscilloscope and everything looks as it is supposed to from what I can tell). I would appreciate any ideas for further debugging, including using my osci to peak in on the communication between the uC and the wifi module to find out if there is indeed a hardware defect.

Keyboard

j / / n
next pair
k / / p
previous pair
1 / / h
show query pane
2 / / l
show candidate pane
c
copy suggested comment
r
toggle reasoning
g i
go to index
?
show this help
esc
close overlays

press ? or esc to close

copied