Search found 5059 matches

by pythoncoder
Sat Apr 10, 2021 1:18 pm
Forum: ESP32 boards
Topic: waveshare eInk display is stuck powering on with BUSY pin on high
Replies: 2
Views: 84

Re: waveshare eInk display is stuck powering on with BUSY pin on high

As a general comment, having ported several display drivers to MicroPython, the way forward is to sit down with the hardware, the datasheet, and the code for the similar display. Check the code line by line against the datasheet. That said, my limited experience with Waveshare boards was bad. Maybe ...
by pythoncoder
Sat Apr 10, 2021 1:06 pm
Forum: MicroPython pyboard
Topic: How to trigger delayed callback from interrupt
Replies: 3
Views: 109

Re: How to trigger delayed callback from interrupt

Another approach if you don't want to use my Delay_ms class is something like this: import uasyncio as asyncio from machine import Pin from pyb import LED led = LED(1) async def my_app(): tsf = asyncio.ThreadSafeFlag() def irq_han(_): led.on() tsf.set() # Trigger the thread safe flag pin = Pin('X1',...
by pythoncoder
Fri Apr 09, 2021 1:57 pm
Forum: MicroPython pyboard
Topic: How to trigger delayed callback from interrupt
Replies: 3
Views: 109

Re: How to trigger delayed callback from interrupt

I would use a uasyncio based software timer: import uasyncio as asyncio from primitives.delay_ms import Delay_ms from machine import Pin from pyb import LED led = LED(1) async def my_app(): tim = Delay_ms(func=lambda : led.off(), duration=100) def irq_han(_): led.on() tim.trigger() # Start the timer...
by pythoncoder
Fri Apr 09, 2021 1:12 pm
Forum: Drivers for External Components
Topic: Update to font_to_py for tiny fonts
Replies: 3
Views: 381

Re: Update to font_to_py for tiny fonts

I have no idea what /lib/ili934xnew.py is. My ILI9341 driver is this one . Python fonts produced by font_to_py.py are compatible with my nano_gui , Writer and CWriter classes, using my drivers. The specification for the files is documented, so other authors may choose to support them. Or they may us...
by pythoncoder
Fri Apr 09, 2021 1:02 pm
Forum: Pyboard D-series
Topic: ntptime kills the wifi station, hard reset required to fix
Replies: 7
Views: 277

Re: ntptime kills the wifi station, hard reset required to fix

Perhaps I'm misunderstanding the problem here, but this works for me on a Pyboard D SF2W: MicroPython v1.13-107-g18518e26a-dirty on 2020-11-02; PYBD-SF2W with STM32F722IEK Type "help()" for more information. >>> import do_connect >>> do_connect.do_connect() connecting to network... network config: (...
by pythoncoder
Thu Apr 08, 2021 5:07 am
Forum: Pyboard D-series
Topic: ntptime not included with PyBoard firmware
Replies: 11
Views: 288

Re: ntptime not included with PyBoard firmware

@kwiley It is easy if your location is static and you handle the date for the change; you are doing it correctly. Full Unix support is not easy as it involves knowing the DST parameters for every country in the world. And they don't always get it right: I have an old project with firmware from an an...
by pythoncoder
Thu Apr 08, 2021 4:56 am
Forum: MicroPython pyboard
Topic: Did I break my board?
Replies: 1
Views: 95

Re: Did I break my board?

I'm afraid it sounds as if you have. I can only think of one thing left to try, which is to see if you can flash new firmware, but given the symptoms I don't hold out much hope :(
by pythoncoder
Wed Apr 07, 2021 4:39 pm
Forum: Pyboard D-series
Topic: ntptime not included with PyBoard firmware
Replies: 11
Views: 288

Re: ntptime not included with PyBoard firmware

You might be interested in these notes on Pyboard D RTC accuracy and calibration.
by pythoncoder
Wed Apr 07, 2021 4:35 pm
Forum: Raspberry Pi microcontroller boards
Topic: Raspberry Pi Pico micropython ModbusRTU
Replies: 2
Views: 261

Re: Raspberry Pi Pico micropython ModbusRTU

Try a forum search on Modbus.
by pythoncoder
Wed Apr 07, 2021 4:32 pm
Forum: General Discussion and Questions
Topic: Custom newline characters when reading files
Replies: 1
Views: 68

Re: Custom newline characters when reading files

It's unsupported. You'll have to read it as a binary file and parse it yourself, I'm afraid.