Commit Graph

15 Commits

Author SHA1 Message Date
Jeff Epler
72f5537027
esp32: don't fully reset the wifi device
.. this makes reconnecting without a full reset not work.

Because this works on other generations of the esp32 (c2, c3, etc),
apply this behavior only to esp32.

After this change, it's possible to connect multiple times to wifi in
different runs of code.py or the repl after soft rebooting.
2022-07-14 15:01:15 -05:00
Jeff Epler
5c6ee20ca5
on esp32 need to initialize nvs before starting wifi
Also, change error handling so that the esp-idf error number
is shown in the traceback in the case of an error.

This allows scanning & connecting to work. I didn't try requests yet.
2022-07-13 11:57:38 -05:00
Scott Shawcroft
3be3e89d82
Merge branch 'main' into cp_webserver 2022-06-29 14:01:32 -07:00
Scott Shawcroft
8dc8265275
Fix auto-wifi created crash
The wifi event_handler runs on the other core so we need to be
careful when calling into CP APIs.

Fixes #6503
2022-06-29 11:53:10 -07:00
Scott Shawcroft
41039445c9
Clean up and add docs 2022-06-27 13:39:09 -07:00
Scott Shawcroft
7543dd9af0
CORS works and autoreload too 2022-06-27 13:39:08 -07:00
Scott Shawcroft
4f0a7aedfd
WIP adding devices.json and auth 2022-06-27 13:34:13 -07:00
Scott Shawcroft
6446010753
Wi-Fi autoconnect and title bar status
This adds support for CIRCUITPY_WIFI_SSID and CIRCUITPY_WIFI_PASSWORD
in `/.env`. When both are defined, CircuitPython will attempt to
connect to the network even when user code isn't running. If the
user code attempts to a network with the same SSID, it will return
immediately. Connecting to another SSID will disconnect from the
auto-connected network. If the user code initiates the connection,
then it will be shutdown after user code exits. (Should match <8
behavior.)

This PR also reworks the default displayio terminal. It now supports
a title bar TileGrid in addition to the (newly renamed) scroll area.
The default title bar is the top row of the display and is positioned
to the right of the Blinka logo when it is enabled. The scroll area
is now below the Blinka logo.

The Wi-Fi auto-connect code now uses the title bar to show its
state including the IP address when connected. It does this through
the "standard" OSC control sequence `ESC ] 0 ; <s> ESC \` where <s>
is the title bar string. This is commonly supported by terminals
so it should work over USB and UART as well.

Related to #6174
2022-06-09 14:55:54 -07:00
gamblor21
90fe20a153 Adding manual IP address set 2022-05-27 15:33:54 -05:00
anecdata
31d45a3f32 fix old bug that was masking new bug 2021-11-12 16:27:13 -06:00
Scott Shawcroft
c1177662cd
Merge pull request #5537 from microDev1/monitor-mode
Add Monitor Mode
2021-11-11 10:10:39 -08:00
microDev
a62675a81a
fix wifi reset and monitor deinit routine 2021-11-10 23:38:44 +05:30
Jeff Epler
c9475adb00
Enable -Werror=missing-prototypes on espressif port 2021-11-10 11:07:45 -06:00
microDev
95172cf3ce
add monitor class
Co-authored-by: anecdata <16617689+anecdata@users.noreply.github.com>
2021-11-02 12:32:09 +05:30
Scott Shawcroft
973a90f2aa
Rename esp32s2 port to espressif
This is in preparation for ESP32-S3 support and potentially others.

Related to #4363
2021-09-13 16:44:55 -07:00