June 23, 2015

Internet Dog Treat Dispenser (v3)

Internet Dog Treat Dispenser (v3)

Once upon a time, a few dog people (people who love dogs, not dog+people hybrids) made a remote controlled dog treat dispenser. You know, because that's what dog people do at hackathons. Things like this:

It dispenses treats with a text message. The Arduino is connected to the computer, which listens for the text.

Version 2 was a little tidier. We made it using a Raspberry Pi instead of a computer, which meant it didn't have to be tethered to a computer. It plugs right into a an USB wall output or battery pack.

Now, V2 was nice and dandy, but it was still messy. I mean, look at all those wires. So I decided to fix that. By making a custom PCB (printed circuit board). I mean, how hard can it be?

It turns out: not that hard! Nowadays, with better software, the internet to connect you with manufacturers, it's getting easier and easier.

V3: Internet Dog Treat Dispenser

For the electronics, I used Fritzing, which is an open source, free schematics and PCB designer. I like it because you start with a visual representation of the breadboard, Raspberry PI, and whatever components. You drag and drop the exact components you need and wire it up exactly how you'd wire it up in real life. From there, the virtual wiring turns into schematics and PCB layout.

Step 1: Real World

Step 2: Virtual Bread Board

Step 3: PCB!

Routing the PCB was kind of fun, like solving a puzzle.

Fritzing exports to Gerber files, which most PCB manufacturers take. I spent a little while Googling around for cheap PCB prototypers (low volume, relatively quick turnaround). I ended up using ITEAD in Shenzhen. For a PCB of this size (1.5x1.75 inches), they will produce 10 QTY for $10. Not a bad deal.

For a more detailed write up of how I made Custom PCBs, check out this blog post. The Fritzing and Gerber files are available on this project's GitHub Page.

There were a few places that had cheap PCBs, most of them are based in China. The kicker is the shipping. The main reason I went with ITEAD was because they offered the "cheapest" expedited shipping options--$18 for DHL Express 3 Days.

Fast forward a week (it took them 6 business days from order to delivery!), I got a fresh pack of custom PCBs from China!!

A few headers here, a few crappy soldering there...

BAM! ELECTRONICS!

One end has a 13x2 pin Raspberry Pi header. There's also 6 positive headers sticking out for the stepper motor. So, plug it into a Raspberry Pi, which is sitting in a cushy 3D printed box. Then plug the stepper motor into the PCB..

Add some more 3D printed parts (all designed in Blender by the way)

Woo!!! Remote control dog (or human) treat dispenser!!!

One USB connects to a webcam, and a micro USB connects to power. Best of all? No messy wires, no scotch tape.

It comes with a nifty web interface, so you can see and hear a live stream of your nice or naughty pet. Give treats according.

Then put the lid on, and you're ready to rumble.


Want more details? I'll give you more details.

  • Detailed write up on the Electronics part
  • Coming soon: Detailed write up on 3D printing the case
  • Coming soon: Detailed write up on the software piece (I used Python, Node.js, Regular ol' front end JavaScript)