Commit Graph

328 Commits

Author SHA1 Message Date
MicroDev
3d2cfa162a
enable paralleldisplay on esp32 and esp32s3 2023-09-13 11:35:14 -07:00
MicroDev
c38972b51c
update ulp implementation 2023-09-13 11:35:14 -07:00
MicroDev
242a720593
fix psram crash 2023-09-13 11:35:14 -07:00
MicroDev
a18e015888
update idf to v5.0 2023-09-13 11:33:51 -07:00
Dan Halbert
9f1d52601e merge from 8.2.x 2023-09-12 20:14:30 -04:00
Bill Sideris
6e9c21baba
Deinit all the pins. 2023-09-11 23:35:54 +03:00
Scott Shawcroft
885dbec599
Merge pull request #8357 from eightycc/memorymap
Add memorymap support to RP2 port
2023-09-08 11:28:11 -07:00
Jeff Epler
5e26862b2c
Allow use of CONFIG_SPIRAM_USE_CAPS_ALLOC
.. and switch makerfabs tft7 over to it as a test.

We have our existing way of "reserving" PSRAM for esp-idf (we actually
control it all but add back the "reserved" part). However, this does
not work with off the shelf esp_lcd, which only will allocate a
framebuffer in PSRAM if CONFIG_SPIRAM_USE_CAPS_ALLOC (or CONFIG_SPIRAM_USE_ALLOC)
is defined, not if CONFIG_SPIRAM_USE_MEMMAP is.

This new way is possibly compatible with more esp-idf code, but it complicates
CircuitPython's initial startup since nothing until port_heap_init is
permitted to use the CP heap or supervisor allocator. In practice this
seems to be OK today.

Right now this doesn't change the setting across all boards with PSRAM and so
it does not revert esp-idf to its prior state. Instead, what I'm thinking is
that we can do it during or just after the IDF5 update when sdkconfig files
will be getting an overhaul anyway.
2023-09-05 12:43:22 -05:00
Jeff Epler
b7d1147f67
Bump the stack size of the uart task
With DEBUG build and a consle UART, this would occur early during startup on makerfabs tft7:
```
I (0) cpu_start: Starting scheduler on APP CPU.
I (10) uart: queue free spaces: 20

***ERROR*** A stack overflow in task uart_event_task has been detected.


Backtrace: 0x403786f2:0x3fce9f40 0x403820a9:0x3fce9f60 0x403850da:0x3fce9f80 0x40383a7d:0x3fcea000 0x40382158:0x3fcea030 0x4038214e:0xa5a5a5a5 |<-CORRUPTED
```

Decoded backtrace was not enlightening:
```
0x403786f2: panic_abort at /home/jepler/src/circuitpython/ports/espressif/build-makerfabs_tft7/esp-idf/../../esp-idf/components/esp_system/panic.c:408
0x403820a9: esp_system_abort at /home/jepler/src/circuitpython/ports/espressif/build-makerfabs_tft7/esp-idf/../../esp-idf/components/esp_system/esp_system.c:137
0x403850da: vApplicationStackOverflowHook at /home/jepler/src/circuitpython/ports/espressif/build-makerfabs_tft7/esp-idf/../../esp-idf/components/freertos/port/xtensa/port.c:407
0x40383a7d: vTaskSwitchContext at /home/jepler/src/circuitpython/ports/espressif/build-makerfabs_tft7/esp-idf/../../esp-idf/components/freertos/tasks.c:3505
0x40382158: _frxt_dispatch at /home/jepler/src/circuitpython/ports/espressif/build-makerfabs_tft7/esp-idf/../../esp-idf/components/freertos/port/xtensa/portasm.S:436
0x4038214e: _frxt_int_exit at /home/jepler/src/circuitpython/ports/espressif/build-makerfabs_tft7/esp-idf/../../esp-idf/components/freertos/port/xtensa/portasm.S:231
0x00000000: ?? ??:0
```

Adding an additional 512 bytes of stack allowed CircuitPython to start
successfully.
2023-09-05 12:07:09 -05:00
Bob Abeles
66b3eccaf6 8334: RP2040 lacks raw memory map access 2023-08-31 20:25:20 -07:00
Jeff Epler
80a1d1a20a
Add support for a non-displayed left portion of screen 2023-08-31 14:52:26 -05:00
Jeff Epler
ed9cacf41d
Add DotClockFramebuffer 2023-08-30 10:30:15 -05:00
Scott Shawcroft
9daccc08c5
Forbidden pins are now correctly "in use" on ESP
This removes duplicate code to make debug UART pins in use via
never reset. It is done through forbidden pins automatically now.

Fixes #8288
2023-08-28 15:55:14 -07:00
Scott Shawcroft
ab70f8eace
Merge remote-tracking branch 'adafruit/main' into i2s_mclk 2023-08-24 15:07:14 -07:00
Jeff Epler
e74ef8b960
ringbuf_alloc no longer has a long-lived argument 2023-08-20 10:15:56 -05:00
Jeff Epler
a3a9c7a098
fix typo 2023-08-20 10:15:55 -05:00
Scott Shawcroft
8c5c73df38
Add I2S MCLK support to iMX RT 2023-08-17 11:39:14 -07:00
Dan Halbert
d582407b06 pre-commit fixes 2023-08-14 00:59:22 -04:00
Dan Halbert
2171e67c1b merge latest adafruit/main 2023-08-13 19:43:54 -04:00
Dan Halbert
10b94796c0 wip; fix more m_malloc and gc_alloc 2023-08-11 00:30:34 -04:00
Dan Halbert
0d2c3c3f08 wip: continuing compilation fixes; mp_obj_alloc everywhere 2023-08-07 20:45:57 -04:00
Dan Halbert
465d1c673e wip 2023-08-03 23:29:00 -04:00
Dan Halbert
0d4bc8c163 initial v1.19.1 merge; not compiled yet 2023-08-01 13:50:05 -04:00
Scott Shawcroft
5f082561b3
Unify some error strings 2023-07-20 11:20:32 -07:00
Dan Halbert
540bf58102 improve start_ap() doc; make "authmode" use consistent internally 2023-06-22 16:24:18 -04:00
Jeff Epler
d4913b04e0 rgbmatrix: update protomatter
and re-organize so that esp32 s2/s3 don't do as much at reset

.. it's not necessary (because most data is in esp-idf managed memory)
and doing this saves me from having to debug why reconstruct isn't working
properly on that platform.

This needs to be tested on other platforms again before being merged!
2023-06-08 10:43:32 -05:00
Dan Halbert
d755238005 add pin_skip_reset_once capability 2023-05-19 15:08:53 -04:00
Dan Halbert
9e995a5e98 Fix Espressif TouchAlarm 2023-05-19 12:36:28 -04:00
Scott Shawcroft
10b2e6bb4a
Add defined check 2023-05-15 13:04:12 -07:00
Scott Shawcroft
bd2c1198d9
Minor C3 debug tweaks 2023-05-12 14:51:59 -07:00
Scott Shawcroft
db8bd56c6c
Merge pull request #7946 from anecdata/ap_ipv4
Allow Access Point static IPv4 on the espressif port
2023-05-12 08:47:07 -07:00
Bojan Potočnik
74624e7c22
Add missing ESP32-S3 pins to microcontroller module
ESP32-S3 defines two additional general use pins in
ports/espressif/peripherals/esp32s3/pins.h, for which
support is missing in the microcontroller module HAL.
2023-05-12 09:10:26 +02:00
Dan Halbert
d99b0634f7 Report SPI frequency accurately on Espressif 2023-05-11 16:57:07 -04:00
anecdata
2f2a9e7e28 Allow Access Point static IPv4 on the espressif port. 2023-05-08 13:25:52 -05:00
Jeff Epler
66411fdd38
espressif: check return value from esp_ping_new_session
esp_ping_new_session can fail, particularly if ping is called quickly
many times in succession.

This is because `esp_ping_new_session` has to do a bunch of stuff
including creating a task and a socket. Calling `esp_ping_delete_session`
doesn't clean up these resources immediately. Instead, it signals the
task to clean up resources and exit 'soon', but 'soon' is defined as 1
second.

When the calls are frequent, the in-use sockets and tasks fill up
available slots—I didn't actually check which resource gets used
up first.

With this change, the ping call will raise an exception instead of
continuing with a call to esp_ping_start that crashes.

Closes #5980 based on my testing on an ESP32S3-N8R2.
2023-05-05 17:11:03 -05:00
Scott Shawcroft
8104b824e0
Standardize CPU temp and voltage. Add autogen warning 2023-04-28 16:19:43 -07:00
Scott Shawcroft
09c2c5ef0e
Merge pull request #7876 from thess/CORS-update
Simplify CORS checks and don't restrict host names.
2023-04-19 11:07:34 -07:00
Milind
fd1e9cf8f1
1. Changed attenuation from ADC_ATTEN_DB_0 to ADC_ATTEN_DB_11
2. Scaling the 12-bit values received from DMA engine to 16-bit value
2023-04-19 21:46:08 +05:30
Ted Hess
8980ebfa16 Simplify CORS checks and don't restrict host names.
Minor socket cleanup.
2023-04-18 22:09:48 -04:00
Ted Hess
9825b7fbb7 Web Workflow sockets and threads handling improvements.
Fixes polling thread looping forever hangs preventing new connections.
Don't lose listening sockets on mp resets and re-init.
Keep better separation of "system" and "user" sockets.
Track socket states to prevent re-use of sockets before closed.
Close REST socket when transaction completes. No post-init.
Remove unnecessary state flags.
2023-04-05 13:50:42 -04:00
Dan Halbert
0aacb146ef take wifi.radio.enabled into account 2023-03-31 22:31:41 -04:00
Dan Halbert
5c429320a8 Add wifi.radio.connected, wifi.radio.ap_active 2023-03-31 17:57:53 -04:00
Dan Halbert
9203b66142
Merge pull request #7815 from bill88t/intercontinental-ballistic-typo
24Mhz -> 240Mhz
2023-03-29 17:12:09 -04:00
Bill Sideris
b746fd05ba
24Mhz -> 240Mhz 2023-03-29 23:58:54 +03:00
hathach
8c1095b268
Merge branch 'main' into add-codespell 2023-03-23 14:09:57 +07:00
Scott Shawcroft
32a596df39
Merge pull request #7757 from adafruit/8.0.x
Merge latest 8.0.x changes
2023-03-20 14:34:59 -07:00
hathach
fecc1bdedb
fix typos (partial) detected by codepell 2023-03-18 22:17:02 +07:00
Dan Halbert
d4840cbf10 translate() messages must be one string 2023-03-14 13:13:58 -04:00
Dan Halbert
b6a7613350
Merge pull request #7470 from microdev1/espnow
Add ESP-NOW Support
2023-03-10 12:21:56 -05:00
MicroDev
874ba4ec68
revert Communicate class and more 2023-03-09 12:04:50 +05:30