Raspberry Pi Spigot Puts Digits Of Pi On Tap

What did you do for Pi Day? Play with your Raspberry Pi 400? Eat some pizza or other typically round objects and recite all nine digits you’ve got memorized? That’s about where we were at this year. But not [bornach], no. [bornach] went all out and built a spigot that spews digits of Pi well past the first nine decimal places.

This clever spigot sculpture implements the spigot algorithm for generating digits of Pi one-by-one in a stream on to a chain of 8×8 matrices, and does so using a Raspberry Pi (of course). The point of the spigot algorithm is to store as few numbers as possible at any given time by reusing variables. We love the way the digits materialize on the matrix, almost as if they are ink being activated by water. Be sure to check out the build and demo video after the break.

That 10k pot on the top really does control the spigot — since the Pi has no ADC, [bornach] is using the potentiometer to charge a capacitor and using the time it takes to reach the threshold to decide whether the faucet is open or closed. There are a couple of hacks at play here, including the Popsicle-stick LED matrix bracing and the HAT [bornach] fashioned so the daisy-chained 8×8 LED modules could interface with the Pi.

We love Raspberry Pis of all eras around here, especially the darling new Pico. Diminutive as it may be, the Pico can be sliced even smaller with a hacksaw if you don’t mind losing a few GPIO pins.

11 thoughts on “Raspberry Pi Spigot Puts Digits Of Pi On Tap

  1. Cool project. I don’t know the computational requirements of the spigot algorithm or even what it is but wouldn’t a task like this be better suited to a microcontroller such as the raspberry pi Pico which has an adc so you don’t need to do strange things to get an analogue input and can also drive the displays at a fraction of the price of a full sized pi.

      1. @wanderer_ said: “@Conor Stewart not a whole lot of people have actually been able to get the Picos…”

        I got two Picos in the mail yesterday, zero problem getting them, and it looks like anyone can get them, but the limit seems to be two maximum per order. The price is $4 USD each and the US shipping was around $5. I ordered on Friday, the box was delivered the following Monday.

        I went to the Raspberry Pi Pico page on Digi-Key [1], there it said “2 In Stock can ship immediately”, so I bought both of them. After I bought those two Picos I went back to the Digi-Key Raspberry Pi Pico page and it still said “2 In stock can ship immediately”. So I bought two more and went all the way through the checkout process right to the last click, then cancelled. Today I see the page still says “2 In stock can ship immediately” and there’s nothing stopping me from buying more Picos, two at a time max. So it looks like Digi-Key is rationing-out their Picos, but for how long is anyone’s guess.

        * References:

        1. RASPBERRY PI PICO RP2040 BOARD

        https://www.digikey.com/en/products/detail/raspberry-pi/SC0915/13684020

    1. I don’t know I mean he could have just used a switch. He did it the way he did it because he thought it looked pleasing. It looks cool, it’s functional and he built it with what he had on hand.

    2. “… I don’t know the computational requirements of the spigot algorithm or even what it is…”.

      Simply type “the spigot algorithm” into your favorite search engine.

      You will find the definition. The definition is your starting point, the beginning of your algorithm which will form the basis of the program you write, on whatever machine you choose, because the definition will also confirm what this article implies: the computational requirements are as minimal as it gets.

  2. I have displays just like these, they’re MAX7219s if I’m not mistaken. but they are pretty bad for outdoor use. does anyone know of super bright programmable LED matrices that would work with a microcontroller that aren’t also a foot tall?

Leave a Reply to wanderer_Cancel reply

Please be kind and respectful to help make the comments section excellent. (Comment Policy)

This site uses Akismet to reduce spam. Learn how your comment data is processed.