An open API service indexing awesome lists of open source software.

https://github.com/bitraf/embassy-skeleton

Simple Embassy outline for Pico W and Esp32-C3 OLED
https://github.com/bitraf/embassy-skeleton

Last synced: 15 days ago
JSON representation

Simple Embassy outline for Pico W and Esp32-C3 OLED

Awesome Lists containing this project

README

          

# Workshop in Embedded Rust with Embassy
_Hosted by Dag Bjørndal in Oslo on December 9th 2025_

The accompanying firmware code from this workshop illustrates use of the [Embassy](https://embassy.dev/book/index.html) framework. It is intended as a bare skeleton demonstration of cooperative multitasking. The following devices are featured:
* Raspberry Pi Pico W (ARM)
* Esp32c3 OLED (Risc-V)

| ![Raspberry Pi Pico W](./assets/picow.jpg "Raspberry Pi Pico W") | ![Esp32 C3 OLED](./assets/esp32c3.jpg "Esp32 C3 OLED") |
|----|----|

## Firmware Features
Both devices do the following:
* The device is initialized in **Embassy** and tasks are started
* The device **connects to Wi-Fi** using SSID and PSK read from src directory
* The onboard **LED is blinked** every second
* A small **web page is retrieved** from the the Internet every 10 seconds, and its content is logged
* **Logging** information is continously sent to the host computer

## Key Differences
The Esp32 device has a small OLED screen which is activated and written to. Dynamic memory allocation using heap is demonstrated on this device. The Esp32 device is connected directly to the host computer via USB. The Pico W device demonstrates using stack memory allocation only. This approach might be considered best practice. The Pico W is connected to the host computer via a programming probe (Picoprobe, ST-Link or Segger). The device uses _defmt_ to minimize bandwidth demand when logging to the host computer.

## Prerequisites to run on Esp32 C3 OLED
* Install Rust. Follow the instructions on [The Rust Programming Language](https://doc.rust-lang.org/book/ch01-01-installation.html).
* Install espflash with 'cargo install espflash --locked'.
* Connect device to host computer via USB cable.

## Prerequisites to run on Pico W
* Install Rust. Follow the instructions on [The Rust Programming Language](https://doc.rust-lang.org/book/ch01-01-installation.html).
* Install probe-rs. Follow the instructions on [probe-rs](https://probe.rs/docs/getting-started/installation/).
* Connect device to programming probe (Picoprobe, ST-Link or segger). Typically SWCLK, SWDIO, 5V and GND are needed. Connect programming probe to host computer.