Hi,
Donald J. Organ IV:
> Can anyone point me to some materials on using the DS2405 with a solid state
> relay. Basically what I am trying to do is control some lights.
Define "a" solid state relay. There are lots of them.
The first question you need to ask is whether the relay needs more
current than the DS2405 can sink. If not, the problem is solved easily:
+5V
|
Relay
|
Resistor
|
DS24xx
|
GND
The resistance is calculated by (+5V - Urelay - Uds) / Irelay.
So let's say the solid state relay (as an example, LH1540) wants 1.25V
and 10mA to switch reliably. Unfortunately, the DS2405 only sinks 4 mA.
Thus, for this particular relay, you'd need a DS2413 (two switches, each
can sink 20 mA), or a DS2406 (pin A can sink 50 mA), or a transistor.
If we use a DS2413 or DS2406, Logic L (i.e., Uds) is at 0.4V.
Thus, the resistor needs to be (5-1.25-0.4)V / 10mA = 330Ω or so.
If we only have a couple of DS2405 lying around, this gets a bit more
complicated and we need to add a few more parts:
+5V +5V
e| |
Tpnp---R2----*---R3
c| b |
R1 |
| DS2405
Relay |
| |
GND GND
A simple general purpose PNP transistor like the BC557 switches 100 mA,
its Uce is around 0.2V. So R1 is roughly the same value as the sole
resistor in the previous schematic.
The transistor has a gain of >100 or so (again, check the data sheets),
so the current through R2 needs to be 0.1mA, so R2 is around 4.7kΩ. R3
is there so that the transistor turns off fast enough, let's pick 100kΩ,
or whatever other resistor in that range we have in our electronics grab
bag.
This concludes today's improptu "how to control a solid state relay" lesson.
Note, however, that you also need to pay attention to the "power" side
of the solid state relay. At minimum:
* ALWAYS set up your circuitry so that there's good and reliable
separation between the input and output sides. Ideally that means
a physical groove in your circuit board. Yes, I'm serious about this.
* ALWAYS make sure that it's impossible to touch the live wires
accidentally. (This should be a no-brainer, but ...)
* Our LH1540 is limited to 150 mA, has an internal resistance of 20Ω,
and a max. power dissipation of 400 mW. Let's play it safe and limit the
thing to 100mA (it'll live longer that way). 100 mA * 20Ω = 2V,
2V * 100mA = 200 mW (so we're safe on that front), and (here's the
important part): (110-2)V * 100 mA = 10W. Thus we may not switch more
than a 10-Watt bulb with that thing (OK, _you_ may not. I live in 220V
country, so I can switch 20W), which means that if we want to illuminate
more than our fingernail, we'd better use an energy-efficient lamp.
Or a more powerful solid state relay.
--
Matthias Urlichs | {M:U} IT Design @ m-u-it.de | [EMAIL PROTECTED]
Disclaimer: The quote was selected randomly. Really. | http://smurf.noris.de
v4sw7$Yhw6+8ln7ma7u7L!wl7DUi2e6t3TMWb8HAGen6g3a4s6Mr1p-3/-6 hackerkey.com
- -
I will not engage an enemy single-handedly until all my soldiers are
dead.
-- The Evil Overlord List
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Owfs-developers mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/owfs-developers