Go Down

Topic: isolating the arduino output via optocopler (Read 2631 times) previous topic - next topic

HugoPT

Hello
I'm developing a project to school which I want to activate a motor via PWM signal but I want isolate the arduino output with a optocopler just in case of preventing a possible damage to arduino board.
Does anyone have a circuit with a optocopler and a relay or a transistor?
Debian,Mint,Ubuntu
Arduino Mega 2560
Arduino Nano
Arduino Duemilanove
MAC OS Montain Lion
Raspberry PI Model B

bubulindo

Relays and PWM don't normally work together... they do make nice sounds before breaking though. :)

Optocouplers can be a problem depending on the frequency you choose to control your motor. Normally PWM frequencies for motors tend to be somewhat high, whilst commuting frequencies for optos (the cheaper kind) aren't. Not that it is impossible, it is more expensive and maybe difficult to locate the parts.

So, you could control the motor with a power driver L298, 293, something like that, or go with transistors. Both of which have plenty of schematics around the internet.
Eu não sou o teu criado. Se respondo no fórum é para ajudar todos mediante a minha disponibilidade e disposição. Responder por mensagem pessoal iria contra o propósito do fórum e por isso evito-o.
Se realmente pretendes que eu te ajude por mensagem pessoal, então podemos chegar a um acordo e contrato onde me pagas pela ajuda que eu fornecer e poderás então definir os termos de confidencialidade do meu serviço. De forma contrária toda e qualquer ajuda que eu der tem de ser visível a todos os participantes do fórum (será boa ideia, veres o significado da palavra fórum).
Nota também que eu não me responsabilizo por parvoíces escritas neste espaço pelo que se vais seguir algo dito por mim, entende que o farás por tua conta e risco.

Dito isto, mensagens pessoais só se forem pessoais, ou seja, se já interagimos de alguma forma no passado ou se me pretendes convidar para uma churrascada com cerveja (paga por ti, obviamente).

CrossRoads

Here's an opto that's pretty quick.
http://www.dipmicro.com/store/4N35
Drive the input side by bringing the cathode low (so that the transistor is off when the arduino starts up). Be sure to use a series current limit resistor to avoid arduino pin damage.
Use the Collector to drive a motor drive transistor for some real current flow.
Designing & building electrical circuits for over 25 years.  Screw Shield for Mega/Due/Uno,  Bobuino with ATMega1284P, & other '328P & '1284P creations & offerings at  my website.

HugoPT

Did you think 4N26 will do the job?
I found on ebay for a nice price
Debian,Mint,Ubuntu
Arduino Mega 2560
Arduino Nano
Arduino Duemilanove
MAC OS Montain Lion
Raspberry PI Model B

Grumpy_Mike

Quote
Did you think 4N26 will do the job?

What job you haven't given any details of what you want to do and what circuit you want to use it in.

HugoPT

I want isolate the arduino pins(digital for motor or  pwm to more small things)to prevent a possible damage , since I want to control some real motor 230V.
the circuit is a simple resistor conected to an optocopler, and on the other side I want connect a relay to activate the motor.Of course I wont connect the relay directly to the opto transistor output since the relay will destroy it.I was thinking make  a stage with another transistor to deal the current of the relay and the base of this transistor conected to the output of the optocopler, but this is the main idea.
Did you think this is ok?
will the 4N26 works?
Debian,Mint,Ubuntu
Arduino Mega 2560
Arduino Nano
Arduino Duemilanove
MAC OS Montain Lion
Raspberry PI Model B

Grumpy_Mike

You said:-
Quote
I want to activate a motor via PWM signal

You can't control a mains motor with PWM.

If you are using a relay you don't need an opto isolator.

If you are having to ask these questions you are not ready to play with mains.

Perfo

do you just want to turn a motor on or off ? Or do you want to do some sort of speed control ?  You project is a little confusing. Yes that opto isolator will be OK for use in a circuit that simply switches a motor on or off. No it wont be any good to use with a PWM signal then a relay to speed control a motor as speed control, mainly due to the relay.

Go Up