Raspberry Pi Pico SDK Examples

Overview

Raspberry Pi Pico SDK Examples

Getting started

See Getting Started with the Raspberry Pi Pico and the README in the pico-sdk for information on getting up and running.

First Examples

App Description Link to prebuilt UF2
hello_serial The obligatory Hello World program for Pico (Output over serial version)
hello_usb The obligatory Hello World program for Pico (Output over USB version) https://rptl.io/pico-hello-usb
blink Blink an LED on and off. https://rptl.io/pico-blink

ADC

App Description
hello_adc Display the voltage from an ADC input.
joystick_display Display a Joystick X/Y input based on two ADC inputs.
adc_console An interactive shell for playing with the ADC. Includes example of free-running capture mode.
microphone_adc Read analog values from a microphone and plot the measured sound amplitude.

Clocks

App Description
hello_48MHz Change the system clock frequency to 48 MHz while running.
hello_gpout Use the general purpose clock outputs (GPOUT) to drive divisions of internal clocks onto GPIO outputs.
hello_resus Enable the clock resuscitate feature, "accidentally" stop the system clock, and show how we recover.

CMake

App Description
build_variants Builds two version of the same app with different configurations

DMA

App Description
hello_dma Use the DMA to copy data in memory.
control_blocks Build a control block list, to program a longer sequence of DMA transfers to the UART.
channel_irq Use an IRQ handler to reconfigure a DMA channel, in order to continuously drive data through a PIO state machine.

Flash

App Description
cache_perfctr Read and clear the cache performance counters. Show how they are affected by different types of flash reads.
nuke Obliterate the contents of flash. An example of a NO_FLASH binary (UF2 loaded directly into SRAM and runs in-place there). A useful utility to drag and drop onto your Pico if the need arises.
program Erase a flash sector, program one flash page, and read back the data.
xip_stream Stream data using the XIP stream hardware, which allows data to be DMA'd in the background whilst executing code from flash.
ssi_dma DMA directly from the flash interface (continuous SCK clocking) for maximum bulk read performance.

GPIO

App Description
hello_7segment Use the GPIOs to drive a seven segment LED display.
hello_gpio_irq Register an interrupt handler to run when a GPIO is toggled.
dht_sensor Use GPIO to bitbang the serial protocol for a DHT temperature/humidity sensor.

See also: blink, blinking an LED attached to a GPIO.

HW divider

App Description
hello_divider Show how to directly access the hardware integer dividers, in case AEABI injection is disabled.

I2C

App Description
bus_scan Scan the I2C bus for devices and display results.
bmp280_i2c Read and convert temperature and pressure data from a BMP280 sensor, attached to an I2C bus.
lcd_1602_i2c Display some text on a generic 16x2 character LCD display, via I2C.
lis3dh_i2c Read acceleration and temperature value from a LIS3DH sensor via I2C
mcp9808_i2c Read temperature, set limits and raise alerts when limits are surpassed.
mma8451_i2c Read acceleration from a MMA8451 accelerometer and set range and precision for the data.
mpl3115a2_i2c Interface with an MPL3115A2 altimeter, exploring interrupts and advanced board features, via I2C.
mpu6050_i2c Read acceleration and angular rate values from a MPU6050 accelerometer/gyro, attached to an I2C bus.
oled_i2c Convert and display a bitmap on a 128x32 SSD1306-driven OLED display
pa1010d_i2c Read GPS location data, parse and display data via I2C.
pcf8523_i2c Read time and date values from a real time clock. Set current time and alarms on it.

Interpolator

App Description
hello_interp A bundle of small examples, showing how to access the core-local interpolator hardware, and use most of its features.

Multicore

App Description
hello_multicore Launch a function on the second core, printf some messages on each core, and pass data back and forth through the mailbox FIFOs.
multicore_fifo_irqs On each core, register and interrupt handler for the mailbox FIFOs. Show how the interrupt fires when that core receives a message.
multicore_runner Set up the second core to accept, and run, any function pointer pushed into its mailbox FIFO. Push in a few pieces of code and get answers back.

Pico Board

App Description
blinky Blink "hello, world" in Morse code on Pico's LED
button Use Pico's BOOTSEL button as a regular button input, by temporarily suspending flash access.

PIO

App Description
hello_pio Absolutely minimal example showing how to control an LED by pushing values into a PIO FIFO.
apa102 Rainbow pattern on on a string of APA102 addressable RGB LEDs.
differential_manchester Send and receive differential Manchester-encoded serial (BMC).
hub75 Display an image on a 128x64 HUB75 RGB LED matrix.
i2c Scan an I2C bus.
ir_nec Sending and receiving IR (infra-red) codes using the PIO.
logic_analyser Use PIO and DMA to capture a logic trace of some GPIOs, whilst a PWM unit is driving them.
manchester_encoding Send and receive Manchester-encoded serial.
pio_blink Set up some PIO state machines to blink LEDs at different frequencies, according to delay counts pushed into their FIFOs.
pwm Pulse width modulation on PIO. Use it to gradually fade the brightness of an LED.
spi Use PIO to erase, program and read an external SPI flash chip. A second example runs a loopback test with all four CPHA/CPOL combinations.
squarewave Drive a fast square wave onto a GPIO. This example accesses low-level PIO registers directly, instead of using the SDK functions.
st7789_lcd Set up PIO for 62.5 Mbps serial output, and use this to display a spinning image on a ST7789 serial LCD.
quadrature_encoder A quadrature encoder using PIO to maintain counts independent of the CPU.
uart_rx Implement the receive component of a UART serial port. Attach it to the spare Arm UART to see it receive characters.
uart_tx Implement the transmit component of a UART serial port, and print hello world.
ws2812 Examples of driving WS2812 addressable RGB LEDs.
addition Add two integers together using PIO. Only around 8 billion times slower than Cortex-M0+.

PWM

App Description
hello_pwm Minimal example of driving PWM output on GPIOs.
led_fade Fade an LED between low and high brightness. An interrupt handler updates the PWM slice's output level each time the counter wraps.
measure_duty_cycle Drives a PWM output at a range of duty cycles, and uses another PWM slice in input mode to measure the duty cycle.

Reset

App Description
hello_reset Perform a hard reset on some peripherals, then bring them back up.

RTC

App Description
hello_rtc Set a date/time on the RTC, then repeatedly print the current time, 10 times per second, to show it updating.
rtc_alarm Set an alarm on the RTC to trigger an interrupt at a date/time 5 seconds into the future.
rtc_alarm_repeat Trigger an RTC interrupt once per minute.

SPI

App Description
bme280_spi Attach a BME280 temperature/humidity/pressure sensor via SPI.
mpu9250_spi Attach a MPU9250 accelerometer/gyoscope via SPI.
spi_dma Use DMA to transfer data both to and from the SPI simultaneously. The SPI is configured for loopback.
spi_flash Erase, program and read a serial flash device attached to one of the SPI controllers.

System

App Description
hello_double_tap An LED blink with the pico_bootsel_via_double_reset library linked. This enters the USB bootloader when it detects the system being reset twice in quick succession, which is useful for boards with a reset button but no BOOTSEL button.
narrow_io_write Demonstrate the effects of 8-bit and 16-bit writes on a 32-bit IO register.
unique_board_id Read the 64 bit unique ID from external flash, which serves as a unique identifier for the board.

Timer

App Description
hello_timer Set callbacks on the system timer, which repeat at regular intervals. Cancel the timer when we're done.
periodic_sampler Sample GPIOs in a timer callback, and push the samples into a concurrency-safe queue. Pop data from the queue in code running in the foreground.
timer_lowlevel Example of direct access to the timer hardware. Not generally recommended, as the SDK may use the timer for IO timeouts.

UART

App Description
hello_uart Print some text from one of the UART serial ports, without going through stdio.
lcd_uart Display text and symbols on a 16x02 RGB LCD display via UART
uart_advanced Use some other UART features like RX interrupts, hardware control flow, and data formats other than 8n1.

USB Device

TinyUSB Examples

Most of the USB device examples come directly from the TinyUSB device examples directory here. Those that are supported on RP2040 devices are automatically included as part of the pico-examples build as targets named tinyusb_dev_ , e.g. https://github.com/hathach/tinyusb/tree/master/examples/device/hid_composite is built as tinyusb_dev_hid_composite.

At the time of writing, these examples are available:

  • tinyusb_dev_audio_4_channel_mic
  • tinyusb_dev_audio_test
  • tinyusb_dev_board_test
  • tinyusb_dev_cdc_dual_ports
  • tinyusb_dev_cdc_msc
  • tinyusb_dev_dfu
  • tinyusb_dev_dfu_runtime
  • tinyusb_dev_dynamic_configuration
  • tinyusb_dev_hid_composite
  • tinyusb_dev_hid_generic_inout
  • tinyusb_dev_hid_multiple_interface
  • tinyusb_dev_midi_test
  • tinyusb_dev_msc_dual_lun
  • tinyusb_dev_net_lwip_webserver
  • tinyusb_dev_uac2_headset
  • tinyusb_dev_usbtmc
  • tinyusb_dev_video_capture
  • tinyusb_dev_webusb_serial

Whilst these examples ably demonstrate how to use TinyUSB in device mode, their CMakeLists.txt is set up in a way tailored to how TinyUSB builds their examples within their source tree.

For a better example of how to configure CMakeLists.txt for using TinyUSB in device mode with the Raspberry Pi SDK see below:

SDK build example

App Description
dev_hid_composite A copy of the TinyUSB device example with the same name, but with a CMakeLists.txt which demonstrates how to add a dependency on the TinyUSB device libraries with the Raspberry Pi Pico SDK

Low Level example

App Description
dev_lowlevel A USB Bulk loopback implemented with direct access to the USB hardware (no TinyUSB)

USB Host

All the USB host examples come directly from the TinyUSB host examples directory here. Those that are supported on RP2040 devices are automatically included as part of the pico-examples build as targets named tinyusb_host_ , e.g. https://github.com/hathach/tinyusb/tree/master/examples/host/cdc_msc_hid is built as tinyusb_host_cdc_msc_hid.

At the time of writing, there is only one host example available:

  • tinyusb_host_cdc_msc_hid

Watchdog

App Description
hello_watchdog Set the watchdog timer, and let it expire. Detect the reboot, and halt.
Issues
  • Add a SSD1306 I2C example

    Add a SSD1306 I2C example

    This is a 128x64 monochrome display, 0.96" diagonal so very small.

    This example initialises the display, and implements basic pixel, line drawing and text output.

    opened by JamesH65 23
  • Add monochrome e-ink display (SSD1681) example

    Add monochrome e-ink display (SSD1681) example

    This PR adds an example for the 200x200 monochrome e-ink display based on the SSD1681. Demonstrates use of the onboard SRAM and the SD card (possibly).

    Checklist

    • [x] documentation
    • [ ] working example
    • [x] Fritzing schematic and image
    • [x] added to CMakeLists.txt
    • [x] added to repo README
    bug enhancement 
    opened by matiasilva 18
  • Configuration error when follow the guide of MS Visual Studio Code setup.

    Configuration error when follow the guide of MS Visual Studio Code setup.

    When I open the pico-example folder, the configuration process generate following error. How can I get sdk automatically download there?. It seems same for me when using command line instead of vsc, after type nmake

    [main] Configuring folder: pico-examples 
    [driver] Removing c:/Users/yuxiong/Documents/GitHub/pico-examples/build/CMakeCache.txt
    [driver] Removing c:\Users\yuxiong\Documents\GitHub\pico-examples\build\CMakeFiles
    [proc] Executing command: "C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\CommonExtensions\Microsoft\CMake\CMake\bin\cmake.EXE" --no-warn-unused-cli -DCMAKE_EXPORT_COMPILE_COMMANDS:BOOL=TRUE -DCMAKE_BUILD_TYPE:STRING=Debug -Hc:/Users/yuxiong/Documents/GitHub/pico-examples -Bc:/Users/yuxiong/Documents/GitHub/pico-examples/build -G Ninja
    [cmake] Not searching for unused variables given on the command line.
    [cmake] Using PICO_SDK_PATH from environment (' ..\..\pico-sdk')
    [cmake] CMake Error at pico_sdk_import.cmake:54 (message):
    [cmake]   Directory 'C:/Users/yuxiong/Documents/GitHub/pico-examples/build/pico-sdk'
    [cmake]   not found
    [cmake] Call Stack (most recent call first):
    [cmake]   CMakeLists.txt:4 (include)
    [cmake] 
    [cmake] 
    [cmake] -- Configuring incomplete, errors occurred!
    
    
    opened by xiongyu0523 18
  • Problem with bmp280_i2c example

    Problem with bmp280_i2c example

    I'm not sure if it's related to the example code, but the serial output of the bmp280_i2c always shows incorrect values like :

    Pressure = 36479.457 kPa
    Temp. = -15.94 C
    

    The good thing is that the values are not constant, if I put the sensor close to a heating source, the values quickly go up.

    After some debugging, it seems that the calibration data I get from the BMP280 are wrong, here's a dump of the raw bytes I get from inside bmp280_get_calib_params() after i2c_read_blocking :

    00 00 00 00 00 2F 94 00 4C 9D C0 7B F3 00 72 74 90 43 A3 2B BA 00 00 6B

    According to the datasheet, it means dig_T1 and dig_T2 are zero but they state that compensation values are never zero...

    I tried with 2 different BMP280 (3.3V) modules wired as in the example schematic but the result is the same.

    I'm now out of idea :)

    Does anyone have an idea on what could cause this issue?

    Thanks in advance

    question 
    opened by Glitchbone 16
  • Merge intern examples

    Merge intern examples

    I have updated a couple of files per @kilograham requests, but I have not tested any of these changes. They look sane. So from my point of view I think this branch can be merged.

    opened by JamesH65 16
  • Add pio/ir_nec

    Add pio/ir_nec

    As discussed with @lurch and referenced by @aallan this PR adds a PIO example to demonstrate sending and receiving infra-red codes in 'NEC' format: pio/ir_nec.

    There are three sub-directories: the loopback example, and a library each for the transmit and receive functions. As requested I have included a README.adoc and wiring diagram along the lines of gpio/hello_7segment

    I've left my name in the copyright message with the BSD-3Clause licence but I'm OK for you to change that if necessary. Incidentally I have followed the format of the other examples by adding the example_auto_set_url() stuff into CMakeLists.txt but I'm afraid I must admit I don't really know what I'm doing with that.

    opened by mjcross 16
  • Add example for the MCP9808 Temperature sensor

    Add example for the MCP9808 Temperature sensor

    This PR reads and writes to the registers on the MCP9808 board. It sets the upper, lower and critical temperatures and reads the ambient temperature to 4dp by performing appropriate conversions. It checks to see that none of the limits have been surpassed and displays alerts if otherwise.

    enhancement 
    opened by aayushijhaveri 15
  • Add BMP280 I2C example

    Add BMP280 I2C example

    This PR adds a new example for the BMP280 temperature and pressure sensor via I2C. It takes care of reading sensor values and also the necessary conversion for the values to make sense. I'm not sure how much "cleaning up" is needed, for now all code is in one file for simplicity but a few definitions want to be in their own header file. Fritzing diagram and file included, accompanying documentation too.

    enhancement 
    opened by matiasilva 15
  • CMake fails to build examples at the command line on Windows

    CMake fails to build examples at the command line on Windows

    Hi,

    Just a heads up. I found that the pico examples weren't building and I needed to add:

    set(PICO_SDK_PATH $ENV{PICO_SDK_PATH})

    ... to the start of the CMakeLists.txt file. Just before where it says "include(pico_sdk_import.cmake)".

    Without this line, CMake was not using the PICO_SDK_PATH environment variable, as per section 8.2.3 of the Getting Started with Raspberry Pi Pico document.

    Cheers.

    opened by slrAU 14
  • Error building hello_usb on Windows 10

    Error building hello_usb on Windows 10

    I've followed this guide step by step: https://www.element14.com/community/community/raspberry-pi/blog/2021/01/24/working-with-the-raspberry-pi-pico-with-windows

    And everything works in "Developer Command Prompt for VS 2019" until the linking where I also have the "╗┐" in front of the directory path with the object files in. image

    duplicate 
    opened by HrOlsen 9
  • error building blink on windows

    error building blink on windows

    AR10B2~1.EXE: error: ´╗┐CMakeFiles/blink.dir/blink.c.obj: No such file or directory
    NMAKE : fatal error U1077: 'C:\PROGRA~2\GNUARM~1\102021~1.07\bin\AR10B2~1.EXE' : return code '0x1'
    Stop.
    NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC\Tools\MSVC\14.29.30133\bin\HostX86\x86\nmake.exe"' : return code '0x2'
    Stop.
    NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC\Tools\MSVC\14.29.30133\bin\HostX86\x86\nmake.exe"' : return code '0x2'
    Stop.
    

    i get the following error attempting to build the examples. not sure why.

    opened by Lite5h4dow 9
  • Strange characters appear when loading objects from the rsp file for the linker on windows

    Strange characters appear when loading objects from the rsp file for the linker on windows

    The generated link command and it inputs are as follows

    	C:\PROGRA~2\GNUARM~1\102020~1\bin\AR10B2~1.EXE -mcpu=cortex-m0plus -mthumb -O3 -DNDEBUG -Wl,--build-id=none --specs=nosys.specs -Wl,--wrap=sprintf -Wl,--wrap=snprintf -Wl,--wrap=vsnprintf -Wl,--wrap=__clzsi2 -Wl,--wrap=__clzdi2 -Wl,--wrap=__ctzsi2 -Wl,--wrap=__ctzdi2 -Wl,--wrap=__popcountsi2 -Wl,--wrap=__popcountdi2 -Wl,--wrap=__clz -Wl,--wrap=__clzl -Wl,--wrap=__clzll -Wl,--wrap=__aeabi_idiv -Wl,--wrap=__aeabi_idivmod -Wl,--wrap=__aeabi_ldivmod -Wl,--wrap=__aeabi_uidiv -Wl,--wrap=__aeabi_uidivmod -Wl,--wrap=__aeabi_uldivmod -Wl,--wrap=__aeabi_dadd -Wl,--wrap=__aeabi_ddiv -Wl,--wrap=__aeabi_dmul -Wl,--wrap=__aeabi_drsub -Wl,--wrap=__aeabi_dsub -Wl,--wrap=__aeabi_cdcmpeq -Wl,--wrap=__aeabi_cdrcmple -Wl,--wrap=__aeabi_cdcmple -Wl,--wrap=__aeabi_dcmpeq -Wl,--wrap=__aeabi_dcmplt -Wl,--wrap=__aeabi_dcmple -Wl,--wrap=__aeabi_dcmpge -Wl,--wrap=__aeabi_dcmpgt -Wl,--wrap=__aeabi_dcmpun -Wl,--wrap=__aeabi_i2d -Wl,--wrap=__aeabi_l2d -Wl,--wrap=__aeabi_ui2d -Wl,--wrap=__aeabi_ul2d -Wl,--wrap=__aeabi_d2iz -Wl,--wrap=__aeabi_d2lz -Wl,--wrap=__aeabi_d2uiz -Wl,--wrap=__aeabi_d2ulz -Wl,--wrap=__aeabi_d2f -Wl,--wrap=sqrt -Wl,--wrap=cos -Wl,--wrap=sin -Wl,--wrap=tan -Wl,--wrap=atan2 -Wl,--wrap=exp -Wl,--wrap=log -Wl,--wrap=ldexp -Wl,--wrap=copysign -Wl,--wrap=trunc -Wl,--wrap=floor -Wl,--wrap=ceil -Wl,--wrap=round -Wl,--wrap=sincos -Wl,--wrap=asin -Wl,--wrap=acos -Wl,--wrap=atan -Wl,--wrap=sinh -Wl,--wrap=cosh -Wl,--wrap=tanh -Wl,--wrap=asinh -Wl,--wrap=acosh -Wl,--wrap=atanh -Wl,--wrap=exp2 -Wl,--wrap=log2 -Wl,--wrap=exp10 -Wl,--wrap=log10 -Wl,--wrap=pow -Wl,--wrap=powint -Wl,--wrap=hypot -Wl,--wrap=cbrt -Wl,--wrap=fmod -Wl,--wrap=drem -Wl,--wrap=remainder -Wl,--wrap=remquo -Wl,--wrap=expm1 -Wl,--wrap=log1p -Wl,--wrap=fma -Wl,--wrap=__aeabi_lmul -Wl,--wrap=__aeabi_fadd -Wl,--wrap=__aeabi_fdiv -Wl,--wrap=__aeabi_fmul -Wl,--wrap=__aeabi_frsub -Wl,--wrap=__aeabi_fsub -Wl,--wrap=__aeabi_cfcmpeq -Wl,--wrap=__aeabi_cfrcmple -Wl,--wrap=__aeabi_cfcmple -Wl,--wrap=__aeabi_fcmpeq -Wl,--wrap=__aeabi_fcmplt -Wl,--wrap=__aeabi_fcmple -Wl,--wrap=__aeabi_fcmpge -Wl,--wrap=__aeabi_fcmpgt -Wl,--wrap=__aeabi_fcmpun -Wl,--wrap=__aeabi_i2f -Wl,--wrap=__aeabi_l2f -Wl,--wrap=__aeabi_ui2f -Wl,--wrap=__aeabi_ul2f -Wl,--wrap=__aeabi_f2iz -Wl,--wrap=__aeabi_f2lz -Wl,--wrap=__aeabi_f2uiz -Wl,--wrap=__aeabi_f2ulz -Wl,--wrap=__aeabi_f2d -Wl,--wrap=sqrtf -Wl,--wrap=cosf -Wl,--wrap=sinf -Wl,--wrap=tanf -Wl,--wrap=atan2f -Wl,--wrap=expf -Wl,--wrap=logf -Wl,--wrap=ldexpf -Wl,--wrap=copysignf -Wl,--wrap=truncf -Wl,--wrap=floorf -Wl,--wrap=ceilf -Wl,--wrap=roundf -Wl,--wrap=sincosf -Wl,--wrap=asinf -Wl,--wrap=acosf -Wl,--wrap=atanf -Wl,--wrap=sinhf -Wl,--wrap=coshf -Wl,--wrap=tanhf -Wl,--wrap=asinhf -Wl,--wrap=acoshf -Wl,--wrap=atanhf -Wl,--wrap=exp2f -Wl,--wrap=log2f -Wl,--wrap=exp10f -Wl,--wrap=log10f -Wl,--wrap=powf -Wl,--wrap=powintf -Wl,--wrap=hypotf -Wl,--wrap=cbrtf -Wl,--wrap=fmodf -Wl,--wrap=dremf -Wl,--wrap=remainderf -Wl,--wrap=remquof -Wl,--wrap=expm1f -Wl,--wrap=log1pf -Wl,--wrap=fmaf -Wl,--wrap=malloc -Wl,--wrap=calloc -Wl,--wrap=free -Wl,--wrap=memcpy -Wl,--wrap=memset -Wl,--wrap=__aeabi_memcpy -Wl,--wrap=__aeabi_memset -Wl,--wrap=__aeabi_memcpy4 -Wl,--wrap=__aeabi_memset4 -Wl,--wrap=__aeabi_memcpy8 -Wl,--wrap=__aeabi_memset8 -Wl,-Map=blink.elf.map -Wl,--script=F:pico\pico-sdk\src\rp2_common\pico_standard_link\memmap_default.ld -Wl,-z,max-page-size=4096 -Wl,--gc-sections -Wl,--wrap=printf -Wl,--wrap=vprintf -Wl,--wrap=puts -Wl,--wrap=putchar -Wl,--wrap=getchar @CMakeFiles\blink.dir\objects1.rsp -o blink.elf  ..\pico-sdk\src\rp2_common\boot_stage2\bs2_default_padded_checksummed.S
    
    

    produces an error

    AR10B2~1.EXE: error: CMakeFiles/blink.dir/blink.c.obj: No such file or directory
    

    Which is the first path in @CMakeFiles\blink.dir\objects1.rsp.

    Using cmake version 3.22.2

    opened by jfarhanm 5
  • Refactor the oled_i2c example

    Refactor the oled_i2c example

    This PR does a number of things:

    1. Renames the oled_i2c example to sssd1306_i2c to match other example folder names that use the device name
    2. Merge code from another ssd1306 exmaple that was sitting in another PR
    3. Add a few more demo parts to the code for extra fun.
    4. Couple of bug fixes that were reported in original code to fix handling different display sizes, so code now works for 32 and 64 pixel height displays by changing a define at top of code.
    opened by JamesH65 0
  • Example request: show how to use pio_sm_set_clkdiv()

    Example request: show how to use pio_sm_set_clkdiv()

    I am trying to use the pio_sm_set_clkdiv() call in my code and had some questions about it. I had hoped to find an example of its use in the examples, but currently there are none. It might be useful to add it, perhaps as an option to the squarewave example, just to show how it works and how it is intended to be used.

    opened by beroset 5
Owner
Raspberry Pi
Raspberry Pi
Tetris on a Raspberry Pi Pico mounted on a Pimoroni Pico Explorer

PicoTetris Classic Tetris game running on a Raspberry Pi Pico microcontroller. Pico C port by Richard Birkby Original JavaScript implementation - Jake

Richard Birkby 31 May 15, 2022
Breakout game for Raspberry Pi Pico with Pimoroni Pico Display pack

breakout_rpi_pico Breakout game for Raspberry Pi Pico with Pimoroni Pico Display pack Prebuilt binary (breakout.uf2) is here. To build your own binary

null 18 Jan 17, 2022
Pico-uart-bridge - Raspberry Pi Pico UART-USB bridge

Raspberry Pi Pico USB-UART Bridge This program bridges the Raspberry Pi Pico HW UARTs to two independent USB CDC serial devices in order to behave lik

Álvaro Fernández Rojas 104 Jun 21, 2022
Digital rain animation gif with glow squeezed into a raspberry pi pico and pimoroni pico-display

pico-display-matrix Digital rain animation gif with glow squeezed into a raspberry pi pico and pimoroni pico-display or how to actually use all Flash

null 28 Apr 3, 2022
Prueba del Raspberry PI PICO con un display Raspberry PI TFT 3.5"

Raspberry-PI-PICO-display-RPI35 Prueba del Raspberry PI PICO con un display Raspberry PI TFT 3.5" Con ayuda de la libreria https://github.com/khoih-pr

null 1 Nov 10, 2021
Raspberry Pi Pico (RP2040) and Micro-ROS (ROS 2) Integration

The Pico is an amazing microcontroller and I couldn't wait for ROS 2 support or Arduino Core, so here is my approach. Once the Arduino Core for RP2040 is out it will be easier to use micro_ros_arduino.

Darko Lukić 19 Jun 19, 2022
built-in CMSIS-DAP debugger tailored especially for the RP2040 “Raspberry Pi Pico”

RP2040 has two ARM Cortex-M0+ cores, and the second core normally remains dormant. pico-debug runs on one core in a RP2040 and provides a USB CMSIS-DAP interface to debug the other core. No hardware is added; it is as if there were a virtual debug pod built-in.

null 189 Jun 25, 2022
🦠 µnix is a UNIX-like operating system for the raspberry pi pico.

The µnix Operating System "µnix", "munix" or, "micro unix" aims to be a micro kernel based operating system targeting the Raspberry Pi Pico. "µnix" is

Sleepy Monax 57 Jun 19, 2022
Fractal rendering for Raspberry Pi Pico microcontroller

picofract Mandelbrot Set rendering demo for Raspberry Pi Pico microcontroller with Pico Display Pack. Building If you already have the Pimoroni SDK bu

null 20 Apr 29, 2022
Arduino API for the Raspberry Pico

Raspberry PI Pico - Arduino API On Friday I was receiving my Raspberry PI Pico and I had the opportunity to play around with it. Actually most of the

Phil Schatzmann 52 Jun 26, 2022
x86 emulator on Raspberry Pi Pico

picox86 x86 emulator on Raspberry Pi Pico https://user-images.githubusercontent.com/10139098/110543817-13299080-812b-11eb-9c88-674cdae919fc.mp4 PCB fr

null 34 Apr 7, 2022
A laser cut Dreamcast Pop'n Music controller and integrated memory card using the Raspberry Pi Pico's Programmable IO

Dreamcast Pop'n Music Controller Using Raspbery Pi Pico (RP2040) Intro This is a homebrew controller for playing the Pop'n Music games on the Sega Dre

null 31 Jun 6, 2022
Web Server based on the Raspberry Pico using an ESP8266 with AT firmware for WiFi

PicoWebServer This program runs on a Raspberry Pico RP2040 to provide a web server when connected to an Espressif ESP8266. This allows the Pico to be

null 44 Jun 10, 2022
Raspberry Pi Pico Arduino core, for all RP2040 boards

Arduino-Pico Raspberry Pi Pico Arduino core, for all RP2040 boards This is a port of the RP2040 (Raspberry Pi Pico processor) to the Arduino ecosystem

Earle F. Philhower, III 553 Jun 22, 2022
A programming environment for Lua for the Raspberry Pi Pico microcontroller

picolua A programming environment for Lua for the Raspberry Pi Pico microcontroller. Version 0.3, April 2021 What is this? picolua is a proof-of-conce

Kevin Boone 47 May 23, 2022
a little hobby raspberry pi pico emulator

PICO-EMU a little raspberry pi pico emulator note: we use the provided bootrom from raspberry pi at the repo: https://github.com/raspberrypi/pico-boot

supercyp 21 Jun 5, 2022
Raspberry Pi Pico AutoHotkey Streamdeck / Keyboard with LEDs

Raspberry Pi Pico AutoHotkey Streamdeck / Keyboard with LEDs

Build Comics 17 Feb 10, 2022
A FAT filesystem with SPI driver for SD card on Raspberry Pi Pico

no-OS-FatFS-SD-SPI-RPi-Pico Simple library for SD Cards on the Pico At the heart of this library is ChaN's FatFs - Generic FAT Filesystem Module. It a

Carl J Kugler III 88 Jun 21, 2022
Enable LoRaWAN communications on your Raspberry Pi Pico or any RP2040 based board. 📡

pico-lorawan Enable LoRaWAN communications on your Raspberry Pi Pico or any RP2040 based board using a Semtech SX1276 radio module. Based on the Semte

Sandeep Mistry 62 Jun 11, 2022