A Coca-Cola machine accepting Bitcoin via the Lightning Network.
The project is for study purposes. The objective is to demonstrate the sales automation process using Bitcoin and the Lightning Network.
- Raspberry Pi 3 Model B;
- Display 7″ Official Touch Screen Para Raspberry Pi;
- Water pump RS 385;
- Bridge H L298N;
Software and Web Solutions:
- Linux Raspbian in Raspberry Pi;
- Apache Server + PHP in Raspberry Pi;
- Wiring Pi (interface GPIO);
- BTCPAY (checkout solution);
- PUSHER (websocket solution);
In Raspberry Pi, I created a local web server (localhost) and in the root I put the files:
In BTCPAY I create the invoice (payment button), so it generates a Lightning Network qr code for payment. I also set up a return url (notification.php), which is the destination BTCPAY will inform when a purchase order has any changes, such as payment receipt.
In the notification.php file is just the PUSHER code. It is the PUSHER that warns Raspberry that BTCPAY has received a payment.
Read More Information…..