-
Notifications
You must be signed in to change notification settings - Fork 214
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add esp wifi to monorepo with history #1582
Add esp wifi to monorepo with history #1582
Conversation
All our PRs get squashed by the merge queue FYI, if you're not aware. |
Ah true ... but at least the contributors will be added to that commit |
Hmm, so I guess the fun here will be that we need to make esp-wifi (and its examples) run on stable :D. Other than that this is looking good so far. |
* switch to heapless for SimpleQueue * Merge Network into WifiStack - Merge the Network and Wifi structs into WifiStack - Get it building & running with just TCP socket for now * get dhcp example building with changes and no warnings * fixup error checking * Fix other examples * fmt * Remove redundant comment * fix unused results * bump BT_INTERNAL_QUEUE to 10 * add back static ip configuration in work()
* Async WiFi with embassy - Add embassy_net::Driver impl for WifiDevice - Add embassy_dhcp example - Update README with embassy_dhcp running instruction Notes: TCP connection may fail a few times until the esp gets an IP address, it seems there is no way to await dhcp completion in embassy_net yet. * Put embassy-net behind feature - Whilst other embassy crates can be used behind the async feature, embassy-net should be put behind its own feature * wait for dhcp to complete in example * fmt * Simplify embedded-io import * Update README, use new bleps
Regardless of whether we can do anything with the incoming packets, we *must* ensure the drivers packet memory is free.
* Add async scan_n() * WifiFuture and async connect - Don't compile the blocking `WifiStack` when using the embassy-net feature - Improve WifiEventFuture to have a waker for each WifiEvent - Stub out async versions of embedded-svc trait * Add async start/stop/connect - All works first time - Fails on reconnect, but this is a bug in the svc implementation - Implements `IntoFuture` for `WifiEvent` - Is it possible to await the event in two seperate futures? or will one overwrite the other? * Async connect/disconnect - Now working in fully async fashion - Improved embedded-svc `Wifi` trait impl - is_started etc still needs work - spotted memory leak when not transmitting anything * Fix async start Can now succesfully reconnect to a network * Fix `is_started` Closes esp-rs/esp-wifi-sys#126 * link state waker * Only wake the transmit waker if we have something to send * Correct WifiEventFuture Instead of relying on the current state, it now tracks events and clears the event before trying to listen. * wifi: split into device and controller - Split the wifi into two parts, the device part which is used within the network stack and the controller, which handles the wifi connection parts - Remove the uneeded `Wifi` impl now that the two parts are separate * undo cfg of blocking stack * small fixups * controller: add `wait_for_event` - This solves the waker overwrite issue, as the function takes `&mut self`, meaning its only possible to await for the same event once. - Sadly this means we have to remove the really clean `into_future` impl :(, but atleast we don't have to bump MSRV. * Fix examples * fmt * make globals pub(crate) * make all events awaitable - Add wakers for all events - Add some docs - Make WifiEventFuture pub(crate) * fix esp-now
* Add basic AP support * Remove IS_AP global static
* Adjust for latest HAL * ESP32-S3 adjustments needed after update * Use ESP32-C2 HAL 0.5.1
* ESP32-C6 WiFi support * Explain the `run_after_initialze_hack` function
* Move some boilerplate code into own examples-util crate * Have an `examples-esp32XXX` folder for each target * Cleanup dependencies * Use workspace dependencies * Adjust CI workflow * `cd` into the right directories * Don't pass chip selection features for examples * Fix ESP32-C6 CI
* Use RADIO singletons - Uses the RADIO singletons when creating wifi/ble/esp_now - Updates all examples to use the singletons - Simplfy esp_now::ReceiveFuture * Fixup examples * fmt * fix examples
* Add set_mode * Revert unnecessary changes * Review changes * Removed unecessary change * Review changes, merge conflict fix
* Add missing ROM functions for ESP32-S3/ESP32-S2 * Cut down nocoex + big-heap heap-size
* Async BLE HCI * Add async-ble example * Use nightly-2023-03-09 for CI (for now)
* Prepare CHANGELOG.md for next release cycle * Fix docs-rs build
* Remove direct embedded-hal v0.2 dependency * Add changelog entry.
4f0cfde
to
6ab404b
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So, for what I hope are obvious reasons, I am not going to review the source code for any of the added packages here 😁 I trust that things are in order, as that's all I can do here.
However, I have reviewed the changes, and think we're in good shape. I have left a few comments, but nothing here is urgent. Frankly this is probably fine to merge as-is.
One small request, could you please also add EspWifi
to the Package
enum in the xtask
package? I keep forgetting to do this when I add packages, so trying to build the habit for myself and others 😅
(Thank you for your work here, really excited to have most of our packages in a single monorepo moving forward!)
Thanks for the hint .... I totally forgot about that 👍 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks! Excited to see this merged :D
Thx! Reducing the dependency hell using main :) |
I also kept all the commits because
This is not just a copy from esp-wifi since some changes were needed to get it working with current
main
- however most changes should be straight forward