Commit Graph

17564 Commits

Author SHA1 Message Date
Jeff Epler
dd6e7f5a8a mimxrt10xx: Add required header for NORETURN definition 2020-09-28 18:56:01 -05:00
Jeff Epler
1dbb59271c esp32: Use esp_restart from reset_to_bootloader; redeclare it NORETURN 2020-09-28 18:56:01 -05:00
Jeff Epler
726dcdb60a Add some NORETURN attributes
I have a function where it should be impossible to reach the end, so I put in a safe-mode reset at the bottom:
```
int find_unused_slot(void) {
    // precondition: you already verified that a slot was available
    for (int i=0; i<NUM_SLOTS; i++) {
        if( slot_free(i)) {
            return i;
        }
    }
    safe_mode_reset(MICROPY_FATAL_ERROR);
}
```
However, the compiler still gave a diagnostic, because safe_mode_reset was not declared NORETURN.

So I started by teaching the compiler that reset_into_safe_mode never returned.  This leads at least one level deeper due to reset_cpu needing to be a NORETURN function.  Each port is a little different in this area.  I also marked reset_to_bootloader as NORETURN.
Additional notes:

 * stm32's reset_to_bootloader was not implemented, but now does a bare reset.  Most stm32s are not fitted with uf2 bootloaders anyway.
 * ditto cxd56
 * esp32s2 did not implement reset_cpu at all.  I used esp_restart().  (not tested)
 * litex did not implement reset_cpu at all.  I used reboot_ctrl_write.  But notably this is what reset_to_bootloader already did, so one or the other must be incorrect (not tested).  reboot_ctrl_write cannot be declared NORETURN, as it returns unless the special value 0xac is written), so a new unreachable forever-loop is added.
 * cxd56's reset is via a boardctl() call which can't generically be declared NORETURN, so a new unreacahble "for(;;)" forever-loop is added.
 * In several places, NVIC_SystemReset is redeclared with NORETURN applied.  This is accepted just fine by gcc.  I chose this as preferable to editing the multiple copies of CMSIS headers where it is normally declared.
 * the stub safe_mode reset simply aborts.  This is used in mpy-cross.
2020-09-28 18:55:56 -05:00
Scott Shawcroft
6bfcb01ee7
Merge pull request #3478 from ansonhe97/main
Turn Default power on Wio Terminal's 40 Pin
2020-09-28 14:44:51 -07:00
Scott Shawcroft
785f2beed0
Merge pull request #3481 from caternuson/iss3480_docupdate
Add MP const info to Design Guide
2020-09-28 14:30:28 -07:00
Scott Shawcroft
ffeaef5d82
Merge pull request #3453 from DavePutz/issue3367
Issue #3367 Changed delay calls to avoid conflicts with qspi_disable
2020-09-28 14:18:51 -07:00
caternuson
4d4dbbcafe RST tweak 2020-09-28 13:28:38 -07:00
caternuson
8e4f08a109 add MP const info to Design Guide 2020-09-28 13:15:43 -07:00
Anson He
96323ac3ac Default power on Wio Terminal's 40 Pin 2020-09-27 10:21:25 +08:00
Jeff Epler
d6da406d0f
Merge pull request #3474 from tannewt/update_tinyusb
Update TinyUSB to get MIDI SysEx fix
2020-09-26 20:31:09 -05:00
Jeff Epler
dab4d0effd
Merge pull request #3476 from jepler/qtpy-haxpress
Add QT Py Haxpress
2020-09-26 12:37:47 -05:00
Jeff Epler
791d20f16c give qtpy haxpress its own USB PID 2020-09-26 11:45:53 -05:00
Jeff Epler
8b27febf32 add new board to actions build 2020-09-26 11:43:46 -05:00
Jeff Epler
9944935fde qtpy haxpress: enable RTC 2020-09-26 11:33:10 -05:00
Scott Shawcroft
2c8ee08520
Merge pull request #3471 from tannewt/i2c_100k
Change I2C default to 100khz
2020-09-25 14:08:25 -07:00
Scott Shawcroft
73d08df9ad
Update TinyUSB to get MIDI SysEx fix
Fixes #3465
2020-09-25 12:23:31 -07:00
Scott Shawcroft
2b856dbd28
Merge pull request #3470 from askpatrickw/fix-pin-printout
Print package if it exists for pin or module only if it does not
2020-09-25 11:21:16 -07:00
Scott Shawcroft
c07307a309
Merge pull request #3455 from weblate/weblate-circuitpython-main
Translations update from Weblate
2020-09-25 11:20:18 -07:00
Scott Shawcroft
b9d68bc5a6
Change I2C default to 100khz
Greater that 100khz is technically out of the original spec.

Background here: https://github.com/adafruit/Adafruit_CircuitPython_CLUE/issues/36
2020-09-25 11:07:22 -07:00
askpatricw
33952023e8 Print package if it exists for pin or module only if it does not 2020-09-25 10:08:26 -07:00
Jeff Epler
eadb4de144 qtpy_m0_haxpress: add 2020-09-24 16:58:24 -05:00
Jeff Epler
6bcbe51f7f supervisor: stub: make unimplemented safe_mode loop forever 2020-09-24 16:57:20 -05:00
Jeff Epler
832869b257 make translate 2020-09-24 16:56:07 -05:00
Maciej Stankiewicz
3a6f7986df Translated using Weblate (Polish)
Currently translated at 73.7% (595 of 807 strings)

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/pl/
2020-09-23 21:30:08 +02:00
Wellington Terumi Uemura
c1830d6212 Translated using Weblate (Portuguese (Brazil))
Currently translated at 100.0% (807 of 807 strings)

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/pt_BR/
2020-09-23 21:30:08 +02:00
Scott Shawcroft
dd86cb00ad
Merge pull request #3448 from hierophect/esp32-sd-fix
ESP32S2 - Fix SPI's SD card issue, add pin protections
2020-09-23 12:30:01 -07:00
Scott Shawcroft
a8558a48ed
Merge pull request #3456 from jepler/qstr-and-or-demagic
makeqstrdefs: don't make _and_, _or_ poisoned substrings for QSTRs
2020-09-23 12:24:02 -07:00
Scott Shawcroft
bcabf5e019
Merge pull request #3457 from ladyada/qtpy_m0
fix pins for rev C
2020-09-23 11:31:28 -07:00
Lucian Copeland
00517b2600 Move missing pin warning to shared-bindings 2020-09-23 11:39:39 -04:00
lady ada
9db7625717 neopix is default on! 2020-09-23 11:19:01 -04:00
lady ada
5384479a61 fix pins for rev C 2020-09-22 23:28:23 -04:00
Jeff Epler
28e80e47d7 makeqstrdefs: don't make _and_, _or_ poisoned substrings for QSTRs
New contributor @mdroberts1243 encountered an interesting problem in
which the argument they had named "column_underscore_and_page_addressing"
simply couldn't be used; I discovered that internally this had been
transformed into "column_underscore∧page_addressing", because QSTR
makes _ENTITY_ stand for the same thing as &ENTITY; does in HTML.

This might be nice for some things, but we don't want it here!
I was unable to find a sensible way to "escape" and prevent this entity
coding, so instead I ripped out support for the _and_ and _or_ escapes.
2020-09-22 17:39:44 -05:00
Jeff Epler
410d27b746
Merge pull request #3452 from weblate/weblate-circuitpython-main
Translations update from Weblate
2020-09-22 16:30:37 -05:00
Hosted Weblate
cabd7539d3
Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/
2020-09-22 21:40:01 +02:00
Szymon Jakubiak
c2d6405fea Translated using Weblate (Polish)
Currently translated at 73.3% (587 of 800 strings)

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/pl/
2020-09-22 21:39:59 +02:00
Scott Shawcroft
98185e914b
Merge pull request #3425 from jepler/canbus
canio: Initial implementation for SAM E5x MCUs
2020-09-22 12:39:52 -07:00
Jeff Epler
82f37c9252 canio: fix read(), iterable bindings 2020-09-22 10:28:25 -05:00
root
dbf8a9ad69 Changed delay calls to avoid conflicts with qspi_disable 2020-09-22 10:25:31 -05:00
DavePutz
7ad7e1cf64
Merge pull request #29 from adafruit/main
Update from adafruit/main
2020-09-22 10:13:18 -05:00
Jeff Epler
9fd9cf1138 canio: fix bugs in shared-bindings 2020-09-22 09:36:47 -05:00
Jeff Epler
59580d0f2d canio: Fix implementation bugs in atmel-sam 2020-09-22 09:36:29 -05:00
hierophect
9f892cdda8
Merge pull request #3451 from microDev1/patch-1
FIX : esp32s2 RTC support
2020-09-22 09:32:18 -04:00
microDev
add230b4da
Update port.c 2020-09-22 11:37:12 +05:30
Jeff Epler
10245c0ff8 canio: a few more stray _canios 2020-09-21 17:04:30 -05:00
Jeff Epler
a8147c125c Fix unintentional cross references 2020-09-21 16:47:28 -05:00
Jeff Epler
85756fa0cd make translate 2020-09-21 16:45:51 -05:00
Jeff Epler
4869dbdc67 canio: rename from _canio
This reflects our belief that the API is stable enough to avoid incompatible changes during 6.x.
2020-09-21 16:44:26 -05:00
Jeff Epler
493679da3b CAN.listen: block until a message comes in or timeout is reached 2020-09-21 16:44:26 -05:00
Jeff Epler
9e8f1820c8 canio.CAN: switch rx/tx, make both mandatory, move declarations around 2020-09-21 16:44:26 -05:00
Jeff Epler
4e4853dcb2 common.template.ld: remove unneeded line 2020-09-21 16:44:26 -05:00