Paid The Beak on other MicroPython devices

  • Thread starter Thread starter classiphil
  • Start date Start date
  • Views Views 284
  • Replies Replies 0
  • Likes Likes 1

classiphil

Well-Known Member
Newcomer
Joined
Dec 3, 2017
Messages
75
Reaction score
12
Trophies
0
Age
45
XP
269
Country
Germany
Hey there,

Maybe we start a collection of tested MicroPython code for other devices?
Find attached the main.py for an ESP32-C3 using pin 21.

Just rescued my 2015 Hynix-EMMC Wii U with it.

Is anybody else wanting to contribute?

Sorry for not including the link to the original post. I am not allowed to do that yet.
Thanks to Jan, Deadly and the whole PTB-team

Code:
from machine import Pin
from time import sleep_ms

pins = [21]

timings = [16, 16, 32, 48, 32, 16, 16, 96]

pins = [Pin(gpio,Pin.OUT) for gpio in pins]


def run_timings(off):
    v = 0
    for t in timings:
        for p in pins:
            p.value(v)
        sleep_ms(t+ (-off if v else off))
        v = 1-v
    print(v)

while True: run_timings(0)
 
Last edited by classiphil,
  • Like
Reactions: blackkawa

Site & Scene News

Popular threads in this forum