Commit Graph

957 Commits

Author SHA1 Message Date
Dan Halbert 9083ae02de
Merge pull request #7710 from PaintYourDragon/pb-feather-dvi
Add Feather RP2040 DVI
2023-03-14 13:10:47 -04:00
hathach b432cf6201
fix rp2040 with new shared irq usb handler 2023-03-13 22:46:27 +07:00
Paint Your Dragon ff0a17d095
Merge branch 'adafruit:main' into main 2023-03-10 13:45:53 -08:00
Dan Halbert 0f31ba676b update errata fixes for RP2040 2023-03-09 17:40:53 -05:00
Scott Shawcroft fe40035cb9
Merge pull request #7697 from dhalbert/pico-sdk-cyw43-update
pico-sdk to 1.5.0; cyw43-driver to 0.9.0
2023-03-09 10:02:45 -08:00
Dan Halbert 2ebc0ea51c
GitHub online editor introduced spaces on blank lines :( 2023-03-09 11:30:38 -05:00
Dan Halbert de3c5ad2f4
add blank lines around aliased pins 2023-03-09 11:00:55 -05:00
Dan Halbert fef9571400 pico-sdk to 1.5.0; cyw43-driver to 0.9.0 2023-03-08 22:43:12 -05:00
Phillip Burgess fa55669da5 Merge branch 'main' of https://github.com/PaintYourDragon/circuitpython 2023-03-08 12:55:23 -08:00
Phillip Burgess a2514ca304 Add board adafruit_feather_rp2040_dvi
Based on Feather RP2040 SCORPIO, but new USB PID (from MBAdafruitBoards/Production) and pin name changes for GP16-23 (CKN/CKP etc., from board schematic).
2023-03-08 11:37:51 -08:00
MicroDev b17364a447
conditionally build all languages 2023-03-04 15:08:54 +05:30
Dan Halbert 859a48723f
Merge pull request #7633 from tannewt/fix_imx_pwm
Fix `pwmio` on iMX RT.
2023-02-28 14:11:06 -05:00
Scott Shawcroft 8e4626ffba
Merge pull request #7559 from startup-potech/main
Request to add a COSMO-Pico board
2023-02-28 09:49:31 -08:00
Dan Halbert f9831b3bbc
Merge pull request #7639 from adafruit/8.0.x
Merge 8.0.x up to main
2023-02-24 19:32:09 -05:00
Scott Shawcroft f832386cda
Merge remote-tracking branch 'adafruit/main' into banglejs2 2023-02-23 14:43:38 -08:00
Scott Shawcroft 1acf65ee22
Fix `pwmio` on iMX RT.
It now handles deinit, never_reset and sharing tracking. PWM
now runs in the WAIT state as well during a time.sleep().

_reset_ok() was removed because it was called in one spot right
before deinit().

Some PWMOut were also switched to a bitmap for use instead of
reference count. That way init and deinit are idempotent.

Fixes #6589. Fixes #4841. Fixes #4541.
2023-02-22 11:22:39 -08:00
Jeff Epler de9233f84a
raspberrypi: SSLSocket: raise OSError when appropriate
Rather than returning the negative error value.

This is intended to close #7606, though I did not test with mqtt.
Instead, I created a simple standalone test program:
```python
import wifi, socketpool, ssl, time
#wifi.radio.connect(<omitted>)
import socketpool
socket = socketpool.SocketPool(wifi.radio)
ctx = ssl.create_default_context()

b = bytearray(8)

s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
sss = ctx.wrap_socket(s, server_hostname='example.com')
sss.connect(('example.com', 443))
sss.setblocking(False)
r = sss.recv_into(b)
print(r, b)  # prints 4294967285 which is -11 as unsigned
sss.close()
```

Before the change, r was the out of range value 4294967285. After the
change, the recv_into call raises OSError instead.

This is comparable to the behavior on standard Python, though an
SSLWantReadError is raised instead.

The original (mis)behavior seems to match what was uncovered deep inside
minimqtt by adding logging:
```
370.578: DEBUG - PKT: _sock_exact_recv: recv_len = 4294967285
```
2023-02-22 10:07:48 -06:00
Scott Shawcroft de5f58a61d
Merge branch 'main' into banglejs2 2023-02-21 12:04:28 -08:00
root 7e6e824d56 Correctly raise OS error in socketpool_socket_recv_into() 2023-02-21 13:38:29 -06:00
MicroDev 508f2015b6
Merge pull request #7605 from Neradoc/pico-uart-in-use-error
Tweak the UART in use message on RP2040
2023-02-18 08:35:52 +05:30
Neradoc 13716c9c30 tweak the UART in use message on RP2040 2023-02-17 23:29:44 +01:00
Dan Halbert bbadc00599
Merge pull request #7577 from dhalbert/safemode-py
Implement safemode.py
2023-02-16 14:15:20 -05:00
Gregory Neverov fd1c3ca784 Increase number of LWIP timers for MDNS 2023-02-15 16:40:45 -08:00
Scott Shawcroft 931c7c1c51
Add Bangle.js 2, JDI memory displays and ACeP epd
This 2-in-1 PR started with the goal of support the Bangle.js 2
smartwatch with *no USB*.
* Adds "secure" DFU build support with a committed private key.
* Adds 3-bit color support with one dummy bit for the JDI memory display
* Allows nrf boards to have a board_background_task() run in RUN_BACKGROUND_TASK.
  This is needed because the Bangle.js 2 uses the watchdog to reset.
* Renamed port_background_task() to port_background_tick() to indicate it
  runs on tick, not RUN_BACKGROUND_TASK.
* Marks serial connected when the display terminal is inited. This means
  that safe mode messages show up on the display.

ACep, 7-color epaper displays also pack 3 bits in 4. So, I added that
support as well.
* Adds 3-bit ACeP color support for 7-color e-paper displays. (Not
  watch related but similar due to color depth.)
* Allows a refresh sequence instead of a single int command. The 7" ACeP
  display requires a data byte for refresh.
* Adds optional delay after resetting the display. The ACeP displays
  need this. (Probably to load LUTs from flash.)
* Adds a cleaning phase for ACeP displays before the real refresh.

For both:
* Add dither support to Palette.
* Palette no longer converts colors when set. Instead, it caches
  converted colors at each index.
* ColorConverter now caches the last converted color. It should make
  conversions faster for repeated colors (not dithering.)
2023-02-15 15:03:40 -08:00
MicroDev 32d86c3ea3
Merge pull request #7580 from adafruit/8.0.x
Merge 8.0.x up to main
2023-02-15 09:16:51 +05:30
MicroDev 48077daa7f
Merge pull request #7581 from gneverov/issue_7333
Add function common_hal_busio_uart_never_reset for rp2
2023-02-15 09:16:25 +05:30
Gregory Neverov 98b61279e4 Add function common_hal_busio_uart_never_reset for rp2 2023-02-14 09:05:24 -08:00
Dan Halbert d8231f1588 Implement safemode.py 2023-02-13 18:26:38 -05:00
Scott Shawcroft 7d236f2782
Merge pull request #7547 from ajs256/add_sprig
Add new board hack_club_sprig
2023-02-13 10:25:04 -08:00
Pierre Constantineau 676cbb308d minor update to boards.c to fix mismatched number of LEDs causing LEDs not to be reset 2023-02-13 09:52:18 -06:00
Ubuntu e125370cd4 first commit 2023-02-09 01:59:59 +00:00
Jeff Epler b9f689adf4 Use lowest drive level for PIO 2023-02-08 16:18:58 -06:00
Alex e78143a2f5
fix copyright header 2023-02-05 11:18:23 -08:00
Alex Sirota 07e8506b79 Add board hack_club_sprig 2023-02-03 20:19:11 -08:00
Gregory Neverov 77c6daf4b8 don't throw exception 2023-02-01 16:33:22 -08:00
MicroDev d9d94eacca
run updated pre-commit 2023-02-01 13:38:41 +05:30
Dan Halbert 13338df9f1
Merge pull request #7462 from tannewt/fix_rp2_reset_reason
Tweak RP2040 reset reason
2023-01-19 21:10:57 -05:00
Scott Shawcroft 82a313065e
Tweak RP2040 reset reason
Watchdogs are used to reboot out of the bootloader. There is a
scratch register for user watchdogs. So use sdk functions to better
distinguish these.

Related to #7346
2023-01-17 16:12:08 -08:00
Scott Shawcroft 683e393878
Add comments for MDNS code 2023-01-17 14:07:30 -08:00
Dan Halbert 79b76f7bea
Merge pull request #7445 from tannewt/fix_rpi_mdns
Share the web workflow MDNS object with the user
2023-01-17 14:46:38 -05:00
Dan Halbert 79bd88349e
Merge pull request #7444 from tannewt/fix_start_end_w_arrays
Have start and end kwargs respect element size
2023-01-13 20:11:41 -05:00
Scott Shawcroft ee2fe993dd
Fix repeated MDNS use on Pico W 2023-01-12 14:56:06 -08:00
Scott Shawcroft 5c517b7e5a
Handle MDNS deinited better. 2023-01-12 11:24:20 -08:00
Scott Shawcroft 72f4a8ebbc
Merge pull request #7423 from 0xCB-dev/add-0xCB-Helios
add support for 0xCB Helios rp2040 controller
2023-01-11 16:27:36 -08:00
Scott Shawcroft aa2ba4d88b
Have start and end kwargs respect element size
The comment says it is `buffer[start:end]` but it assumed elements
were a single byte long. Now it correctly does multibyte elements
from array.array.

Fixes #4988
2023-01-11 15:36:41 -08:00
Scott Shawcroft 78c2fa5b28
Merge pull request #7437 from dhalbert/improve-type-checking-error-msgs
Improve type validation error messages, especially for pins
2023-01-11 10:54:22 -08:00
Jeff Epler e817563ca0
Update cyw43-driver, fix no-password wifi
Now, open wifi works on Pico W, so this closes #7438.

For the web workflow it's now OK to either
 * specify an empty password string (as before)
 * not have the CIRCUITPY_WIFI_PASSWORD key at all (new functionality)
2023-01-10 15:07:17 -06:00
Dan Halbert a974402542 Improve type validation errors messages, especially for pins 2023-01-10 15:02:55 -05:00
Conor Burns 5aa8419455
add pid.codes VID and PID 2023-01-07 13:11:38 +01:00
Conor Burns 56c0f0388d
add 0xCB Helios 2023-01-05 23:02:00 +01:00