nemmi69
Posts: 46
Joined: Tue Jan 10, 2012 11:49 am

Re: cheap i/o optoisolated board

Thu Feb 02, 2012 5:39 pm

Any one know of a cheap optoisolated i/o boards or easy to follow circuit design?

acmbc68
Posts: 11
Joined: Thu Jan 26, 2012 2:28 pm

Re: cheap i/o optoisolated board

Thu Feb 02, 2012 5:52 pm

nemmi69 said:


Any one know of a cheap optoisolated i/o boards or easy to follow circuit design?


For breadboard-level digital i/o work, try phototransistors (with pull-up resistors if needed). Dirt cheap and easy.  Can dig up some references if needed.

Added bonus, can do (within limits) voltage level conversion.

For analog applications, it's a bit trickier.

If  you "just" want digital outputs to drive real world loads, look for relay boards on eBay

nemmi69
Posts: 46
Joined: Tue Jan 10, 2012 11:49 am

Re: cheap i/o optoisolated board

Thu Feb 02, 2012 6:48 pm

well i am no electronics bod hough can follow a diagram. first project is based around 4 inputs. i want to use it on a vehicle so must be able to protect from high volt spikes. is there a speed limit?

error404
Posts: 351
Joined: Wed Dec 21, 2011 11:49 pm

Re: cheap i/o optoisolated board

Thu Feb 02, 2012 7:16 pm

Optoisolators are very simple. If you"re using them as switches, you can basically model them as LEDs and drive them with a series current limiting resistor just like you would any other LED. Set the current from the datasheet"s LED current vs. collector current graph so that you have the necessary output sinking capability that you need.

On the output side, they are usually NPN transistors, and you"ll normally at least have access to the collector and emitter. So either configure them in common collector or common emitter depending on your needs. Available source/sink current will be provided in the datasheet as a curve of diode current vs. collector current. With a typical 4N35, it"s kind-of linear and close to 1:1, so you shouldn"t need an extra driver vs. driving directly from the micro pins. If you need push-pull output (ie. need to both source and sink current), you'll need to buffer the output of the optoisolator somehow, using 74 series logic is probably the easiest way.

If we"re only talking about slow-speed requirements (say, < 10KHz), you can basically neglect everything else.

That said, unless you want separate ground domains for some reason, there"s not really much reason to use them.

Edit: Okay I see you want to use these in a vehicle, that's a good application for them. The easiest thing to do is to use a low LED current (say 1mA), such that relatively high voltages don't come anywhere close to exceeding the specification. Since you're driving it into a microcontroller you can use large pull-up resistors and will need very little output current capability.

User avatar
Gert van Loo
Posts: 2487
Joined: Tue Aug 02, 2011 7:27 am
Contact: Website

Re: cheap i/o optoisolated board

Thu Feb 02, 2012 10:52 pm

Probably superfluous but : Make sure you also use a fully isolated power supply. In case of automotive it will be a DC-DC converter.

nemmi69
Posts: 46
Joined: Tue Jan 10, 2012 11:49 am

Re: cheap i/o optoisolated board

Fri Feb 03, 2012 1:07 pm

Got a cheap AIM104-IO32 to try out. Does warn o use an extra circuit to protect against high voltage. No idea how quick it is.

Still would like a circuit diagram of an opto i/o board to build myself. aiming for a cheap system.

error404
Posts: 351
Joined: Wed Dec 21, 2011 11:49 pm

Re: cheap i/o optoisolated board

Fri Feb 03, 2012 8:57 pm

I was hoping my description would be good enough for you to design such yourself, it's pretty trivial for simple requirements. Are you after input or output? From/to what? How fast does it need to be?

Your I/O board can be bidirectional, supporting this with optoisolation can be a bit tricky. Do you need that?

jwatte
Posts: 203
Joined: Sat Aug 13, 2011 7:28 pm

Re: cheap i/o optoisolated board

Fri Feb 03, 2012 10:50 pm

You might want to just buy an Arduino and run it from the USB port.

The Ruggeduino works well as an I/O board, because it has a lot of protection that the default Arduino board doesn't.

http://ruggedcircuits.com/html.....duino.html

User avatar
Gert van Loo
Posts: 2487
Joined: Tue Aug 02, 2011 7:27 am
Contact: Website

Re: cheap i/o optoisolated board

Fri Feb 03, 2012 11:44 pm

nemmi69 said:


Got a cheap AIM104-IO32 to try out. Does warn o use an extra circuit to protect against high voltage. No idea how quick it is.

Still would like a circuit diagram of an opto i/o board to build myself. aiming for a cheap system.



Ok, here you go (as I am suck a sucker...)


nemmi69
Posts: 46
Joined: Tue Jan 10, 2012 11:49 am

Re: cheap i/o optoisolated board

Sat Feb 04, 2012 5:25 pm

ta for that.

what would be the best way to protect it all from high peak surges when testing a car?

nemmi69
Posts: 46
Joined: Tue Jan 10, 2012 11:49 am

Re: cheap i/o optoisolated board

Sat Feb 04, 2012 5:27 pm

also it going to have to be fairly fast as i expect to be able to use it on cars. I am looking for both input and output.

User avatar
ledow
Posts: 40
Joined: Thu Feb 02, 2012 12:55 pm

Re: cheap i/o optoisolated board

Mon Feb 06, 2012 10:59 am

The spec sheet for that optoisolator device says that it's slowest operation is 4 microseconds.  That's about 25,000 state changes a second.  May not be perfect for everything but that's the price you pay for optoisolation.

To be honest, for car circuits, you're better off just putting voltage regulators on anything that comes in if you're that worried, or using a regulated power supply and only interfacing optically (which might limit you - you *MIGHT* get OBDII data at those rates, for instance, but then again you might not).

Or just saying "feck it" and put fuses on anything for their maximum rating and see which ones pop when you run the car.

User avatar
Gert van Loo
Posts: 2487
Joined: Tue Aug 02, 2011 7:27 am
Contact: Website

Re: cheap i/o optoisolated board

Mon Feb 06, 2012 3:26 pm

Well the title is 'cheap i/o optoisolated board' not 'fast i/o optoisolated board'. So I went to the website of a big electronics provider, searched for opto-isolator and sorted by price. (No other criteria) The one in my schematic was bottom of the price list.

That is what you get if you give specifications to an engineer. (Search for "joke engineer manager balloon")



britguy
Posts: 16
Joined: Mon May 28, 2012 1:34 am

Re: cheap i/o optoisolated board

Sun Jun 03, 2012 5:47 am

Gert please excuse the dumb question, but why doesn't your circuit diagram show a 270ohm resistor between pins 4 and 6 for output from raspberry pi, as per the h11L1 data sheet? I tried your circuit and couldn't get it to work, but then I added a 270R and I can now get it to turn on a motor (using an h bridge driver) when the rasp pi pin is low, and off when it is high. I want to get it to turn the motor on when the pi output pin is high, any ideas what I can do to modify the circuit to achieve this?

Thanks for any assistance you can provide!

Gert van Loo wrote:nemmi69 said:


Got a cheap AIM104-IO32 to try out. Does warn o use an extra circuit to protect against high voltage. No idea how quick it is.

Still would like a circuit diagram of an opto i/o board to build myself. aiming for a cheap system.



Ok, here you go (as I am suck a sucker...)

Return to “General discussion”