![]() |
![]() OCAU News - Wiki - QuickLinks - Pix - Sponsors |
|
|||||||
| Notices |
|
Sign up for a free OCAU account and this ad will go away! Search our forums with Google: |
![]() |
|
|
Thread Tools |
|
|
#1 |
|
Member
Join Date: Aug 2012
Location: Perth, WA
Posts: 5
|
Hi All, im not new on this forum but new to this section and under this username. Years ago I used to have ~aconnoll username but have forgotten the password and dont use that work email address anymore. Myself and my friend Craig were known here for supercharging a Camira a few years ago.
Anyway, fast forward to now and I have a problem im trying to solve that id like a little help with. Im far from an electronics expert but understand the basics. I would like help with the below image. As can be seen I have a 12v source powering some sensors that output 3.3v high when motion is detected. Now I want these sensors to be able to turn on a 12v solenoid (poly retic valve), essentially to scare my dogs away from the fence when they get to close to it (as they have been digging human sized holes into the neighbours to try and eat the poodle next door). The problem im having is that im only getting about 1.8v out of each sensor in the way ive got it wired up like above. Meaning that they have to move past both sensors to set off the transistor and get the water squirting. Can someone please help me here on how I can wire it so that only one sensor can set off the solenoid? ive tried diodes to try and block interference between sensors but it doesnt seem to matter. I understand that I should be using a protection diode between the collector and 12+ (not shown or implemented yet). Thanks in advance, Adam.
__________________
|
|
|
|
| Join OCAU to remove this ad! |
|
|
#2 |
|
Member
Join Date: Mar 2008
Posts: 29
|
what transistor are you using?
|
|
|
|
|
|
#3 |
|
Member
Join Date: Feb 2004
Location: Brisbane - Southside
Posts: 439
|
Depending on how the otuput of the sensors are driven, it looks like the 2 1k resistors are acting like a voltage divider. Hence why you are only getting about 1.8v output.
What you should use is something like an OR gate. The two sensors from the inputs of the OR, and the output of the OR drives the current transistor. Here's an example circuit of a transistor OR gate, 2nd one on the page.
__________________
Lots of trades - biggest so far, $2500 with Raynar |
|
|
|
|
|
#4 |
|
SLATYE, not SLAYTE
Join Date: Nov 2002
Location: Canberra
Posts: 25,776
|
As others have said, one sensor is pulling the voltage down to ground, while the other is trying to hold it at 3.3V. The result is that the voltage at the transistor is 3.3V/2 = 1.65V (depending on how powerful the pull-up/pull-down hardware in each sensor is).
If you just put one transistor on each sensor and then tie the outputs of those together (ie rather than tying the sensor outputs together before the single transistor) then that should work.
__________________
Main system: Phenom II X4 920 | 8GB (4x 2GB) DDR2-800 | Gigabyte M57SLI-S4 v2.0 | Leadtek Geforce 9600GSO 384MB | Enermax Modu82+ 525W | 1TB Hitachi HDD | 3.5" + 5.25" FDD Laptop: Compal EL80 | C2D T7200 | 320GB Fujistu HDD | 2GB DDR2-667 | GF Go 7600 |
|
|
|
|
|
#5 |
|
Member
Join Date: Aug 2012
Location: Perth, WA
Posts: 5
|
Thanks for the speedy replies guys. I'm out at th moment but will try that when I return home this arvo and report back. Cheers, Adam
__________________
|
|
|
|
|
|
#6 |
|
Grumpy Member
Join Date: Jun 2002
Location: /dev/null
Posts: 9,303
|
I think you should have a diode across the solenoid too, to stop its back-emf from damaging the transistor.
__________________
"How is anyone supposed to know that this isn't just a bunch of crap?" - Richard Feynman.
|
|
|
|
|
|
#7 |
|
Member
Join Date: Jan 2006
Location: Crooklyn 3012
Posts: 2,063
|
If the electronics fail, what's the backup to stop your dogs from killing
I'd be pegging 1.5m wide wire mesh - flat along the ground - at the fence line.
__________________
I'm the reason we can't have nice things
|
|
|
|
|
|
#8 |
|
Member
Join Date: Jul 2005
Location: Niraikanai
Posts: 6,553
|
yeah, a fly-back, or reverse biased diode across the solenoid would be a good idea. A 1N4007 or similar would do the trick.
__________________
I DO NOT support internet filtering!!! Tereno Empireo Rapidmova Reakcii Armeo
Check out my Youtube channel! |
|
|
|
|
|
#9 | |
|
Member
Join Date: Aug 2012
Location: Perth, WA
Posts: 5
|
Quote:
To everyone else helping, ive just whacked on a second transistor so that the signals are separate, and have joined the transistors back together at their respective collectors and emitters. Im still seeing the same issue here, where the sensor is outputting 1.8v instead of 3.3v? Im still having to walk past the two to set it off? Its not making sense to me. To get around this, couldn't I just use smaller (lower valued) resistors than 1K to activate? FYI protection diode now in place between collector and 12v. Cheers, Adam
__________________
|
|
|
|
|
|
|
#10 |
|
Member
Join Date: Aug 2009
Posts: 2,607
|
Does the thing fire if there's only one sensor connected?
I'm not sure what's going on with the sensor but at a guess you need about 6mA base current to get the solenoid to fire, so your 1k resistor is too much anyway. I'd put on a 220ohm and see if it fires, though I don't know what your sensor output current capability is. You might actually need a buffer between the sensor and transistor if the sensor won't provide enough current to drive the transistor base directly. |
|
|
|
|
|
#11 | |
|
Member
Join Date: Aug 2012
Location: Perth, WA
Posts: 5
|
Quote:
much appreciated
__________________
|
|
|
|
|
|
|
#12 |
|
Member
Join Date: Aug 2012
Location: Perth, WA
Posts: 5
|
Big thanks to all that helped. I tried the 220ohm resistors in place of the 1Ks and it works great! Thanks again
If any of you live around the Canning Vale area, id shout you a beer while we watch the dogs run away from the fence haha..
__________________
Last edited by adkeco; 20th August 2012 at 7:39 PM. Reason: added picture :) |
|
|
|
![]() |
| Bookmarks |
|
Sign up for a free OCAU account and this ad will go away! |
| Thread Tools | |
|
|