Code: Select all
MPY: soft reboot
MicroPython v1.15 on 2021-06-09; ESP32 module with ESP32
Type "help()" for more information.
>>> from machine import Pin
>>>
paste mode; Ctrl-C to cancel, Ctrl-D to finish
=== nxt = Pin(36, Pin.IN, Pin.PULL_UP) # Move to next control
=== sel = Pin(37, Pin.IN, Pin.PULL_UP) # Operate current control
=== prev = Pin(38, Pin.IN, Pin.PULL_UP) # Move to previous control
=== increase = Pin(39, Pin.IN, Pin.PULL_UP) # Increase control's value
===
>>> nxt()
0
>>> sel()
0
>>> prev()
0
>>> increase()
0
>>>
It is something to do with the specific pins, which are brought out on the TTGO T-Display but not on the reference board. On the latter, if I specify pin 18 or 19 which are brought out, the pullups work.
Does the MicroPython firmware fully support pins 36-39? The pins work, but the internal pullups don't.