Search found 3507 matches

by dhylands
Wed Jan 20, 2021 9:07 pm
Forum: General Discussion and Questions
Topic: machine.RTC().datetime() gives incorrect hours, minutes, and day of the week
Replies: 3
Views: 41

Re: machine.RTC().datetime() gives incorrect hours, minutes, and day of the week

I know rshell has a bunch of code to deal with the various RTC's: https://github.com/dhylands/rshell/blob/aae27f5b39af428982eec81a0b90fdea6e191669/rshell/main.py#L951 It looks like the arguments to datetime are expected to be in the following order: (year, month, day, weekday, hour, minute, second, ...
by dhylands
Wed Jan 20, 2021 12:19 am
Forum: Development of MicroPython
Topic: machine memory module
Replies: 3
Views: 58

Re: machine memory module

machine_mem is used in many of the MCU ports as well (stm32, zephyr, samd, nrf, esp8266, eps32, mimxrt) Here's some sample code that uses it: https://github.com/dhylands/upy-examples/blob/15bed30b402512b94dfa1f3558a85408430741b7/encoder.py#L14 (the stm.memXX functions and machine.memXX functions are...
by dhylands
Sun Jan 17, 2021 10:02 pm
Forum: micro:bit boards
Topic: Maximum and minimum int and float values?
Replies: 2
Views: 51

Re: Maximum and minimum int and float values?

It depends. There are several different ways of configuring micropython. The standard pyboard (STM32F405) has a notion of small ints which can store 31-bit signed integers. It also supports MPZ (multi-prrecision) which is essentually infinite precision integers, limited only by available memory. Mic...
by dhylands
Fri Jan 15, 2021 2:09 am
Forum: ESP32 boards
Topic: rshell cannot access port (MacOS Catalina)
Replies: 2
Views: 99

Re: rshell cannot access port (MacOS Catalina)

I'm running Catalina (10.15.7) and don't have any issues accessing my ESP32 board. $ rshell -l Serial Device: /dev/cu.Bluetooth-Incoming-Port Serial Device: /dev/cu.Dave-Headphones-SPPDev USB Serial Device 0403:6015 with vendor 'FTDI' serial 'DN02Z2XC' intf 'FT231X USB UART' found @/dev/cu.usbserial...
by dhylands
Tue Jan 12, 2021 9:05 pm
Forum: General Discussion and Questions
Topic: Function for writing posts, "Insert image:" I hope it wasn't asked 10 times before
Replies: 10
Views: 859

Re: Function for writing posts, "Insert image:" I hope it wasn't asked 10 times before

Ah, thanks for the tip about GitHub. I think I read something about Chrome terminally disapproving of http? Does it see http://hinch.me.uk ? Firefox shows an "insecure" indicator but otherwise displays the page. I only use the webspace for sharing odds and ends, but I guess the days of http are com...
by dhylands
Tue Jan 12, 2021 5:46 pm
Forum: General Discussion and Questions
Topic: Function for writing posts, "Insert image:" I hope it wasn't asked 10 times before
Replies: 10
Views: 859

Re: Function for writing posts, "Insert image:" I hope it wasn't asked 10 times before

Peter, Your http link didn't show up for me in Chrome, but it did show up in firefox and safari.

The https links show up in all 3 browsers.
by dhylands
Tue Jan 12, 2021 5:34 pm
Forum: General Discussion and Questions
Topic: Function for writing posts, "Insert image:" I hope it wasn't asked 10 times before
Replies: 10
Views: 859

Re: Function for writing posts, "Insert image:" I hope it wasn't asked 10 times before

To link from github, you need to link to the raw image (i.e. right click on the Download button and copy that link)
Image

Linking from https Image seems to work
by dhylands
Wed Jan 06, 2021 7:45 pm
Forum: General Discussion and Questions
Topic: OSError: accelerometer not found
Replies: 7
Views: 2115

Re: OSError: accelerometer not found

Are you sure you have a 1.1 board? The 1.0 LITE board doesn't have an accelerometer.

What does:

Code: Select all

import os
os.uname()
report for you?
by dhylands
Mon Jan 04, 2021 4:08 pm
Forum: Other Boards
Topic: WeAct STM32F411CEU6 black pill
Replies: 61
Views: 15328

Re: WeAct STM32F411CEU6 black pill

Then in ports/stm32: make clean to be sure nothing remains from previous compilation. Then make BOARD=WeAct_F411CE -j4 I just thought I'd point out that running make clean without specifying BOARD= will do a clean of the default board, which is PYBV10. You really want to do: make BOARD=WeAct_F411CE...
by dhylands
Mon Jan 04, 2021 3:08 pm
Forum: Development of MicroPython
Topic: M_new in external C Module, How to protect from GC.collect()
Replies: 10
Views: 229

Re: M_new in external C Module, How to protect from GC.collect()

In order to “protect” memory allocated from the Python heap, the allocated object needs to reachable by tracking from the root pointers or the stack.

There are several threads in the forum discussing this like this one: viewtopic.php?f=2&t=8877&p=51142