MEO Wallet was one of themes of this year's Codebits. We gave participants a sneak preview at the project and at our sandbox enviroment. Lots of great projects and ideas came out of it and MEO Wallet was battle tested on a number of new scenarios with a crowd that doesn't believe in "if it isn't broken don't fix it".
But we like to have some fun at Codebits too and in the time honoured spirit of dogfooding we decided to do something in the spirit of the event and hack together a vending machine on short notice using our public ProCheckout API and a lot of help from our partners at MicroIO. MicroIO are experts in automation and they gave us some boards that control vending machines exposing a simple command interface through a good old serial port. So now that we can convince the vending machine it has credit we need to interface with the user and MEO Wallet. Because it's Codebits the obivous path was raspberryPIs with 2.8" screens runnig node.js. Implementing create checkout and receiving callbacks was a few lines of HTTP server and client code. The interface card was connected through the serial port on the rPI GPIO interface and once we found a working serial port library sending commands worked on the first go.
Adafruit's 2.8" TFT screen shield for the RaspberryPi
The screen was another matter. We only had to display the checkout QRcode on the screen but getting node.js to display anything on the "builtin" screen is challenge. Luckily we have special access to the author of node-openvg-canvas and through some framebuffer copying magic we got the QRcode to show up on screen complete with W animation. So tying it all together, the node daemon created a checkout, displayed the MEO Wallet QRcode on screen, waited for the callback indicating payment and credit the payed ammount on the vending machine. If the vending machine gave us an error we would even refund the payment.
3D printed case, fitted in the vending machine
After everything was tested it was time to put everything together inside the machines. Lets just say a lot of duct tape, hot glue and 3d printing was involved.
Everything connected with loose wires and duct tape, inside the machine