aditya0yadav opened a new issue, #18498:
URL: https://github.com/apache/nuttx/issues/18498
### Description
Hey everyone,
I am planning to work on this project: Add support to ESP Hosted on NuttX.
Most boards don’t have built-in WiFi or BLE, so every time someone wants to
connect to a network, they have to handle low-level stuff on the ESP32
themselves. It works, but it’s kind of a pain and slows things down.
What I’m thinking is to make a POSIX-style driver for the ESP32 on NuttX so
apps can just open a device and use it. Something like:
1. Auto-initialize the ESP32 and network stack when the device opens
(probably over SPI for speed)
2. Set WiFi credentials easily (SSID, password, security)
3. Send/receive network data with write()/read()
4. Optionally scan nearby networks
5. BLE support similar to WiFi
6. Handle ESP32 power modes automatically
7. Include a few example apps under /apps/
Here’s roughly how it might look in code:
```c id="j8ymzf"
int fd = open("/dev/esp_hosted0", O_RDWR); // start ESP32 over SPI
struct wifi_config cfg = { "SSID_NAME", "PASSWORD", WPA2 };
ioctl(fd, ESP_IOCTL_SET_WIFI, &cfg); // connect WiFi
write(fd, data, len); // send something
read(fd, buffer, sizeof(buffer)); // read response
close(fd); // close it
```
Everything else—the SPI communication, network management, BLE—would happen
inside the driver, so apps don’t have to worry about it.
I thought about some alternatives too:
Doing all ESP32 handling in each app – too messy
One big ioctl for everything – could mix data and control and get confusing
Separate device files for BLE/optional scans – seems cleaner
A few extra points:
Difficulty: pretty big project (~350 hours)
Mentors: Alan Carvalho de Assis and other devs
Resources:
1. [ESP-Hosted](https://github.com/espressif/esp-hosted)
2. [NuttX docs](https://nuttx.apache.org/docs/latest/)
3. [ESP32 hosted MCU](https://github.com/espressif/esp-hosted-mcu)
Some questions I have:
Has anyone tried an ESP-Hosted driver on NuttX before?
Should we support UART later, or just SPI for now?
Separate devices or merge optional features into one ioctl?
Which boards are best for testing WiFi and BLE?
About me
I’m Aditya Yadav, a previous GSoC student (2025) with Apache. I’ve worked on
multiple Apache open-source projects and am especially dedicated to
contributing to the Apache ecosystem.
### Verification
- [x] I have verified before submitting the report.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]