Search found 5101 matches

by pythoncoder
Thu Apr 22, 2021 5:17 pm
Forum: MicroPython pyboard
Topic: Please could some Pyboard 1.x users try this
Replies: 1
Views: 54

Please could some Pyboard 1.x users try this

This is in support of PR6007 . I experienced problems with Kingston SD cards where the SPI bus is shared with other peripherals. The fault is fixed by a simple change to sdcard.py. The question is whether I have some specially dodgy SD cards or whether others are affected. In my testing Sandisk card...
by pythoncoder
Thu Apr 22, 2021 7:19 am
Forum: Raspberry Pi microcontroller boards
Topic: Pico MicroPython with networking over USB
Replies: 8
Views: 284

Re: Pico MicroPython with networking over USB

HermannSW wrote:
Thu Apr 22, 2021 7:15 am
...
The point is to give Pico MicroPython networking, so that any usocket code will work on it as is.
...
When I will have usocket running with lwIP over USB, I will revisit the connected ESP01 and get hopefully "real" Wifi networking for the Pico.
Light dawns :D
by pythoncoder
Thu Apr 22, 2021 7:11 am
Forum: ESP32 boards
Topic: Some pins are in HIGH mode after reboot
Replies: 2
Views: 69

Re: Some pins are in HIGH mode after reboot

Yes. In general microcontrollers boot up with pins floating: any other option would be potentially unsafe to connected peripherals. If you want a pin to start at a defined level, an external resistor is the solution.
by pythoncoder
Thu Apr 22, 2021 7:08 am
Forum: Raspberry Pi microcontroller boards
Topic: Pico MicroPython with networking over USB
Replies: 8
Views: 284

Re: Pico MicroPython with networking over USB

I may be wrong but my understanding of this project is that the Pico/ESP8266-01 combination hosts an HTTPS website on one core while running arbitrary Python code on the other. The Python side supports a REPL over UART for debugging. This could have plenty of applications. As you say, I imagine you ...
by pythoncoder
Wed Apr 21, 2021 5:25 pm
Forum: ESP32 boards
Topic: micropython-nano-gui with m5stickc.
Replies: 2
Views: 79

Re: micropython-nano-gui with m5stickc.

The rgb() function you copied converts 24-bit rgb color values to an 8-bit result, for use with a bytearray buffer. This is a RAM saving device: I use GS8 mode for the underlying framebuf, with values being expanded to 12-bit at runtime. I'm surprised the result looks remotely correct! Given that yo...
by pythoncoder
Tue Apr 20, 2021 12:36 pm
Forum: Pyboard D-series
Topic: ntptime kills the wifi station, hard reset required to fix
Replies: 11
Views: 566

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

... Is that -3155673600 indicative of the problem? Actually after trying this a few more times it seems if I don't wait more than one (?) second between tries then I get the error... If you look at ntptime.py you'll find this line . A return value of -3155673600 means that the time() function has f...
by pythoncoder
Tue Apr 20, 2021 12:17 pm
Forum: ESP32 boards
Topic: CORE in ESP32
Replies: 1
Views: 120

Re: CORE in ESP32

No. FreeRTOS runs on one core and MicroPython on the other. MicroPython supports pre-emptive multitasking via _thread and cooperative multitasking via uasyncio, but in both cases (on ESP32) execution is on a single core.
by pythoncoder
Tue Apr 20, 2021 12:11 pm
Forum: General Discussion and Questions
Topic: oled date display
Replies: 2
Views: 81

Re: oled date display

Try this format string

Code: Select all

'{:02d}-{:02d}-{:02d}'.format(t[0] - 2000,t[1],t[2])
by pythoncoder
Tue Apr 20, 2021 10:20 am
Forum: General Discussion and Questions
Topic: How do you catch getaddrinfo() errors
Replies: 9
Views: 432

Re: How do you catch getaddrinfo() errors

Interesting link. It's noteworthy that your two addresses both fall in the 74.125.0.0/16 range reported in September 2017. The article talks of the address ranges changing with time - it doesn't mention whether individual addresses within a range might become unavailable. A possible approach to mini...
by pythoncoder
Mon Apr 19, 2021 3:49 pm
Forum: General Discussion and Questions
Topic: How do you catch getaddrinfo() errors
Replies: 9
Views: 432

Re: How do you catch getaddrinfo() errors

... That didn't take long ... took about 10 minutes for it to change from ('74.125.200.108', 465) to ('74.125.68.109', 465)... That's interesting. I wonder if the old address still worked? I'm no expert on this stuff but it's possible that Google maintain a pool of IP addresses and DNS servers serv...