Towards a Bird-Computer Interface!

Bryce

New member
Sep 26, 2017
92
0
Long Island
Parrots
Ruby, Psittacus erithacus, 17 y/o f.
No, this is not about our new cyborg-bird (cybird?) masters. I've been working on some specialized peripheral devices for parrots. My goal here is to build a 'video game' that my gray, Ruby, can play while I'm away from home. She figures out conventional foraging toys really quickly, and I think it's time to go digital.

So far, I've made a treat dispenser and a controller box with buttons.

IMG_20180210_224924.jpg

IMG_20180210_225212.jpg


I'm going to connect these peripherals to a single-board computer, probably a BeagleBone (similar to a Raspberry Pi) and try to implement a simple pong-like game. Ruby will press the buttons with her beak to move the paddle, and get rewards from the dispenser for performance. Of course, I expect to have to train her to do this in gradual steps (beginning with just getting rewards for pressing the buttons.)

When I get these things more refined, I'll post more details about their construction. I've already got quite a few changes to make to the dispenser based on Ruby's feedback. She was frightened of it the first time it dispensed a treat, but after seeing goodies come out of it when it made that noise about twice, she started to respond to the noise by rushing over to the chute in anticipation instead of retreating.

Many of the components of both the button box and the dispenser are 3D printed. The buttons on the button box are arcade machine buttons, which I'm hoping will stand a good chance of surviving The Beak.
 
Wow! This is really inventive! 3D printing amazes me. I am looking forward to seeing more updates!
It's hard to tell from the perspective, but I was wondering if she could reach the cord through the bars?
 
Wow! This is really inventive! 3D printing amazes me. I am looking forward to seeing more updates!
It's hard to tell from the perspective, but I was wondering if she could reach the cord through the bars?

Yes ... I have a low voltage warmer for Gus, and it has an armored cable outside the bars. He doesn't seem to have a lot of beak strength - a bigger macaw might even chew through that. Can always pick up a small piece of romex and use the outside part.
 
Nice! Was also going to mention the cable, can it be pulled back? Another worry for me, is that plastic food safe? Any warnings about making baby toys with it?
 
  • Thread Starter
  • Thread starter
  • #5
The cable is about 5mm beyond her maximal reach, but it does look close. I might revise the button box to have the cable coming out farther away though, since it is a near thing and I'd like it to work with parrots other than just mine specifically. :)

The system is printed in ABS. This specific ABS is not certified as food-grade as far as I know, but the type of plastic is often used in toys. If she had chewed on the chute (or if she decides to in the future), my plan is to reprint it in polycarbonate, which is more durable and also more widely used in food-contact applications. You can also get polypropylene filament for 3D printers now which is explicitly food-grade, but my last experience trying to print with it was not too successful. I don't know how much better it would be now that I have a nicer 3D printer than I used to.
 
  • Thread Starter
  • Thread starter
  • #6
I've been continuing to work on this project, optimizing the amount of 3D printing required and choosing appropriate electronics. I'm hoping to have a beta version done in a week or two.
 
You people with your smart birds! The Rickeybird is stymied by the simplest foraging toys, and is completely enchanted by the same foot-toys for hours.

An amazing invention!
 
Well conceived!

My Amazon takes a brute approach to tech stuff: If it cannot be easily broken, just disassemble it!
 
  • Thread Starter
  • Thread starter
  • #9
Well conceived!

My Amazon takes a brute approach to tech stuff: If it cannot be easily broken, just disassemble it!

That sort of thing is why I'm designing the system to go outside the cage (apart from cage space saving). I also eliminated the chute going into the cage, in favor of a hole in the side of the device that is accessible through the cage bars. This does require some geometric changes (the opening has to be tall enough for macaw beaks and close enough to the bars for budgerigar beaks) but it eliminates an entire printed part (cost, complexity and time savings) and the hygiene problems. (The bird defecating or regurgitating on the chute.)

The casing is printed out of ABS. I think that ABS will not be very rewarding for a parrot to chew, but I do think it is very possible for them to do so if inclined. The new design allows a pretty simple solution - a thin metal or polycarbonate plate with holes for the mounting hardware and food hole would do the trick nicely, I think, for people with chewy birds.
 
Dude ! I want one! Make 2 and sell one to me for Salty. Your here in the Island too!
 
  • Thread Starter
  • Thread starter
  • #11
Sure thing - once I get the design locked down a bit more, I will be ordering the parts for a first batch of "beta test" kits for others to try. I'm shooting for April 30th for the first system here, and the feeder module for integration in your own project (even as simple as just a button) should be ready to ship soon thereafter, but I'm not sure how long the whole parrot video game system will take to develop.

Right now the biggest question is the motor. My first version used a relatively large stepper motor of the type used in most 3D printers. This one works, but it is strong enough to grind up some seeds and pellets if they jam (really you want to clear jams by reversing the motor, not by forcing it through that way), and is much larger than it needs to be, so the case has to be bigger to fit it. The next iteration used a small DC gear motor, but that motor's behavior when a jam occurs wasn't good - instead of stopping like the stepper, the motor kept going and ground the plastic gears in the gearbox. The current iteration uses a smaller stepper motor. When I've confirmed that the smaller stepper motor is suitable, I'll place a "bulk" (well, for twenty or so, depending on demand here and locally) order of them, and it will take a month or so to be delivered. (During which time I can also print out all the parts, get the PCBs partially assembled, etc.)

Thanks for your interest. I'd love to be able to bring some kind of entertainment to birds that might otherwise be bored.
 
  • Thread Starter
  • Thread starter
  • #12
So, since several people now have expressed interesting in having one of these, I thought I'd put together more of a specification for comments and suggestions.

To start with, this is only pertaining to the seed dispenser. At a minimum, I also intend to produce a bird-friendly button box / controller to share. I don't know if I'll be offering the complete "bird video game" I come up with; probably, but I haven't got a prototype of that finished yet and I don't want to get too far ahead of myself there.

So, the treat dispenser will be something that you can combine with a device of your choosing to make a complete parrot game. This could be as simple as a button (though I suspect Polly will figure that out relatively quickly), up to something like an Arduino that lights up certain colored lights to let the bird know _which_ button to press, or even a sophisticated computer-based (Raspberry Pi, Beaglebone, even desktop computer) system that implements a full bird video game. That's my personal goal, but the treat dispenser would only be part of that.

That out of the way, my current design for the treat dispenser would have these features:

1. Support for most small parrot food pellets, sunflower seeds, pistachios without shell, almond or walnut fragments, and other small food items of that sort.

2. A capacity of 50-60mL of food, with an optional funnel accessory that could hold more if several days supply is desired.

3. Reliability features, including detection of dispensed food, to ensure that the bird is rewarded when intended, and automatic clearance of jams.

4. Powered by an external power supply, < 500mA when dispensing food, < 10mA when inactive. 5V-28VDC input. (I am currently powering the prototype from rechargeable batteries.)

5. Compact case design so that multiple units can be placed next to each other in case you want to offer multiple types of rewards. (Have a pellet as a consolation prize, Birdie...)

6. Compatibility with all common domestic psittacines from budgies to macaws.

7. Optional chewing guard accessory.

8. Optional alternate dispensing/metering rotor for small seeds like millet which would otherwise be dispensed in ludicrous quantities by the standard metering rotor.

9. Four possible interfaces, possibly selectable at home (not sure yet):
a. USB (also provides power)
b. RS-485 serial (suitable for integration into a more complex system or transmission over long distances, suitable for e.g. research use or outdoor use for projects involving feeding wild birds)
c. TTL-level serial, 9600 baud (suitable for Arduino and other small systems located nearby)
d. Simple electrical interface (for direct connection any ordinary switch).

10. Cost in kit form, requiring soldering, less than $60; cost in kit form, no soldering required, less than $90, cost as a completed subassembly ready for integration into a larger project, less than $130. Possibly also version of the kit without the 3D printed parts for even less, for people with 3D printers.

11. Schematics and solid model files freely available for users wishing to modify or repair it. (Or build their own from scratch.)

12. Externally mounted, compatibility as many cage bars arrangements as possible.

13. Free of zinc or heavy metals.

Further suggestions or modifications welcome.
I'd be especially interested in hearing what kind of interfaces you want, if you're planning on making this part of your own project. I know not everyone is as keen on micro-controllers as I am, so I want to offer a viable interfacing option besides serial/USB.
 
Do you know a research team made a TV control for a grey to choose between different video programs, like one with flocks of greys, one with forest scnery, etc etc. But no reward like you are planning, I just mention it for ideas
 
  • Thread Starter
  • Thread starter
  • #14
Do you know a research team made a TV control for a grey to choose between different video programs, like one with flocks of greys, one with forest scnery, etc etc. But no reward like you are planning, I just mention it for ideas

It is a neat idea. I thought about making some kind of youtube interface, but I'm afraid she'd find her way to one of those parrots cussing compilations and make mixing with polite company more difficult in the future :D
 
  • Thread Starter
  • Thread starter
  • #15
Status update: I've got the firmware of the food dispenser about half done. (About 550 bytes of 8051 machine code, for the curious.)

The mechanical design of the beta version model is finalized except for some tweaks to the printed parts and the fabrication of a "macaw adapter" for large-beaked birds.

The electronic design is about 80% done. I am working on designing a printed circuit board (the current prototype of the electronics is too big to fit in the case.)


IMG_20180304_004640.png
 
  • Thread Starter
  • Thread starter
  • #17
I've completed the prototype electronics and the firmware. (1105 lines of 8051 assembly language. Yes, I know newer MCUs, but these are appropriate technology.)

I'll be making a circuit board that integrates everything here (except the battery) onto a single board that fits in the feeder, and all those wires coming out the back will be replaced with a power/serial connector.

It works pretty reliably, dispensing 1-3 seeds at a time. (Usually 1-2.)


proto_electronics.jpg
 
Cool! What did you use to dispense the treats? Just curious, because I'm also an electronics enthusiast.

Have you considered using Arduino instead of using assembly directly? I'd imagine that would be time consuming.
 
  • Thread Starter
  • Thread starter
  • #19
Cool! What did you use to dispense the treats? Just curious, because I'm also an electronics enthusiast.

To dispense the treats, I'm using a 3D-printed apparatus I designed. It's the black object above the circuit boards in the photo. The device uses a short-body NEMA 17 stepper motor to turn a 3D-printed rotor. Above the rotor is a compartment in which the treats are stored. Below (the curved part) is an integrated chute and an opening through which the bird can retrieve the treats. The turning rotor meters the treats into the chute. An IRED and photodiode detect the passage of a treat as it falls out of the rotor into the chute. In this way, it's a closed loop system, which is important because the treats are often a natural product (e.g. seed or nut) with variations in size, the possibility of jamming, etc. That's about all there is to it fundamentally.

Have you considered using Arduino instead of using assembly directly? I'd imagine that would be time consuming.

I often use Arduinos for one-off projects (sometimes programming them with the Arduino IDE, others with Eclipse AVR), but I'm planning in making these in at least tens and hopefully 100s quantity. Arduinos cost over twenty dollars apiece and include many features which are not necessary for this application. The AT89C2051 microcontroller I'm using costs less than fifty cents. It requires some passive components as well, a clock crystal, etc, but the total comes out to around a dollar exclusive of the circuit board. But the circuit board is needed anyway for the other features - stepper motor driver, DC-DC converter, and a serial or USB chip. You can certainly get Arduino shields or peripherals for each of those things, but the final product would end up as gnarly-looking as the electronics prototype above, with little dupont wires snaking around all over the place. The case would have to be larger to accommodate that, and that ends up being the biggest factor affecting the cost, since the case is 3D printed. The longer the case takes to print, the fewer of these I can make. Stepping up to injection moulding is tremendously expensive.

So, the best choice here is to use a custom controller rather than an Arduino. If I'd made an Arduino-based prototype, though, it might have been a good idea to use an ATMEGA MCU instead of the cheaper AT89C2051. Although the ATMEGA would have capabilities that the project does not need and would cost more, they are not that expensive, and it would have saved a lot of development time, since the Arduino software could be flashed onto it directly (using an ISP header, as when flashing a new bootloader to an Arduino.)

pcb-rev.png
 
  • Thread Starter
  • Thread starter
  • #20
Here is a view of the internal mechanisms of the feeder in my CAD program.

seedfeeder_cad.png
 

Most Reactions

Latest posts

Back
Top