Commit Graph

496 Commits

Author SHA1 Message Date
hathach 8b3ce25ce0 update tinyusb to have esp32sx, stm32 and imxrt passed compliance test suite 2021-09-13 23:25:30 +07:00
Scott Shawcroft cfc4ed19aa
Merge pull request #5308 from microDev1/patch
Revert localization of `REPL` messages
2021-09-08 12:35:18 -07:00
Kamil Tomaszewski 8a023b04ca Update TinyUSB 2021-09-07 13:09:27 +02:00
microDev 86221b9895
revert localization of repl messages 2021-09-07 16:28:00 +05:30
Scott Shawcroft ebc44fad55
Update tinyusb for samd and rp2040 improvements
The improvements are based on the USB compliance tests.
2021-09-01 18:22:57 -07:00
Scott Shawcroft ec067ae728
Merge remote-tracking branch 'adafruit/main' into nrf-usb-compliance-test 2021-08-31 15:56:33 -07:00
Scott Shawcroft a4246bcfa3
Fix two watchdog crashes
Fixes a crash from trying to raise an exception when trying to
deinit a RESET wdt by not raising an exception.

Fixes a crash when raise a wdt exception in the REPL when waiting
for input. We now catch and print any exceptions raised.

Fixes #5261
2021-08-30 18:10:43 -07:00
hathach ec3dfed066
update tinyusb to commit 38f5aee9c3 2021-08-31 00:28:29 +07:00
Scott Shawcroft ca989c4357
Update the idf to a newer 4.3 commit
Also, make all port-level CIRCUITPY_ settings overridable.
2021-08-27 10:49:57 -07:00
Jeff Epler 4a9ad8a942 Translate & compress some repl messages 2021-08-23 20:23:23 -05:00
microDev 57b4d0176f
Merge pull request #5077 from microDev1/atexit
Add atexit module
2021-08-23 19:49:46 +05:30
Dan Halbert 57841dc92b
Merge pull request #5171 from tannewt/unicode_filenames
Turn on unicode for FATFS
2021-08-21 16:31:54 -04:00
microDev 25437dcb33
Merge branch 'main' into atexit 2021-08-20 09:45:54 +05:30
Dan Halbert 3c4c663d36 update tinyusb 2021-08-18 10:46:22 -04:00
Scott Shawcroft 11f1c42bb5
Turn on unicode for FATFS
This also tweaks the repr for unicode strings to only escape a few
utf-8 code points. This makes emoji show in os.listdir() for
example.

Also, enable exfat support on full builds.

Fixes #5146
2021-08-17 17:41:59 -07:00
microDev bdf8bc58ed
allow exception raise inside atexit callback 2021-08-16 22:35:04 +05:30
microDev 1c4a6c3667
atexit module refinements
- add test for atexit module
- add callback to gc collection
- fix callback memory allocation
- execute callback on both code and repl exit
2021-08-16 21:37:32 +05:30
Scott Shawcroft f0859ac954
Switch SAMD21 ticks to PER event
The EVSYS is used to generate an interrupt from the event. This
simplifies timing used in pulseio that conflicted with the
auto-reload countdown.

Fixes #3890
2021-08-10 15:23:45 -07:00
microDev 063e3946d6
Merge pull request #5094 from jepler/quirc
Add qrio: Decode QR codes with quirc lib
2021-08-07 09:30:20 +05:30
Scott Shawcroft be2342f32f
Merge pull request #5072 from microDev1/traceback
Add traceback module
2021-08-06 12:10:17 -07:00
Jeff Epler 2e8eb43dcc Use new quirc define for small stacks
.. and revert stack enlargement of esp32-s2
2021-08-05 12:52:43 -05:00
Jeff Epler bd903f2f03 Add qrio: Decode QR codes with quirc lib 2021-08-04 09:16:00 -05:00
microDev 193a8d2e67
add traceback object 2021-08-04 12:10:57 +05:30
microDev a3998d0626
add atexit module 2021-07-30 09:32:28 +05:30
Scott Shawcroft cdf978f3af
Fix a couple fake sleep bugs on nrf and esp
On ESP ctrl-c during fake sleep will now stop the sleep. A crash
on real deep sleep is now fixed as well. (Exception string saving
was crashing on reading the deep sleep exception.) Fixes #4010

This also fixes nRF fake sleep after the first time. The internal
variable wasn't being reset early enough. Fixes #4869
2021-07-28 13:27:48 -07:00
Christian Walther cf97793af8 Add supervisor.get_previous_traceback() function.
Useful for #1084.
2021-07-22 12:23:55 -04:00
Scott Shawcroft 1a4061ca4a
Merge pull request #4995 from hathach/fix-midi-write-offby1
update tinyusb to fix midi write off by one
2021-07-13 12:17:46 -07:00
hathach ae48c3d2db update tinyusb to fix midi write off by one 2021-07-13 21:45:42 +07:00
Jeff Epler 52540a9830 Rename EXTENDED_FIELDS -> MP_TYPE_EXTENDED_FIELDS 2021-07-12 06:57:59 -05:00
Jeff Epler 7302bc09a7 rename the type flag to EXTENDED for consistency 2021-07-09 14:59:37 -05:00
Jeff Epler d37f8a1a5a milestone: a selection of builds succeed 2021-07-06 10:57:44 -05:00
Jeff Epler df56ba207f WIP 2021-07-06 09:25:56 -05:00
Scott Shawcroft a7e353b80e
Merge pull request #4897 from jepler/merge-1.16
Merge 1.16
2021-06-23 10:15:10 -07:00
hathach 683304fd3c update tinyusb to fix nrf control race condition 2021-06-19 02:27:41 +07:00
Jeff Epler 87d3740c64 Merge tag 'v1.16' 2021-06-18 10:54:19 -05:00
Jeff Epler 11288c1c28 esp32s2: Add rgbmatrix support 2021-05-26 11:21:59 -05:00
Damien George 0aa01b0205 lib/mbedtls: Switch to currently latest commit of LTS branch v2.16.
Signed-off-by: Damien George <damien@micropython.org>
2021-05-25 00:04:01 +10:00
Scott Shawcroft 966d25c6a5
Merge MicroPython v1.15 into CircuitPython 2021-05-12 17:51:42 -07:00
Scott Shawcroft e02a26453c
Merge MicroPython 1.14 into CircuitPython 2021-05-11 15:07:40 -07:00
Ayke van Laethem 70f50c46cc lib/utils: Add ARM semihosting utility functions.
This can be a replacement for a UART in custom ports.
2021-05-11 23:33:12 +10:00
Damien George b6b39bff47 py/gc: Make gc_lock_depth have a count per thread.
This commit makes gc_lock_depth have one counter per thread, instead of one
global counter.  This makes threads properly independent with respect to
the GC, in particular threads can now independently lock the GC for
themselves without locking it for other threads.  It also means a given
thread can run a hard IRQ without temporarily locking the GC for all other
threads and potentially making them have MemoryError exceptions at random
locations (this really only occurs on MCUs with multiple cores and no GIL,
eg on the rp2 port).

The commit also removes protection of the GC lock/unlock functions, which
is no longer needed when the counter is per thread (and this also fixes the
cas where a hard IRQ calling gc_lock() may stall waiting for the mutex).

It also puts the check for `gc_lock_depth > 0` outside the GC mutex in
gc_alloc, gc_realloc and gc_free, to potentially prevent a hard IRQ from
waiting on a mutex if it does attempt to allocate heap memory (and putting
the check outside the GC mutex is now safe now that there is a
gc_lock_depth per thread).

Signed-off-by: Damien George <damien@micropython.org>
2021-05-10 13:07:16 +10:00
Scott Shawcroft 3fda0c0a1b
Fix board builds and use MP_ERROR_TEXT in py and extmod 2021-05-05 17:51:52 -07:00
Scott Shawcroft f0bb26d70f
Merge MicroPython 1.13 into CircuitPython 2021-05-04 18:06:33 -07:00
Scott Shawcroft b35fa44c8a
Merge MicroPython 1.12 into CircuitPython 2021-05-03 14:01:18 -07:00
Scott Shawcroft 76033d5115
Merge MicroPython v1.11 into CircuitPython 2021-04-26 15:47:41 -07:00
Damien George 530c76f6ca lib/utils: Remove unused PYEXEC_SWITCH_MODE from pyexec.h.
It was made obsolete by commit c98c128fe8.

Signed-off-by: Damien George <damien@micropython.org>
2021-04-24 00:10:59 +10:00
Scott Shawcroft 09f7b43c64
Merge MicroPython 1.10 into CircuitPython 2021-04-21 15:59:17 -07:00
Scott Shawcroft b057fb8a4b
codeformat 2021-04-19 22:22:44 -07:00
Jeff Epler 95a75b0410 update protomatter 2021-04-13 08:48:40 -05:00
hathach 7c3975ecf2 update tinyusb to fix midi buffer overflow issue 2021-04-02 17:57:56 +07:00