Shop OBEX P1 Docs P2 Docs Learn Events
optoisolaters not working with the prop — Parallax Forums

optoisolaters not working with the prop

science_geekscience_geek Posts: 247
edited 2009-08-02 21:02 in Propeller 1
I would like to use 2 4-channel optoisolators found at the sparkfun website, http://www.sparkfun.com/commerce/product_info.php?products_id=784, i for some reason can not get it to turn on a simple led from the prop, does anyone have any experience with these that they could give any help, i have tried every configuration possible, i just need 1 channel to work for now but will eventually need 6 working, any comments/help is welcome.

Comments

  • SamMishalSamMishal Posts: 468
    edited 2009-08-02 06:59
    You might be using 3.3V instead of 5V.....most chips require 5V for power
    and if you are using the Vdd of the Demo Board it will be 3.3V....make sure you are using 5V to power
    the optoisolator.

    Sam
  • StefanL38StefanL38 Posts: 2,292
    edited 2009-08-02 07:09
    hello Science-Geek,

    can you provide a datsheet details about LED current ?

    I don't believe that you have checked REALLY ALL configurations (there are thousands of it)

    so please post a schematic and a DETAILED description of what you have tried
    including COMPLETE sourcecode

    best regards

    Stefan
  • Nick MuellerNick Mueller Posts: 815
    edited 2009-08-02 07:28
    Hi science geek!
    If you look at the schematics provided by sparkfun, do you measure a volatge rise at pin#4?
    Are you sure, that you do have a signal on the input side of the OC?

    Nick

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Never use force, just go for a bigger hammer!

    The DIY Digital-Readout for mills, lathes etc.:
    YADRO
  • Peter JakackiPeter Jakacki Posts: 10,193
    edited 2009-08-02 08:10
    Trying to drive an LED? Usually optos don't have a lot of drive capability due to the inefficiency of driving the opto's led and then the phototransistor. Looks like the example circuit is a "test circuit", not that it is an example but that it is simply to measure the response of the device (100us pulse is for testing). Do not use this circuit, read the datasheet, understand it, and observe the limits.

    As to voltage since it's just a darlington phototransistor you can run with 3.3V easily enough but don't try to switch a led with it. Set up your circuit in the way that you actually want to use it (tell us if it helps).

    Typically optos are used to isolate inputs as you only need 10ma or so to drive the input led. Set the current limit resistor to "limit" the current that depends upon the input voltage (not 50 ohms!). When it comes to ouputs though they are a bit more limited as you need some isolated voltage for the load. By using the transistor as a "grounded emitter" with an open-collector though you can make it appear as a switch on the isolated ground.

    *Peter*
  • PhilldapillPhilldapill Posts: 1,283
    edited 2009-08-02 10:16
    I know you are wanting to use that particular isolator, but TI makes some VERY good ones. I'll give you the bad news first - they are only available in SOIC packages.

    The good news, is that you can get them in different configurations such as: 2 port bi-directional(2 isolators, 1 in each direction i.e. in and out) or 4 port with 1in-3out, 2in-4out, or all 4 in the same direction. They are 3.3V-5V compatible so they work fine with any voltage in between. Oh, a plus, is that they come in 150Mbs so they are EXTREMELY fast. Another bit of good news, is that they are in their sample program!

    The part number is ISO721M for the single channel, or ISO7240M for the 4 port. Go to TI.com and search the part number. Set up an account for free samples if you want.
  • JonnyMacJonnyMac Posts: 9,197
    edited 2009-08-02 16:37
    Without knowing your input to the opto-isolator it's difficult to help. The output side is a pretty standard open-collector circuit; connect the emitter pin to ground and the collector to a Propeller IO pin that has a 4.7K pull-up. The pull-up is required for you to see any state change on the Propeller IO pin.
  • kwinnkwinn Posts: 8,697
    edited 2009-08-02 21:02
    Science_geek, the two most important ratings (other than the max isolation voltage) are Vf (the forward voltage drop of the led) and CTR (current transfer ratio). For this particular device they are:

    Vf - typical 1.17, max 1.4 (at 10mA) This means that at 10mA current through the led there will be 1.17 to 1.4 volts across the led. If you are driving the led from a prop pin you would need a series resistor of (3.3 - 1.4)/0.01 = 190 ohms. Closest common resistor would be 180 ohms.

    CTR - min 80%, typical 300%, max 600% (@ 5V) This means that with 5V on the transistor the light output from the led will result in a minimum current through the transistor of 80% x 10mA or 8mA. The typical current would be 300% x 10 = 30mA, and the max would be 600% x 10 = 60mA.

    In most cases you would design the circuit so that it will operate properly at or near the minimum CTR, keeping in mind that the maximum ratings of both the diode and transistor can not be exceeded. Turning on a led should not be a problem. Use a 180 ohm resistor between the propeller and the opto isolator led, and a 330 ohm on the transistor side.
Sign In or Register to comment.