Author Topic: Over my head...  (Read 969 times)

0 Members and 1 Guest are viewing this topic.

Offline AirsniperTopic starter

  • Newbie
  • Posts: 4
  • Country: gb
Over my head...
« on: February 01, 2023, 06:41:05 am »
I have a project I am working on.

I need to have optoisoltors / optocouplers in the project.

What I built for a game site my son plays at is a couple of team counters.

I am upgrading them to add remote control on 433 Mhz, some 4 channel units.

The transmitter I have set up so it operates just below the maximum voltage of 12 volts (10.9 volts) using a DC-DC CC-CV buck boost converter.

The receiver has to be on 5 Volts. 

I need to use some PC123 optocouplers I have and the data sheet says voltage for the LED is 1.2 volts (1.4 max) and a 10uA current.

How to I calculate the resistor needed to drop the voltage and current?

Am I right in saying that its (5v - 1.2v) / (10 / 1,000,000) = 380,000 ohms = 380K ?


 

Offline Swainster

  • Frequent Contributor
  • **
  • Posts: 259
  • Country: sg
Re: Over my head...
« Reply #1 on: February 01, 2023, 06:58:56 am »
Hi Airsniper,

10uA is the reverse current i.e. the current which flows when the transmitter LED is reverse biased - this is probably not relevant to your application. To drive this LED you should aim for a forward current of about 5mA i.e. you need a current limiting resistor of approximately 760 ohms. 1K should also be fine.
 

Offline tooki

  • Super Contributor
  • ***
  • Posts: 11501
  • Country: ch
Re: Over my head...
« Reply #2 on: February 01, 2023, 07:33:32 am »
Given that 5mA is on the low side of the de-facto operating range (given that numerous other specs are given at If=20mA), I wouldn’t go below 5mA, so I’d probably use 680 ohms, or even 470 ohms, not 1k.
 

Online pcprogrammer

  • Super Contributor
  • ***
  • Posts: 3704
  • Country: nl
Re: Over my head...
« Reply #3 on: February 01, 2023, 07:41:57 am »
Correct. The datasheet mentions a typical forward voltage of 1.2V at 20mA forward current.

You mention both 10.9V and 5V and wonder at which one you connect the optocoupler LED. Your calculation shows 5V and then the calculation of Swainster is correct, but you will have to match the resistance with what is available within a given range.

Quite common would be to use 470 ohm in this case depending on what is connected to the other side. The mentioned 1K ohm should indeed also do the job.

Offline AirsniperTopic starter

  • Newbie
  • Posts: 4
  • Country: gb
Re: Over my head...
« Reply #4 on: February 01, 2023, 03:32:46 pm »
There are two voltage rails on the receiver unit, 5V and 8 volts, is the receiver unit, a separate unit which is in its own enclosure. I have read the comments about the receiver and the voltage is strict, above 5 volts and the unit lets out the magic smoke.

10.9V is the transmitter as 5v on the transmitter by all accounts gives a couple of meters range and I need to have max range of about 20 meters which is 10+ volts.

The PC123 optocouplers (x2) will be needed on the receiver unit as its output will form one of two functions, to help pulse a pin input on a unit that has an 8 volt supply to power and pulse the pin, the reset pins are simply shorted together. So this only needs the optocoupler arranged as a device that bridges the pins when activated.

I don't have any way of showing a wiring diagram, I can however show you via these links the units I am using.

The counter https://www.amazon.co.uk/dp/B016U4J2RG is a unit that is used as a tachometer or as a counter up and down.
The Tx / Rx units https://www.amazon.co.uk/gp/product/B08ZMN4PMJ is a set of 433 Mhz units with 4 channels

The optocouplers are needed x2 for the isolation of the higher voltage rail from the lower voltage rail as the counter is operating on its lowest voltage setting.

So what I need is to drop the 5volt rail on the low voltage rail down so that the input voltage is 1.2v.

In this data sheet https://media.digikey.com/pdf/data%20sheets/sharp%20pdfs/pc123%20series.pdf page 5, it shows a table. If I am reading this right,

Looking up resistor voltage dropping, ( input volts - unit vots ) / milliamps is what I need to use. I think I got the wrong scale earlier as milliamps is 1/1000 making 20mA 0.02amps.

So 5v = 1.2v = 3.8v     3.8v / 20uA  or   3.8v / 0.02 = 190 ohms

The closest I can get to that figure is 195 ohm (120 ohm + 75 ohm inline)
 

Online pcprogrammer

  • Super Contributor
  • ***
  • Posts: 3704
  • Country: nl
Re: Over my head...
« Reply #5 on: February 01, 2023, 04:26:41 pm »
The receiver module you are using can't output 20mA according to the specs on amazon.

Quote
Receiver module:
Working Voltage : DC2.5V-5V
Working current:3MA
Output current : 10 mA
Working Frequency: 433MHz
Receive Sensitivity: -108dB
Working Temperature : -25~75
Working mode:Point move, self-locking, interlocking
The output: 4 channel CMOS level signal Corresponding to the remote control ABCD 4 buttons

It states 10mA, but to be sure you should try to get the datasheet for the used chip.

Also for the optocoupler it does not need the 20mA per se. The specs also show a graph for If = 5mA, but the simplest way to see if it works is to test it with a 680 ohms resistor or even a 1K ohm one.

Since you are driving the counter inputs there is not much load on the transistor of the optocoupler, so I think it will work fine with even the 1K ohm resistor. But you also need a resistor of say 4K7 ohm on the transistor side from the collector to the 8V supply and the emitter needs to be connected to the ground. The counter is connected to the collector.

Online pcprogrammer

  • Super Contributor
  • ***
  • Posts: 3704
  • Country: nl
Re: Over my head...
« Reply #6 on: February 01, 2023, 04:45:56 pm »
Another option would be to use a couple of small mosfet's like the 2n7000, if the counter module supply can be connected with the ground to the ground of the receiver.

See the attached picture for how it can be done.

Offline BillyO

  • Super Contributor
  • ***
  • Posts: 1382
  • Country: ca
Re: Over my head...
« Reply #7 on: February 01, 2023, 04:46:20 pm »
I find in using opto-isolators that it is best to drive them as close to the peak in the current transfer ratio as you can.  For this device the peak is @ ~7 mA.  That's what I'd aim for.  Also try to keep the collector current as low as you can (under 5 mA) to get the best response time.
Bill  (Currently a Siglent fanboy)
--------------------------------------------------
Want to see an old guy fumble around re-learning a career left 40 years ago?  Well, look no further .. https://www.youtube.com/@uni-byte
 
The following users thanked this post: tooki

Offline AirsniperTopic starter

  • Newbie
  • Posts: 4
  • Country: gb
Re: Over my head...
« Reply #8 on: February 02, 2023, 04:15:20 am »
I have had to revise my plan as I won't get the upgrade finished in time.

I have instead opted to outfit a new wiring loom that will facilitate a plug in of the Rx unit in the counters at a later date.

I have been looking around for software that I can use to draw the circuit but find nothing offers what I need, I found easyEDA and its horrible to work with, has very limited options for components and I canned it after spending 20 minutes working out how to do simple things in it.

I don't need anything fancy I just need to draw things on a page that shows connectors, switches, LED's etc.

Any suggestions?

 

Offline BillyO

  • Super Contributor
  • ***
  • Posts: 1382
  • Country: ca
Re: Over my head...
« Reply #9 on: February 02, 2023, 01:44:24 pm »
Any suggestions?
Have you looked at Dip Trace?  They have a free (but limited) version.
Bill  (Currently a Siglent fanboy)
--------------------------------------------------
Want to see an old guy fumble around re-learning a career left 40 years ago?  Well, look no further .. https://www.youtube.com/@uni-byte
 
The following users thanked this post: Airsniper

Offline AirsniperTopic starter

  • Newbie
  • Posts: 4
  • Country: gb
Re: Over my head...
« Reply #10 on: February 02, 2023, 02:31:11 pm »
I will try it, I don't have my windows machine hooked up to the internet as its only for music and video production.

So I will grab the binary and look at it later.
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf