My driveway is short so if I don't get close to the gate with my car then my butt hangs on the sidewalk and I get a ticket. So I saw a few items on adafruit for sensing distance and said what the hell, let's make something "simple" that'll have a "red", "yellow", "green" light scheme telling me how close I am to the gate. Then I'll power it all by a small solar panel and be done with it.
I was also tired of software from my last project and didn't want to deal with programming anything so I challenged myself to diagram out how I'd make it without a microcontroller. The proximity sensor pulls like 30mA at 5V so I can't leave it on all the time or else the battery will drain over night. I figure I'd use a 555 timer to wake up ever second and assess if something is within view of the sensor. If not, go to sleep for another second, if there is something then start a different 555 timer to turn on the LEDs and show the distance front the gate to my car for like 20 seconds. Then it'll have to latch into a state where it doesn't come back on and say "hey I can see something!" but rather stays off until the car has left the view and come back. It was really fun to go back to flip flops and logic gates to get this done. Was proud of myself for designing everything over 1 weekend on paper then took another weekend to tune in SPICE.
I was also tired of software from my last project and didn't want to deal with programming anything so I challenged myself to diagram out how I'd make it without a microcontroller. The proximity sensor pulls like 30mA at 5V so I can't leave it on all the time or else the battery will drain over night. I figure I'd use a 555 timer to wake up ever second and assess if something is within view of the sensor. If not, go to sleep for another second, if there is something then start a different 555 timer to turn on the LEDs and show the distance front the gate to my car for like 20 seconds. Then it'll have to latch into a state where it doesn't come back on and say "hey I can see something!" but rather stays off until the car has left the view and come back. It was really fun to go back to flip flops and logic gates to get this done. Was proud of myself for designing everything over 1 weekend on paper then took another weekend to tune in SPICE.
The LTSPICE simulation file is below. Feel free to take it and play around.
|