Pico W WiFi + LED

Browse source code on GitHub

Overview

This sample demonstrates concurrent WiFi and LED operation on the Raspberry Pi Pico W and Pico 2 W. A background thread blinks the onboard LED via the CYW43 GPIO driver while the main thread performs a WiFi scan.

Requirements

This sample requires a board with an Infineon CYW43439 WiFi chip:

  • Raspberry Pi Pico W (rpi_pico/rp2040/w)

  • Raspberry Pi Pico 2 W (rpi_pico2/rp2350a/m33/w)

Building and Running

# From the root of the zephyr repository
west build -b rpi_pico2/rp2350a/m33/w samples/boards/raspberrypi/pico_w_wifi_led
west flash

Sample Output

*** Booting Zephyr OS build v4.3.0 ***
Pico W WiFi + LED Demo
LED blinking started
Starting WiFi scan...
  SSID: MyNetwork              CH:  6 RSSI: -45
WiFi scan complete
Demo complete - LED continues blinking

See also

GPIO