Introduction: A Steam Punk Style Lottery Machine

About: Howdy, we are application engineers in Seeed. Sharing projects with the maker community is awesome. Hope you like it XD Seeed is the IoT hardware enabler providing services that empower IoT developers to swift…

Here share my latest project, a very cool stream punk style drawing machine.

Please take a look at the video to get how does it work.

And if you want to make one, please follow the below few steps.

Step 1: A Video

Here is a small video to help you to get more about this machine.

Step 2: What Do We Need

Open source hardware modules:

Hercules Dual 15A 6-20V Motor Controller is a high current motor drive control board. including micro controller processor, motor drive circuit, charging circuit and protection circuit. It features a complete solution to power supply, control and drive.

This is an embedded thermal printer, which is widely used in various occasions, such as supermarkets, convenience stores, post office, bank and so on. It is not a normal consumer product, but similar to consumer products. The compact size makes it easy to be embedded to any kinds of instruments and meters. With a nice appearance, you can even put it on the table. On the hardware side, we specially choose the TTL interface so that it can be directly controlled by development boards such as Arduino or Raspberry Pi. In the Internet of things era, it’s time to print out your ideas!

The others:

  • 5mm wooden board
  • Some gears
  • Some screws and nuts

Step 3: Laser Cut the Box

Download the file attached and put it into a laser cut machine.

Then you will get 6 piece of wooden board. We will use them to make a box.

Step 4: Hardware Connection

You may need to do some soldering here.

The hardware connection as below:

  • Button connect to A1 and GND
  • Printer connect to I2C port, and we know that the printer is a uart device, don't worry about it, we just use A4/A5 as the software serial bus.
  • WS2812B connect to D12
  • Motor connect to M1, on Hercules board
  • Battery connect the board via a switch

Step 5: Software Works

Download the code here.

1. When you get to the github page, find a Download ZIP button, click to download the code.

2. The code you downloaded is not an Arduino library, it's a sketchbook, which is include all the library the project need.

3. Unzip the file you had downloaded from github, you will get a folder named LotteryMachine-master.

4. Open your Arduino IDE, click File > Preferences > Sketchbook Location, browse to the folder we had mentioned above - LotteryMachine-master. Then click OK to save it.

5. Close and re-open Arduino IDE, click File > Sketchbook > Lottery, then the main code of this project is opened.

6. Choose the right board(Arduino UNO) and port to upload the code. Refer to the image above.

Note: As there's no usb2uart ic on Hercules, so a Uartsbee is needed.

Step 6: Test Function

After hardware and software works is done, open the switch and press the button.

See if all the function is ok.

1. WS 2812B Led green when there's no operation.

2. When press the button, WS2812B will turn to Blue, and the motor move

3. Printer will shift out a paper when release the button, WS2812B turn to green when the printer finish its job.

Step 7: Fix the Gears and Modules

You need a glue gun here to connect things together. There're few steps to be follow.

1. Fix the button on the top of the box

2. Fix the gears, hmm, maybe this step is hard for you

3. Fix the printer in the front

4. Fix the switch in the back

5. Fix the motor, you need to make some holder

6. Fix the other modules

Please refer to the attached image for more information.

Full Spectrum Laser Contest 2016

Participated in the
Full Spectrum Laser Contest 2016