76 Commits

Author SHA1 Message Date
Kirill Mikhailov
88c4dba9e0
esp-wifi docs improve (#2354)
* Improve esp-wifi docs (WIP)

* Finalize

* Address reviews, make cratewide public functions be `pub(crate)`.

* config -> configure
2024-10-18 08:23:16 +00:00
Anthony Grondin
060aa7262c
feat(esp-wifi): Implement serde:{Deserialize, Serialize} for wifi structs (#2346)
* feat(esp-wifi): Implement `serde:{Deserialize, Serialize}` for wifi structs

* Update changelog

* Add missing serde feature for dependencies that supports it.
2024-10-16 07:10:43 +00:00
Dániel Buga
7aa8145213
Silence clippy (#2332) 2024-10-11 17:38:42 +00:00
Jesse Braham
d08dc3dcb7
Add new living migration guides (#2327) 2024-10-10 12:44:28 +00:00
Scott Mabin
f29d539a78
Prepare new radio related releases (#2328) 2024-10-10 12:20:52 +00:00
Jesse Braham
d655fe665f
New package releases (#2310)
* Bump version numbers of all packages to be published, update deps as needed

* Update all `CHANGELOG.md` files

* Update migration guide headings
2024-10-10 10:19:04 +00:00
Dániel Buga
ba8daafb0b
Require float-save-restore in esp-wifi (#2322)
* Add failing test case

* Make sure task contexts are properly initialised

* Require float-save-restore for esp-wifi
2024-10-10 08:24:50 +00:00
Scott Mabin
0142703112
I2c rename, small docs clean up (#2320)
* cleanup prelude docs

* fixups and i2c rename

* changelog and migration

* fixup docs and examples

* fix lint
2024-10-10 07:26:13 +00:00
Dániel Buga
b27482df3c
Mention silent esp-hal-embassy breaking change (#2307) 2024-10-08 15:17:38 +00:00
Dániel Buga
f26eef646a
Remove current_millis (#2304) 2024-10-08 14:04:59 +00:00
Björn Quentin
81f93698b0
Remove unused dependencies (#2306) 2024-10-08 13:49:49 +00:00
Scott Mabin
08030d5541
bump all semver compatible deps (#2303) 2024-10-08 12:56:30 +00:00
Björn Quentin
038d07f5b6
Use relevant features when building documentation (#2295)
* Use relevant features when building documentation

* CHANGELOG.md and migration guide

* Fix imports
2024-10-08 07:31:56 +00:00
Dániel Buga
16f277915b
Remove redundant feature (#2297) 2024-10-08 07:31:47 +00:00
Björn Quentin
e5bc63916f
Change debug! to trace! to reduce logging noise (#2284) 2024-10-07 09:29:41 +00:00
Kirill Mikhailov
a4fe5e6e63
Adding a way to deinitialize the WiFi stack. (#2187)
* WIP

* cleanup

* WIP (BLE)

* WIP (BLE)

* c2 ble deinit doesn't work with ble alone, works in coex (WIP)

* fmt

* cleanup

* changelog entry

changelog entry

* WIP (do not check it)

 it's just to save things before weekend!

* polishing, refactor

* cleanup

* lint

* Addressing reviews

* address reviews

* utilize `EspWifiInitialization` in deinit

* example -> description

* reviews

* reviews

* fix memory leak + rebase

* typo

* fix

* init -> initialize

screwed up after rebase

* make esp32c6/h2 buildable again

* edit safety comment
2024-10-04 12:16:52 +00:00
Björn Quentin
18da679d8a
esp-wifi: Align default settings (#2251)
* Align esp-wifi defaults with ESP-IDF

* Check we assume the correct wifi-config defaults

* No WIFI-CONFIG for ESP32-H2
2024-10-04 09:34:42 +00:00
Björn Quentin
b8a4d5f9ff
Remove unused functions (#2254) 2024-09-30 12:07:41 +00:00
Juraj Sadel
11c73caf89
esp-wifi: Remove log feature from default features (#2253)
* esp-wifi: Remove log feature from default features

* changelog
2024-09-30 11:10:58 +00:00
Björn Quentin
fa66a43949
Update drivers (#2239)
* Update drivers

* Fixes

* Changelogs

* Actually remove timers when we should

* Have one waker for all events

* Prefer `swap_remove` over `remove`

* Really implement new coex fucntions for C3/S3

* Real implementation for `coex_schm_flexible_period_set` and `coex_schm_flexible_period_get`

* Mute warnings
2024-09-30 08:40:44 +00:00
Sergio Gasquez Arcos
fd57488ce3
Remove embedded-svc traits and feature (#2235)
* feat: Remove embedded-svc traits and feature

* docs: Changelog entry
2024-09-26 11:14:42 +00:00
Scott Mabin
117327e206
esp-config: allow negative values (#2204)
* esp-config: allow negative values

* Add small test for parsing erroneous negative values

* split Value::Number into signed and unsigned
2024-09-24 07:07:06 +00:00
Dániel Buga
3ee8fa61ee
Apply rustfmt fix (#2210) 2024-09-23 08:19:29 +00:00
Sergio Gasquez Arcos
3d0a1998fa
Allow configuring the watchdogs in the init config (#2180)
* feat: Allow configuring the watchdogs in the init config

* docs: Update changelog

* refactor: Remove unnecesary unsafe

* feat: Add a config module

* test: Add some init tests

* style: Rename all ocurrences to esp_hal::config::Config::default()

* style: Fix format

* fix: Doc errors

* revert: Move Config struct to lib.rs

* tests: Add default config test

* test: Add a test with CpuClock::max()

* test: Add timg1 test

* feat: Move Config struct to config module and reexport it in lib.rs

* fix: Fix init compilation for C2

* revert: Move Config struct to config module and reexport it in lib.rs

* fix: Use proper timergroup
2024-09-20 13:51:35 +00:00
Björn Quentin
370f54119f
Create mutexes in heap memory (#2202)
* Create mutexes in heap memory

* CHANGELOG.md

* Remove unnecessary CS usage
2024-09-20 12:45:57 +00:00
Scott Mabin
ba63beb3b2
Move binary logging to sys crate (#2183)
* Move binary logging to sys crate

* make ieee take radio clks by value

* rename wifi-logs to binary-logs and fix compilation

* update sys to use correct size types

* move rtc_clk_xtal_freq_get to esp-hal

* changelogs and migration guide

* s/wifi-logs/sys-logs/g

* activate log features for esp-wifi-sys

* ble log fix c2

* fix logs using latest sys rev

* fix warning
2024-09-19 15:19:54 +00:00
Scott Mabin
d9d771706f
esp-config (#2156)
* Initial esp-config poc, replacing the place-spi-driver-in-ram feature

* Allow documentation generation for configuration options

* add `Value::Number` and a macro to parse

* Add Value::String and replace esp-wifi's config

* repo maint

* make bool parsing stricter and number parsing more flexible

* use hand rolled const str to int

* Collect unknown config options

* friendly errors

* also batch invalid values

* dump msrv to 1.79

* Mention perf boost from disabling logging

* review suggestions

* output selected config

* changelogs and migration guides

* review feedback

* avoid multiple case conversions where possible

* refactor generate, fix bug, add full test

* run host tests in CI

* add more esp-config tests

* review comments

* add cargo env workaround
2024-09-19 08:58:29 +00:00
Björn Quentin
831df5a83c
Be more clear about the esp-alloc feature in esp-wifi's migration guide (#2165) 2024-09-16 11:21:11 +00:00
Dániel Buga
dfb40c0416
Fix overflowing subtraction (#2164) 2024-09-16 10:47:16 +00:00
Dániel Buga
e7dab298f5
Rename and wrap ErasedTimer (#2144)
* Rename and wrap ErasedTimer

* Also rename conversion trait
2024-09-11 20:29:21 +00:00
Dániel Buga
7a733a75db
GPIO interconnect (#2128)
* Allow accessing signal list via ErasedPin

* Replace AnyPin with more flexible signal config

* Update tests and examples

* Fix enable_from_gpio value

* Access signals from pin drivers

* DummyPin is not a pin

* Remove redundant public fns

* Various fixes, rename ErasedPin

* Changelog

* rustfmt

* Update i8080

* Typos and endless recursion

* Drop Pin suffix from traits

* Extract AF conversion

* Touch up changelog

* Clean up spi tests

* Refactor pull resistor handling

* Don't disable configured output functionality

* Clean up TODO

* Tweak docs

* Clean up examples
2024-09-11 15:15:55 +00:00
Björn Quentin
ddf4ff7e9d
Make sure we can compile with defmt (#2126)
* Set DEFMT_LOG in CI

* Set DEFMT_LOG in CI

* Set DEFMT_LOG in CI

* Fix BLE vs DEFMT issue

* Fix ESP32 defmt problems in psram.rs

* Use `defmt` feature on `bt-hci`
2024-09-09 16:40:30 +00:00
Björn Quentin
6295c5f9da
Esp wifi/fix wifi logs (#2117)
* Fix `wifi-logs` feature

* Some clarifications in the esp-wifi migration guide

* CHANGELOG.md

* Review comments

* Check more features
2024-09-09 10:15:52 +00:00
Björn Quentin
d71434adfb
esp-wifi uses global allocator, esp-alloc supports multiple regions (#2099)
* esp-wifi uses global allocator, esp-alloc supports multiple regions

* CHANGELOG.md

* Apply suggestions

* Use `alloc` when linting esp-wifi

* Make coex example build for ESP32

* Re-enable some wifi examples for ESP32-S2

* Optionally depend on `esp-alloc` (by default)

* Rename INSTANCE -> HEAP
2024-09-06 15:42:19 +00:00
Ulf Lilleengen
93f1012663
Add integration with bt-hci crate (#1971)
* Add integration with bt-hci crate

Implementing traits from bt-hci allows the BleConnector to
be used with the Trouble BLE stack.

* use packed based read interface

* Improve example to allow another connection after disconnect

* update trouble version

* Workaround for spurious command complete events

* fix formatting

* ignore notify errors in example

* fix clippy warnings

* remove async feature from hal dependency

* remove deprecated feature from example

* Adopt to api changes

* Api fix for esp32

* Set rust-version of esp-wifi

* bump MSRV to 1.77 for CI and esp-hal

* Add changelog entry
2024-09-06 13:08:25 +00:00
liebman
492e35aa74
esp-wifi: other crates also provide strchr (littlefs2-sys) (#2096)
* esp-wifi: other crates also provide strchr (littlefs2-sys)

* esp-wifi: other crates also provide strchr (littlefs2-sys)

* changelog

* fmt :-(
2024-09-06 09:22:33 +00:00
Scott Mabin
70126c8149
Rename esp_hal::time::current_time to esp_hal::time::now (#2091)
* rename esp_hal::time::current_time to esp_hal::time::uptime

* changelog

* move more things to init

* s/uptime/now/g
2024-09-05 14:57:56 +00:00
Dániel Buga
99bf346898
Remove the need to manually pass clocks around (#1999)
* Clean up passing clocks to drivers

* Update changelog

* Initialise Clocks in a critical section

* Fix calling now() before init

* Fix doc

* Fix esp-wifi migration guide

* Add safety comment

* Update tests
2024-09-04 14:13:51 +00:00
Jesse Braham
b7b916f03a
Remove most trait implementation features from esp-hal (#2070)
* Eliminate esp-hal's `ufmt` feature

* Eliminate esp-hal's `embedded-hal-02` feature

* Eliminate esp-hal's `embedded-hal` feature

* Eliminate esp-hal's `embedded-io` feature

* Eliminate esp-hal's `async` feature

* Update `CHANGELOG.md`

* Remove `async` from required features for HIL tests

* Update migration guide
2024-09-04 06:15:27 +00:00
Björn Quentin
0cf7abfc47
Make esp-wifi build on stable, again. Bump to 0.9.1 (#2067)
* Make esp-wifi build on stable, again. Bump to 0.9.1

* CHANGELOG.md

* MSRV check esp-wifi

* ESP32-S2 doesn't support Bluetooth
2024-09-03 16:10:20 +02:00
Björn Quentin
9c3b17166f
Bump to esp-wifi 0.9.0 (#2066) 2024-09-03 13:30:28 +01:00
Björn Quentin
5420ce0959
WPA2 ENTERPRISE (#2004)
* WPA2 ENTERPRISE

* Defmt, Clippy, Changelog

* Defmt, again

* Clippy, again

* Mention corresponding JIRA ticket

* Rename

* fmt

* Use Mutex in scheduler

* Adapt wifi_delete_queue

* Adapt log level
2024-09-03 11:22:39 +00:00
Sergio Gasquez Arcos
f9ab55c38f
fix: Fix nightly errors (#1934) 2024-08-30 14:08:06 +00:00
Jesse Braham
533288d351
Begin next release cycle (#2039)
Co-authored-by: Scott Mabin <scott@mabez.dev>
2024-08-30 12:28:14 +00:00
Jesse Braham
5917275108
Version 0.20.0 (#2038)
* Update package dependencies and bump version numbers

* Update `CHANGELOG.md` for each package to be published

* Remember to update `xtensa-lx-rt` too :)

* Add and use TrapFrame::new() in esp-wifi

* Bump `xtensa-lx-rt` by minor instead of patch, as there are breaking changes

---------

Co-authored-by: Dániel Buga <bugadani@gmail.com>
2024-08-29 19:29:33 +00:00
Dániel Buga
1003ce0c0f
Clean up SHA, RSA, mandate #[must_use] on Futures (#2000)
* Janitor go brr

* Clean up SHA

* Use max CPU speed

* RSA cleanup part 1

* Clean up nonsense comments

* Mark all futures as must_use
2024-08-27 10:43:58 +00:00
Frostie314159
d1acacb757
Implement Sniffer API (#1935)
* Implemented queue_msg_waiting.

* Fmt.

* Adjusted changelog.

* Fixed CI.

* Fixed pointer mutability.

* Implemented experimental sniffer api.

* Fixed CI..

* Added safety comment.

* Featured gated, PromiscuousPkt

* Format.

* Adjusted imports.

* Added injection example.

* Made RxControlInfo::from_raw public.

* Format.

* Added sniffer example.
2024-08-19 06:51:18 +00:00
Dániel Buga
f95ab0def5
Simplify initialization APIs (#1957)
* Accept more types in embassy::init

* Apply the same treatment to esp-wifi

* Changelog

* Clean up

* Add doc examples

* Fix Alarm generic parameters
2024-08-16 16:33:29 +00:00
Kirill Mikhailov
f1ec4a2ac9
Removing raw addresses manipulations - part 3 (#1892)
* WIP state

* More fixes

* Roll back `esp-storage` changes

* Small fixes

Will not work, needs another patch for PACs

* update pacs dep

* Lint

* Get rid of unnecessary if-else

fix

* New pacs version
2024-08-14 16:38:00 +00:00
Frostie314159
1173aac945
Implemented queue_msg_waiting. (#1925)
* Implemented queue_msg_waiting.

* Fmt.

* Adjusted changelog.

* Fixed CI.

* Fixed pointer mutability.
2024-08-14 12:44:48 +00:00