Search found 125 matches

by chuckbook
Fri Sep 11, 2020 2:48 pm
Forum: MicroPython pyboard
Topic: [SOLVED] Prevent powerbank to go into standby mode
Replies: 4
Views: 190

Re: Prevent powerbank to go into standby mode

It's usually ok to create power peaks onec and a while to keep the power bank happy. def wup(p): for i in range(1000): pass rtc.wakeup(10000, wup) This is a pretty naive way to create power consumption peaks, but it shows the idea. Note: If you run your pyboard at a low processor clock it might not ...
by chuckbook
Mon Aug 17, 2020 8:06 am
Forum: Pyboard D-series
Topic: wbus-DIP28 button use?
Replies: 5
Views: 271

Re: wbus-DIP28 button use?

This button allows to put the STM32 processor into boot mode. Keep in mind that ST boot loader supports only the FS port!
by chuckbook
Sat Aug 01, 2020 5:48 pm
Forum: General Discussion and Questions
Topic: RTC sub-seconds prescaler register not writable
Replies: 2
Views: 301

Re: RTC sub-seconds prescaler register not writable

Keep in mind that the RTC has to be fully powered down to change it's configuration.
by chuckbook
Mon Jul 13, 2020 8:06 am
Forum: Pyboard D-series
Topic: PYBD WBUS connector
Replies: 22
Views: 3346

Re: PYBD WBUS connector

Any copper track to a solder pad simply increases adhesive power between copper layer and substrate. This is very important in case of poor soldering which usually happens during manual assembly.
by chuckbook
Thu Jul 09, 2020 9:45 am
Forum: Programs, Libraries and Tools
Topic: TypeError: 'bytearray' object doesn't support item deletion
Replies: 9
Views: 706

Re: TypeError: 'bytearray' object doesn't support item deletion

Maybe I wasn't precise enough with my wording.
Intact was meant the way that storage space stays fixed not it's content.
Of course there are better ways to deal with non-contiguous data, but if you have to shift data chunks around it is pretty efficient.
by chuckbook
Wed Jul 08, 2020 10:13 am
Forum: Programs, Libraries and Tools
Topic: TypeError: 'bytearray' object doesn't support item deletion
Replies: 9
Views: 706

Re: TypeError: 'bytearray' object doesn't support item deletion

What about:

Code: Select all

lba = 1000         # size of bytearray
n = 10             # number of bytes to delete
ba = bytearray(lba)
mba = memoryview(ba)
mba[0:-n] = mba[n:]
This construct leaves the bytearray intact, which might come in handy for later reuse.
by chuckbook
Sun Jun 28, 2020 2:32 pm
Forum: Pyboard D-series
Topic: PYBD WBUS connector
Replies: 22
Views: 3346

Re: PYBD WBUS connector

When using small mezzanine connectors it is good practice to route unused pins to dummy tracks with vias close to the unused pads.
by chuckbook
Wed Jun 24, 2020 10:23 am
Forum: MicroPython pyboard
Topic: vbat connection solution ?
Replies: 7
Views: 699

Re: vbat connection solution ?

The VBACK pin has to be used for RTC backup.
by chuckbook
Mon Jun 22, 2020 9:34 am
Forum: Pyboard D-series
Topic: Max number of files to iterate with os.listdir()
Replies: 10
Views: 808

Re: Max number of files to iterate with os.listdir()

FAT filesystem has a terrible performance with more than some thousands of entries per directory.
Try to use a multi level hierarchy with less than 1000 entries per directory.
by chuckbook
Thu Jun 11, 2020 12:15 pm
Forum: Pyboard D-series
Topic: PYBD WBUS connector
Replies: 22
Views: 3346

Re: PYBD WBUS connector

If a PYBD doesn't 'click' into position there is no guarantee for proper contact of all pins.
Although HIROSE only specifies 30 mating cycles (-35° to 85° C), the connectors will easily withstand more than 1000 cycles at room temperature.