transcribe

I built a bitcoin lottery machine

Rootkid · 9m · transcribed May 2026
More from Rootkid Business
𝕏 Share ▶ YouTube 📥 PDF 🤖 .md

Transcript

0:00 For most of human history, value came from something tangible. Gold in the ground, labor in the field, objects you could hold. But today, trillions of dollars circulate through something stranger. Numbers competing with other numbers inside machines. Every 10 minutes, somewhere on Earth, a number is discovered. That number is worth hundreds of thousands of dollars. What if the next one was yours? This is my piece, a blind consensus. And here is how I built it. The first step was to acquire hardware capable of calculating numbers extremely fast. To understand why we need that, here is a bit of background. On October 31, 2008, a PDF appeared online from an anonymous source. It described a novel way to store and send money securely between people without relying on central authorities like banks or government.

0:46 The same freedom and privacy you get with cash, but in the digital world. This system was appropriately named Bitcoin. I'm not going to tunnel you about how Bitcoin works exactly, but you can think of it as a big shared ledger of all transactions ever made. Everyone has a copy and anyone can read it. To pay someone, just add the transaction, sign it, and broadcast the change to the network. Now, since there is no trusted authority, how do you prevent people from creating false or duplicate transactions? This problem, known as the double spending problem, remained unsolved for decades. Bitcoin's breakthrough was a solution called proof of work. The idea is simple. To add new transactions to the ledger, you have to perform a costly computation. Real work done by real computers. Each update is called a block. And since they contain informations about the previous block, they effectively form a chain. Hence the name a blockchain. Whenever there are competing version of the ledger, the network always trusts the longest chain.

1:40 Why does this work? Because to forge a fraudulent version of the ledger, an attacker would need to produce more computation than all the rest of the network combined. In practice, that would require them controlling more than half of the world's computing power, which is effectively impossible. So, what is this work exactly? Since it has no purpose other than being extremely computationally demanding, it's pretty much a number guessing game. To validate an update to the ledger, you create a new block containing the address of the previous one, the transactions to include, and a special number called a nons. You then pass that block's data into a special mathematical function that reduces it into a fixed size, seemingly random number. For the result to be valid, that number has to fall below a specific threshold called the network target. Given the scale of these numbers, the chances of that happening are astronomically low. So you increase the nons by one and try again millions, billions, trillions of time until you find a valid combination. This result can then be verified by others and prove that this new version of the ledger results from work and thus can be trusted. And here's the thing. To reward you for the work you've done validating transactions securely, the Bitcoin network rewards you with brand new bitcoins. This process is called Bitcoin mining, and the current reward is set at more than three bitcoins, which at current market value is worth around $240,000.

2:55 Anyways, back to the build. After looking online, I found a supply of used ASIC hardware. These are industrial scale devices designed specifically to be extremely fast at this exact mathematical operation. Each one of them is capable of 14 trillion operations per second. With those in hand, I started designing the rest of the machine around them. My idea was to have them stacked like they would in a data center and have all the rest of the electronics mounted on the side. This would include a computer to control everything and a screen to display the process. Once I was happy with the design, I modeled the frame in 3D, exported the plans, and started building. At first, I used stainless steel, but quickly realized the frame would be way too heavy, so I switched to aluminum. I cut all the pieces to size and assembled them using a technique called brazing, which uses a high temperature torch and a filler alloy that melts, bonding the pieces together. Once the frame was complete, I sanded it smooth and moved on to the rest of the hardware. For the computer, I picked up an old professional workstation, disassembled it and mounted the motherboard and the power supply directly onto the frame. Next up was the display. I wanted a display that was low profile and not too large to fit nicely on the frame. I couldn't find existing panels with the right dimensions. So I ended up buying a used laptop computer, disassembled it completely and extracted the screen panel from it. Because these raw panels cannot be used directly, I got a controller board to drive it via display port. To install all that, I designed and 3D printed supports, screwed them onto the frame, and mounted the display in place.

4:21 After that, I installed the two power supply for the A6 at the back of the chassis. They are rated at 1,800 watts each, which should give you an idea of the power of these things. Next was networking. Because the A6 communicate over Ethernet, I picked up an old router and configured it to act as a local network. As with the rest, the router was disassembled and mounted onto the frame. Finally, I installed the two A6 and connected everything together carefully.

4:47 With the hardware done, I was ready to move on to the software. The goal of the software is pretty straightforward to interface between the hardware and the Bitcoin network, display what's happening and send the reward to whoever is looking at the machine. The first step was to install Bitcoin Core, the official implementation of the Bitcoin protocol that allows computer to become a node in the network and start validating transactions. To ensure my version of the ledger is the correct one, the software start from the first ever transaction and validate the almost 1 million version of the ledgers to date. This process took around three full days and with more than 1.5 billion transaction weigh more than 600 GB.

5:22 Anyways, next I installed software that makes the bridge between the Bitcoin node and the mining hardware. At this point, the system could already start mining Bitcoin. But I couldn't stop there. I wanted to be able to display the exact numbers involved in real time. This turned out to be much harder than expected. At first, I thought I could just have each A6 and all the guesses they're making in real time and display the lowest so far. Then I realized that sending 28 trillion number every second would require more than 7,000 terabytes of bandwidth which is more than four times the global internet traffic. So I started looking at how it works internally and this is where things started to get complicated. This data transits between programs encoded using an obscure protocol whose specification only is 50 pages long. So instead of spending days combing through the docs and coding, I handed the task over to cursor. Cursor is a tool that allows you to utilize AI agents to build software.

6:14 Basically, I described exactly what I needed, pasted the complete protocol specs, and it got started researching and writing code. A few minutes later, it produced a fully functional program that basically sits in the middle and decodes all the informations I need, saving me days of work. The cool thing is that since the agent has context of the code, you can submit follow-up instructions, for example, to create a graphical interface for it, which it did in seconds. I've been using Cursor for work pretty much since it came out. It's a tool I'd honestly recommend to anyone.

6:44 So, we got in touch and they agreed to sponsor this video. Anyways, with all those informations now available, I started working on the visual interface. I wanted it to feel cold and numerical. So, I took inspiration from industrial system interfaces and ended up with this. It shows the status of the system, but most importantly, it shows two numbers, the current network target and the lowest number we've found so far. If our number ever drops below the target, we've solved it and earned the reward.

7:11 So, what are the odds of that happening exactly? Short answer, very unlikely. But we can actually calculate it. Our odds depend on the total computing power of all people trying to solve the same problem, which amount to 550 quadrillion guesses per second compared to our 28 trillion guesses per second. With that, we can calculate our probability to around 1 in 200,000 every day or an average time of 580 years to find the solution. The interesting thing though is that statistically there are equal chances that it happens in the next minute than in a 100 years. And it does happen even for people with way less computing power. I also compared these odds to winning the parable lottery.

7:47 Turns out standing in front of this machine is roughly equivalent to buying one parable ticket every minute. Finally, I added my signature and the piece was complete. Upon starting, it generates a new Bitcoin wallet. Think of it as an anonymous account where whoever knows the passphrase can access the funds. The machine then connects to the network, get the latest ledger and begins guessing at full power. If the number on the right ever drops below the one on the left, it has successfully mined bitcoin. At that moment, the bitcoins are sent to the wallet and its secret passphrase appear on screen for 30 seconds, allowing anyone to claim it.

8:24 After that, the key to the wallet is deleted from memory, locking access to those phones forever, and the whole process starts again. Standing in front of this machine, hearing the roaring of the fan and feeling the heat radiating off the hot metal, the absurdity is hard to ignore. We're burning energy to produce meaningless numbers that can be erased in a split second. And yet here you are watching, waiting for that number to drop. These numbers don't have value because they inherently do, but because enough of us agree that they do.

8:51 And by standing here, you're agreeing too. This machine doesn't create value. It just reveals what it always was, applying consensus.

Summary

The video discusses the evolution of value from tangible assets to digital currencies, focusing on Bitcoin and the process of mining. It details the construction of a custom Bitcoin mining machine, explaining the hardware and software involved, as well as the underlying principles of blockchain technology and proof of work.

- Value has shifted from tangible assets to digital currencies like Bitcoin, which operates on a decentralized ledger.
- Bitcoin mining involves solving complex mathematical problems to validate transactions and create new bitcoins.
- The mining process uses specialized hardware (ASICs) capable of trillions of operations per second.
- The Bitcoin network relies on proof of work to prevent double spending, requiring significant computational power to forge fraudulent transactions.
- The creator built a custom mining machine, utilizing recycled components and advanced software to interface with the Bitcoin network.
- The odds of successfully mining a Bitcoin block are extremely low, estimated at 1 in 200,000 per day.
- The machine generates a new Bitcoin wallet for each mining attempt, with the passphrase displayed briefly for potential claimants.
- The process highlights the paradox of creating value through energy consumption and consensus in the digital realm.
© transcribe · For agents Built with care and craft by Gokul Rajaram