Code Monkey home page Code Monkey logo

blinkenbox's Introduction

Blinkenbox

Some fancy drivers and demos for an IKEA Frekvens LED box, powered by a Raspberry Pi Pico-W

What's so great about this?!

The LED matrix of FREKVENS is based on single-bit shift registers. That means you shift a serial bit stream of 256 pixel states into it and then LATCH to show the values in the LED array.

That hardware doesn't support dimming of individual pixels.

This repo implements Binary Code Modulation, as described by SpritesMods here and Batsocks here.

The actual driving of the display is done entirely without CPU intervention. There are no timers, interrupts or bit-banging involved. In fact, Blinkenbox doesn't even use any of the transceivers on the RP2040 chip!

As a joke, a punishment and a cool trick, the LED driver is implemented entirely in Programmable I/O (see matrix.py) and driven by multiple autonomous DMA channels (see fb.py). Using these methods, the pico-w is able to display about 2000 raw single-bit images per second. When BCM is added to perform brightness modulation over 32 frames, the system can draw about 62FPS with a 5-bit grayscale depth. This comes at no cost in terms of CPU utilization, since all data shuffling is performed by DMA controllers and Programmable I/O.

Pinout

GP0: LATCH (gray)
GP1: CLK (yellow)
GP2: DATA (blue)
GP3: ENABLE (green)
GP13: Button COM (red)
GP14: Button 1 (white)
GP15: Button 2 (Black)

Cable colors on motherboard Cable colors on Raspi Pico Cable colors on Raspi Pico

Interference

Separate the red VSYS cable from the signal wires!! Otherwise you'll likely get strange artefacts when the USB is connected

Don't mix signals and power

blinkenbox's People

Contributors

eldstal avatar segelbaot avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.