Skip to content

Commit

Permalink
Add feature to examples
Browse files Browse the repository at this point in the history
  • Loading branch information
bugadani committed Dec 4, 2024
1 parent 3a96548 commit 28fcf19
Show file tree
Hide file tree
Showing 46 changed files with 46 additions and 33 deletions.
1 change: 1 addition & 0 deletions examples/src/bin/debug_assist.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
//! Uncomment the functionality you want to test
//% CHIPS: esp32c2 esp32c3 esp32c6 esp32h2 esp32s3
//% FEATURES: esp-hal/unstable

#![no_std]
#![no_main]
Expand Down
2 changes: 1 addition & 1 deletion examples/src/bin/dma_extmem2mem.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//! Uses DMA to copy psram to internal memory.
//% FEATURES: esp-hal/log esp-hal/octal-psram aligned
//% FEATURES: esp-hal/log esp-hal/octal-psram aligned esp-hal/unstable
//% CHIPS: esp32s3

#![no_std]
Expand Down
2 changes: 1 addition & 1 deletion examples/src/bin/dma_mem2mem.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//! Uses DMA to copy memory to memory.
//% FEATURES: esp-hal/log
//% FEATURES: esp-hal/log esp-hal/unstable
//% CHIPS: esp32s3 esp32c2 esp32c3 esp32c6 esp32h2

#![no_std]
Expand Down
2 changes: 1 addition & 1 deletion examples/src/bin/embassy_hello_world.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
//! concurrently.
//% CHIPS: esp32 esp32c2 esp32c3 esp32c6 esp32h2 esp32s2 esp32s3
//% FEATURES: embassy esp-hal-embassy/integrated-timers
//% FEATURES: embassy esp-hal-embassy/integrated-timers esp-hal/unstable

#![no_std]
#![no_main]
Expand Down
2 changes: 1 addition & 1 deletion examples/src/bin/embassy_multicore.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
//! - LED => GPIO0
//% CHIPS: esp32 esp32s3
//% FEATURES: embassy embassy-generic-timers
//% FEATURES: embassy embassy-generic-timers esp-hal/unstable

#![no_std]
#![no_main]
Expand Down
2 changes: 1 addition & 1 deletion examples/src/bin/embassy_multicore_interrupt.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
//! - LED => GPIO0
//% CHIPS: esp32 esp32s3
//% FEATURES: embassy embassy-generic-timers
//% FEATURES: embassy embassy-generic-timers esp-hal/unstable

#![no_std]
#![no_main]
Expand Down
2 changes: 1 addition & 1 deletion examples/src/bin/embassy_multiprio.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
// The interrupt-executor is created in `main` and is used to spawn `high_prio`.

//% CHIPS: esp32 esp32c2 esp32c3 esp32c6 esp32h2 esp32s2 esp32s3
//% FEATURES: embassy esp-hal-embassy/log esp-hal-embassy/integrated-timers
//% FEATURES: embassy esp-hal-embassy/log esp-hal-embassy/integrated-timers esp-hal/unstable

#![no_std]
#![no_main]
Expand Down
2 changes: 1 addition & 1 deletion examples/src/bin/embassy_rmt_rx.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
//! - Connect GPIO4 and GPIO5
//% CHIPS: esp32 esp32c3 esp32c6 esp32h2 esp32s2 esp32s3
//% FEATURES: embassy embassy-generic-timers
//% FEATURES: embassy embassy-generic-timers esp-hal/unstable

#![no_std]
#![no_main]
Expand Down
2 changes: 1 addition & 1 deletion examples/src/bin/embassy_rmt_tx.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
//! - generated pulses => GPIO4
//% CHIPS: esp32 esp32c3 esp32c6 esp32h2 esp32s2 esp32s3
//% FEATURES: embassy embassy-generic-timers
//% FEATURES: embassy embassy-generic-timers esp-hal/unstable

#![no_std]
#![no_main]
Expand Down
2 changes: 1 addition & 1 deletion examples/src/bin/embassy_serial.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
//! writing to and reading from UART.
//% CHIPS: esp32 esp32c2 esp32c3 esp32c6 esp32h2 esp32s2 esp32s3
//% FEATURES: embassy embassy-generic-timers
//% FEATURES: embassy embassy-generic-timers esp-hal/unstable

#![no_std]
#![no_main]
Expand Down
2 changes: 1 addition & 1 deletion examples/src/bin/embassy_spi.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
//! CS => GPIO5
//% CHIPS: esp32 esp32c2 esp32c3 esp32c6 esp32h2 esp32s2 esp32s3
//% FEATURES: embassy embassy-generic-timers
//% FEATURES: embassy embassy-generic-timers esp-hal/unstable

#![no_std]
#![no_main]
Expand Down
2 changes: 1 addition & 1 deletion examples/src/bin/embassy_usb_serial.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
//! - DM => GPIO19
//% CHIPS: esp32s2 esp32s3
//% FEATURES: embassy embassy-generic-timers
//% FEATURES: embassy embassy-generic-timers esp-hal/unstable

#![no_std]
#![no_main]
Expand Down
2 changes: 1 addition & 1 deletion examples/src/bin/embassy_usb_serial_jtag.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
//! Most dev-kits use a USB-UART-bridge - in that case you won't see any output.
//% CHIPS: esp32c3 esp32c6 esp32h2 esp32s3
//% FEATURES: embassy embassy-generic-timers
//% FEATURES: embassy embassy-generic-timers esp-hal/unstable

#![no_std]
#![no_main]
Expand Down
1 change: 1 addition & 0 deletions examples/src/bin/etm_timer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
//! - LED => GPIO2
//% CHIPS: esp32c6 esp32h2
//% FEATURES: esp-hal/unstable

#![no_std]
#![no_main]
Expand Down
1 change: 1 addition & 0 deletions examples/src/bin/hmac.rs
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@
//! ```
//% CHIPS: esp32c3 esp32c6 esp32h2 esp32s2 esp32s3
//% FEATURES: esp-hal/unstable

#![no_std]
#![no_main]
Expand Down
1 change: 1 addition & 0 deletions examples/src/bin/ieee802154_receive_all_frames.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
//% CHIPS: esp32c6 esp32h2
//% FEATURES: esp-hal/unstable

#![no_std]
#![no_main]
Expand Down
1 change: 1 addition & 0 deletions examples/src/bin/ieee802154_receive_frame.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
//% CHIPS: esp32c6 esp32h2
//% FEATURES: esp-hal/unstable

#![no_std]
#![no_main]
Expand Down
1 change: 1 addition & 0 deletions examples/src/bin/ieee802154_send_broadcast_frame.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
//% CHIPS: esp32c6 esp32h2
//% FEATURES: esp-hal/unstable

#![no_std]
#![no_main]
Expand Down
1 change: 1 addition & 0 deletions examples/src/bin/ieee802154_send_frame.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
//% CHIPS: esp32c6 esp32h2
//% FEATURES: esp-hal/unstable

#![no_std]
#![no_main]
Expand Down
1 change: 1 addition & 0 deletions examples/src/bin/ieee802154_sniffer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
//! Besides the runtime changeable channel and the output format it's almost identical to ieee802154_receive_all_frames
//% CHIPS: esp32c6 esp32h2
//% FEATURES: esp-hal/unstable

#![no_std]
#![no_main]
Expand Down
1 change: 1 addition & 0 deletions examples/src/bin/lp_core_basic.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
//! - LED => GPIO1
//% CHIPS: esp32c6
//% FEATURES: esp-hal/unstable

#![no_std]
#![no_main]
Expand Down
2 changes: 1 addition & 1 deletion examples/src/bin/spi_loopback_dma_psram.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
//! If your module is quad PSRAM then you need to change the `psram` feature in the
//! in the features line below to `quad-psram`.
//% FEATURES: esp-hal/log esp-hal/octal-psram
//% FEATURES: esp-hal/log esp-hal/octal-psram esp-hal/unstable
//% CHIPS: esp32s3

#![no_std]
Expand Down
1 change: 1 addition & 0 deletions examples/src/bin/spi_slave_dma.rs
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
//! so no immediate neighbor is available.
//% CHIPS: esp32c2 esp32c3 esp32c6 esp32h2 esp32s2 esp32s3
//% FEATURES: esp-hal/unstable

#![no_std]
#![no_main]
Expand Down
1 change: 1 addition & 0 deletions examples/src/bin/touch.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
//! pad on a PCB).
//% CHIPS: esp32
//% FEATURES: esp-hal/unstable

#![no_std]
#![no_main]
Expand Down
1 change: 1 addition & 0 deletions examples/src/bin/twai.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
//! * change the `tx_pin` and `rx_pin` to the appropriate pins for your boards.
//% CHIPS: esp32 esp32c3 esp32c6 esp32h2 esp32s2 esp32s3
//% FEATURES: esp-hal/unstable

#![no_std]
#![no_main]
Expand Down
1 change: 1 addition & 0 deletions examples/src/bin/usb_serial.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
//! - DM => GPIO19
//% CHIPS: esp32s2 esp32s3
//% FEATURES: esp-hal/unstable

#![no_std]
#![no_main]
Expand Down
2 changes: 1 addition & 1 deletion examples/src/bin/wifi_80211_tx.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
//! Periodically transmits a beacon frame.
//!
//% FEATURES: esp-wifi esp-wifi/wifi esp-wifi/utils esp-wifi/sniffer
//% FEATURES: esp-wifi esp-wifi/wifi esp-wifi/utils esp-wifi/sniffer esp-hal/unstable
//% CHIPS: esp32 esp32s2 esp32s3 esp32c2 esp32c3 esp32c6

#![no_std]
Expand Down
2 changes: 1 addition & 1 deletion examples/src/bin/wifi_access_point.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
//! On Android you might need to choose _Keep Accesspoint_ when it tells you the WiFi has no internet connection, Chrome might not want to load the URL - you can use a shell and try `curl` and `ping`
//!
//% FEATURES: esp-wifi esp-wifi/wifi esp-wifi/utils
//% FEATURES: esp-wifi esp-wifi/wifi esp-wifi/utils esp-hal/unstable
//% CHIPS: esp32 esp32s2 esp32s3 esp32c2 esp32c3 esp32c6

#![no_std]
Expand Down
2 changes: 1 addition & 1 deletion examples/src/bin/wifi_access_point_with_sta.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
//! On Android you might need to choose _Keep Accesspoint_ when it tells you the WiFi has no internet connection, Chrome might not want to load the URL - you can use a shell and try `curl` and `ping`
//!
//% FEATURES: esp-wifi esp-wifi/wifi esp-wifi/utils
//% FEATURES: esp-wifi esp-wifi/wifi esp-wifi/utils esp-hal/unstable
//% CHIPS: esp32 esp32s2 esp32s3 esp32c2 esp32c3 esp32c6

#![no_std]
Expand Down
2 changes: 1 addition & 1 deletion examples/src/bin/wifi_bench.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
//! Ensure you have set the IP of your local machine in the `HOST_IP` env variable. E.g `HOST_IP="192.168.0.24"` and also set SSID and PASSWORD env variable before running this example.
//!
//% FEATURES: esp-wifi esp-wifi/wifi esp-wifi/utils
//% FEATURES: esp-wifi esp-wifi/wifi esp-wifi/utils esp-hal/unstable
//% CHIPS: esp32 esp32s2 esp32s3 esp32c2 esp32c3 esp32c6

#![no_std]
Expand Down
2 changes: 1 addition & 1 deletion examples/src/bin/wifi_ble.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
//! - offers one service with three characteristics (one is read/write, one is write only, one is read/write/notify)
//! - pressing the boot-button on a dev-board will send a notification if it is subscribed
//% FEATURES: esp-wifi esp-wifi/ble
//% FEATURES: esp-wifi esp-wifi/ble esp-hal/unstable
//% CHIPS: esp32 esp32s3 esp32c2 esp32c3 esp32c6 esp32h2

#![no_std]
Expand Down
2 changes: 1 addition & 1 deletion examples/src/bin/wifi_coex.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
//! Note: On ESP32-C2 and ESP32-C3 you need a wifi-heap size of 70000, on ESP32-C6 you need 80000 and a tx_queue_size of 10
//!
//% FEATURES: esp-wifi esp-wifi/wifi esp-wifi/utils esp-wifi/ble esp-wifi/coex
//% FEATURES: esp-wifi esp-wifi/wifi esp-wifi/utils esp-wifi/ble esp-wifi/coex esp-hal/unstable
//% CHIPS: esp32 esp32s3 esp32c2 esp32c3 esp32c6

#![allow(static_mut_refs)]
Expand Down
2 changes: 1 addition & 1 deletion examples/src/bin/wifi_csi.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
//! Set SSID and PASSWORD env variable before running this example.
//!
//% FEATURES: esp-wifi esp-wifi/wifi esp-wifi/utils esp-wifi/log
//% FEATURES: esp-wifi esp-wifi/wifi esp-wifi/utils esp-wifi/log esp-hal/unstable
//% CHIPS: esp32 esp32s2 esp32s3 esp32c2 esp32c3 esp32c6

#![no_std]
Expand Down
2 changes: 1 addition & 1 deletion examples/src/bin/wifi_dhcp.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
//! This gets an ip address via DHCP then performs an HTTP get request to some "random" server
//!
//% FEATURES: esp-wifi esp-wifi/wifi esp-wifi/utils
//% FEATURES: esp-wifi esp-wifi/wifi esp-wifi/utils esp-hal/unstable
//% CHIPS: esp32 esp32s2 esp32s3 esp32c2 esp32c3 esp32c6

#![no_std]
Expand Down
2 changes: 1 addition & 1 deletion examples/src/bin/wifi_dhcp_smoltcp_nal.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
//! This gets an ip address via DHCP then performs an HTTP get request to some "random" server
//! When using USB-SERIAL-JTAG you may have to activate the feature `phy-enable-usb` in the esp-wifi crate.
//% FEATURES: esp-wifi esp-wifi/wifi esp-wifi/utils
//% FEATURES: esp-wifi esp-wifi/wifi esp-wifi/utils esp-hal/unstable
//% CHIPS: esp32 esp32s2 esp32s3 esp32c2 esp32c3 esp32c6

#![no_std]
Expand Down
2 changes: 1 addition & 1 deletion examples/src/bin/wifi_embassy_access_point.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
//! Because of the huge task-arena size configured this won't work on ESP32-S2
//!
//% FEATURES: embassy embassy-generic-timers esp-wifi esp-wifi/wifi esp-wifi/utils esp-wifi/sniffer
//% FEATURES: embassy embassy-generic-timers esp-wifi esp-wifi/wifi esp-wifi/utils esp-wifi/sniffer esp-hal/unstable
//% CHIPS: esp32 esp32s2 esp32s3 esp32c2 esp32c3 esp32c6

#![no_std]
Expand Down
2 changes: 1 addition & 1 deletion examples/src/bin/wifi_embassy_access_point_with_sta.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
//! Because of the huge task-arena size configured this won't work on ESP32-S2
//!
//% FEATURES: embassy embassy-generic-timers esp-wifi esp-wifi/wifi esp-wifi/utils
//% FEATURES: embassy embassy-generic-timers esp-wifi esp-wifi/wifi esp-wifi/utils esp-hal/unstable
//% CHIPS: esp32 esp32s2 esp32s3 esp32c2 esp32c3 esp32c6

#![no_std]
Expand Down
2 changes: 1 addition & 1 deletion examples/src/bin/wifi_embassy_bench.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
//! Because of the huge task-arena size configured this won't work on ESP32-S2 and ESP32-C2
//!
//% FEATURES: embassy embassy-generic-timers esp-wifi esp-wifi/wifi esp-wifi/utils
//% FEATURES: embassy embassy-generic-timers esp-wifi esp-wifi/wifi esp-wifi/utils esp-hal/unstable
//% CHIPS: esp32 esp32s2 esp32s3 esp32c3 esp32c6

#![allow(static_mut_refs)]
Expand Down
2 changes: 1 addition & 1 deletion examples/src/bin/wifi_embassy_ble.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
//! - offers one service with three characteristics (one is read/write, one is write only, one is read/write/notify)
//! - pressing the boot-button on a dev-board will send a notification if it is subscribed
//% FEATURES: embassy embassy-generic-timers esp-wifi esp-wifi/ble
//% FEATURES: embassy embassy-generic-timers esp-wifi esp-wifi/ble esp-hal/unstable
//% CHIPS: esp32 esp32s3 esp32c2 esp32c3 esp32c6 esp32h2

#![no_std]
Expand Down
2 changes: 1 addition & 1 deletion examples/src/bin/wifi_embassy_dhcp.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
//!
//! Because of the huge task-arena size configured this won't work on ESP32-S2
//% FEATURES: embassy embassy-generic-timers esp-wifi esp-wifi/wifi esp-wifi/utils
//% FEATURES: embassy embassy-generic-timers esp-wifi esp-wifi/wifi esp-wifi/utils esp-hal/unstable
//% CHIPS: esp32 esp32s2 esp32s3 esp32c2 esp32c3 esp32c6

#![no_std]
Expand Down
2 changes: 1 addition & 1 deletion examples/src/bin/wifi_embassy_esp_now.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
//!
//! Because of the huge task-arena size configured this won't work on ESP32-S2
//% FEATURES: embassy embassy-generic-timers esp-wifi esp-wifi/wifi esp-wifi/utils esp-wifi/esp-now
//% FEATURES: embassy embassy-generic-timers esp-wifi esp-wifi/wifi esp-wifi/utils esp-wifi/esp-now esp-hal/unstable
//% CHIPS: esp32 esp32s2 esp32s3 esp32c2 esp32c3 esp32c6

#![no_std]
Expand Down
2 changes: 1 addition & 1 deletion examples/src/bin/wifi_embassy_esp_now_duplex.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
//!
//! Because of the huge task-arena size configured this won't work on ESP32-S2
//% FEATURES: embassy embassy-generic-timers esp-wifi esp-wifi/wifi esp-wifi/utils esp-wifi/esp-now
//% FEATURES: embassy embassy-generic-timers esp-wifi esp-wifi/wifi esp-wifi/utils esp-wifi/esp-now esp-hal/unstable
//% CHIPS: esp32 esp32s2 esp32s3 esp32c2 esp32c3 esp32c6

#![no_std]
Expand Down
2 changes: 1 addition & 1 deletion examples/src/bin/wifi_embassy_trouble.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
//! - automatically notifies subscribers every second
//!
//% FEATURES: embassy embassy-generic-timers esp-wifi esp-wifi/ble
//% FEATURES: embassy embassy-generic-timers esp-wifi esp-wifi/ble esp-hal/unstable
//% CHIPS: esp32 esp32s3 esp32c2 esp32c3 esp32c6 esp32h2

#![no_std]
Expand Down
2 changes: 1 addition & 1 deletion examples/src/bin/wifi_esp_now.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
//!
//! Broadcasts, receives and sends messages via esp-now
//% FEATURES: esp-wifi esp-wifi/wifi esp-wifi/utils esp-wifi/esp-now
//% FEATURES: esp-wifi esp-wifi/wifi esp-wifi/utils esp-wifi/esp-now esp-hal/unstable
//% CHIPS: esp32 esp32s2 esp32s3 esp32c2 esp32c3 esp32c6

#![no_std]
Expand Down
2 changes: 1 addition & 1 deletion examples/src/bin/wifi_sniffer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
//! Sniffs for beacon frames.
//!
//% FEATURES: esp-wifi esp-wifi/wifi esp-wifi/utils esp-wifi/sniffer
//% FEATURES: esp-wifi esp-wifi/wifi esp-wifi/utils esp-wifi/sniffer esp-hal/unstable
//% CHIPS: esp32 esp32s2 esp32s3 esp32c2 esp32c3 esp32c6

#![no_std]
Expand Down
2 changes: 1 addition & 1 deletion examples/src/bin/wifi_static_ip.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
//! - responds with some HTML content when connecting to port 8080
//!
//% FEATURES: esp-wifi esp-wifi/wifi esp-wifi/utils
//% FEATURES: esp-wifi esp-wifi/wifi esp-wifi/utils esp-hal/unstable
//% CHIPS: esp32 esp32s2 esp32s3 esp32c2 esp32c3 esp32c6

#![no_std]
Expand Down

0 comments on commit 28fcf19

Please sign in to comment.