Close

Back on it

A project log for Vending Machine for Birds

Simple, inexpensive bird feeder that dispenses peanuts in exchange for dropping stuff in a hole. A vending machine for clever birds.

stephen-chaseyStephen Chasey 01/13/2023 at 13:410 Comments

Holidays are over and things are back to normal, so I'm starting to get the feeder ready to remount on the balcony.

After some multimeter diagnostics, my current design will run at 5V, but not reliably. The voltage drop across the BD139 puts the sensor's 555 in questionable territory voltage-wise, and I think it occasionally misses triggers from the deposit sensor due to this. I could replace it with a CMOS 555 and that would probably sort it out. I have a few laying around. The LM538 op amp runs at 3+ volts and the CMOS 555 from 2+ volts. After some PCB surgery and multimetering I found that the voltage with both sensors on and the motor running can go as low as 3.5 volts. Still, this should be ok if I use a TLC or LMC 555.

I tried to make a PNP-based switch for the power-bank keep-alive power rail, but that didn't pan out. The way I put the PCB together makes it difficult to hold the keep-alive 555 in reset while the feeder is on. I would need to do some more PCB surgery to fix this. Then I could just use a BC547 and a 10K resistor to ground that pin when the sensor power rail is on. However, Isince I'm running off mains right now and it looks like I need 6 volts for the time being, so ths will probably have to wait for the next PCB version in a couple of weeks.

I experimented with putting this all on a PIC, and it would be pretty simple. Any uC with 8+ pins and a couple of ADC channels would work. Also looked at some ESP8266 and ESP32 modules with a PIR and camera built-in, which could also handle everything in addition to replacing the RPi I'm using as a remote camera - but they are not that easy to find for me. I tried using pulsed IR to reduce ambient light issues. I experimented with this a bit on the PIC, but for proximity sensing I could not get it to work as well as the current version.

Before I go digital with this I want to make a solid analog design that runs for a week on a 10K mAh 5V power bank, and what I have now is still pretty far from that.

While I work on all these problems and experiments I'm just going to put the current PCB back in the feeder on 6 or 7 volts so can keep working with the birds.

------------------

I finally thought of the obvious solution after writing this. Just control the voltage to the sensors themselves (just the leds and phototransistors), not the 555 and op amp. I'll use a but more power in standby (~50mA over 20mA), but should be much more reliable and let me use a 5V supply with a few modifications to the current pcb.

Discussions