Raspberry Pi Bitcoin Lottery

Long ago I was really into bitcoin mining. It was a fun project that actually generated a little income at the time. This was way back when GPU mining was still a thing. I stopped playing around with Bitcoin a few years ago and sold all of my equipment(except for a few block eruptors). I also sold all of my bitcoins when it was around $700 and just called it quits, I had no time to be playing around. Now that it is up to $4000(!), I thought it would be fun to make a little bitcoin lottery device. The basic idea is that you solo mine with a raspberry pi and a block eruptor, and hope you mine your own block. It uses so little power, and my Pi is running anyway. If you happen to mine a block you will get 12.5 bitcoins, in USD that is around $50,000. Yeah, really. However, it is extremely unlikely that you will mine a block, but it is still possible, and probably close to the same odds as the real lottery, but much cheaper(cost of electricity for the Pi).

Step by step to setup your own after the jump!

Alot of the info came from the following webpage and I added my own modifications.

https://www.raspberrypi.org/forums/viewtopic.php?t=49274

sudo apt-get update

sudo apt-get install libusb-1.0-0-dev libusb-1.0-0 libcurl4-openssl-dev libncurses5-dev libudev-dev

wget http://ck.kolivas.org/apps/cgminer/cgminer-4.10.0.tar.bz2

tar xvf cgminer-4.10.0.tar.bz2

cd cgminer-4.10.0

./configure –enable-icarus

sudo make install

sudo apt-get install screen

screen -S miner

cd cgminer-4.10.0

sudo cgminer

Get the python code for the pi here:

https://github.com/IdleHandsProject/BTCLotto

 

You will need to understand how cgminer works, there is plenty of documentation online. For solo mining I’m using a pool called NiceHash. https://solo.nicehash.com/ – a pool allows you to avoid having to download the entire blockchain!

The remaining assembly please refer to my instructables(link). Its much cleaner.

To get the Neopixels to work, I had to permanently disable the sound output on the Pi by doing the following: http://www.instructables.com/id/Disable-the-Built-in-Sound-Card-of-Raspberry-Pi/

Enjoy your own personal lottery machine!

 

FacebookTwitterGoogle+Share

Leave a Reply