esp32-wasm-base
esp32-wasm-base copied to clipboard
MQTT support
MQTT should be managed by the base application, configured via the command line or web APIs, and functionally available to WASM tasks.
API
How to structure the API to be useful to a task is an interesting problem. On the assumption that tasks will predominantly be sleeping, a poll-based approach seems reasonable? Something like:
send(char* topic, char* data)available()receive(char* topic, char* data)
It might be valuable to consider how to propagate events between tasks and whether it's viable to have a mechanism for waiting on events (eg. new MQTT message, timer timeout, external gpio) rather than just sleeping and polling.
Tasks:
- [ ] MQTT manager
- [ ] Configuration loading (#14)
- [ ] Console commands
- [ ] Endpoint / Data Manager Integration (#15)
Progress here.