A Closer Look at Raspberry Pi RP2040 Programmable iOS (PIO)

This page summarizes the projects mentioned and recommended in the original post on news.ycombinator.com

Our great sponsors
  • WorkOS - The modern identity platform for B2B SaaS
  • InfluxDB - Power Real-Time Data Analytics at Scale
  • SaaSHub - Software Alternatives and Reviews
  • picodvi

    Discontinued [Moved to: https://github.com/Wren6991/PicoDVI]

  • > HDMI is a 10Gbps port.

    > The PIO ports discussed here are on the order of 100kHz

    PIO runs at the system clock, 125 MHz by default, overclocks of over 400 MHz have been reported stable. A single PIO can clock out 32 bits every cycle (with a DMA and a memory system that can feed this), giving you a total of 4 Gbps.

    Running at full throttle like that, especially for a decent length of time is tricky if you want to actually do anything other than blast out bits but 16 or 8 bits per cycle is a lot more straight forward, so 2 or 1 Gbps.

    DVI output has already been demonstrated, running two displays at 480p: https://github.com/Wren6991/picodvi

    The DVI is maybe more of a party trick than something you'd do in production hardware but it does demonstrate how capable the PIO can be. You could happily implement the same concept in a more performant device and reach 10 Gbps or more in a reasonable way.

  • pico-extras

  • I've just been getting to grips with the PIO, they are a lot of fun to program. Whilst the instruction set is very limited with only enough memory for 32 of them you can do some pretty sophisticated things. A key part of the flexibility is the ability to execute incoming data as instructions. You can stream in a mixture of data and instructions via the DMA, the PIO separates the two and uses the instructions to modify execution so a simple loop becomes a lot more flexible. You can easily sync several of them up to. The scanvideo library: https://github.com/raspberrypi/pico-extras/blob/master/src/c... which is for producing video signals (like VGA) on the fly with scanlines supplied by the CPU is a good example of what's possible. You can have multiple scanline PIO running at once, each decoding a compressed RLE format including transparency and it composes them all together on the fly.

    If you've ever played one of the Zachtronics games (in particular Shenzhen IO) it feels like the programming in one of those games. Tight constraints but major possibilities when you think about it for a while.

  • WorkOS

    The modern identity platform for B2B SaaS. The APIs are flexible and easy-to-use, supporting authentication, user identity, and complex enterprise features like SSO and SCIM provisioning.

    WorkOS logo
  • esp-idf

    Espressif IoT Development Framework. Official development framework for Espressif SoCs.

  • Quadrature decoding is extremely common in microcontrollers, though the peripheral may not be called a quadrature decoder. Normally they just make the counter peripheral flexible enough to do it.

    Example for the ESP32: https://github.com/espressif/esp-idf/tree/73db142/examples/p...

    I would not be surprised if you don't need PIO for this on this chip.

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts