Machsupport Forum
Mach Discussion => General Mach Discussion => Topic started by: cncfreakcncfrea on May 31, 2017, 02:45:46 AM
-
Hello all,
I have created a break out board schematics it is finished and I would like to add a relay for coolant/flood to pin 17, so when coolant is activated the relay clicks, is the illustration below correct?
(http://i1204.photobucket.com/albums/bb407/cncfreakcncfreak/BOB/2017-5-31%20%2002-40-17_zpswvxfkueo.jpg) (http://s1204.photobucket.com/user/cncfreakcncfreak/media/BOB/2017-5-31%20%2002-40-17_zpswvxfkueo.jpg.html)
-
You need to connect a protection diode across the relay coil and also check the model / rank of the PC817 opto as their maximum drive current rating varies from 2.5 to 30 mA and this will determine the type of relay you could use.
Maybe better to purchase a ready-made cnc relay board ( ebay from China ) ??
Tweakie.
-
Hi,
I don't think your diagram is correct...the relay coil is permanently energised as you've drawn it.
The relay coil should be in series with the optotranistor, commonly in the collector side.
Craig
-
Hi,
don't know whether this will attach....
-
Hi,
it worked! The protection diode Tweakie talked about is D1. You don't really need a resistor in the output circuit, the relay coil is commonly
1kohm and will self current limit.
Craig
-
Thank you for replying.
Tweakie,
This is more like a electronic project I wish to make it myself. Will look into protection diode, thanks.
Joeaverage
I did a test on a bob's pin 17 and gnd using a voltmeter for continuity, after entering Mach3 I measure Pin 17 and gnd no continuity, then I type M08 at MDI voltmeter beeping I get 5v, M09 to disconnect or off.
My output setings are:
Output #1 Enabled Port 1 Pin17 Activ low = off
-
Ignore the above I was describing a bob using SN 74act245N, totally different to 74Hc14, sorry..
-
Hi,
what voltage do you have available? Clearly the 74HC********* has to be 5V and so also the input photodiode of the optocupler.
The relay and the phototransistor don't have to be 5V, in fact better to be 12V or even better 24V. Relays are available with
5V coils but they are pretty small and liteweight and not likely to last long switching 230V to a pump. There are many more 12V
relays and due to industrial use thousands of 24V relay to choose from.
Craig
-
Ok I've just built a simple circuit in scratch, the only diode I have is a 1N4007N, is is ok?
-
the only diode I have is a 1N4007N, is is ok?
Yes.
Tweakie
-
mm....scratch did not work....
-
Hi,
measure the voltage across R1 with the buffer amp output high, do the calculation to find the current thru R1.
Most optoisolators have approx. unit current gain across the opto boundary. Thus if you have 1mA input thru the photodiode then the
phototransitor will have approx. 1mA in emitter/collector circuit. Most PCB relays will need 20mA for reliable operation,
ie you should aim for 20mA in the photodiode.
Another possibility to increase the sensitivity of the phototransistor is to bias the base. It is for this reason that the base is
pinned out. Use a resistive voltage divider to apply 0.55-0.58V or so to the base. If you bias to high or circuit conditions change,
temperature for instance, you risk having the phototransistor conduct WITHOUT the photodiode conducting!
Craig
-
A quick question:
Is this schematic correct?
https://karusisemus.files.wordpress.com/2016/07/sch.png
-
Hi
correct in what sense...it will not work for a relay. The 4.7k resistor permanently powers a relay coil if hooked to
an output and the phototransistor shorts the coil...all for what?
Craig
-
Hi,
just been dealing with a spotwelder/dent puller at work based on triac control of a transformer of low ouiput voltage but very high
current. Had to repair the control PCB and it turns out the 'solid state relay, SSR' was faulty. Bought a new one popped it in and away it went.
Bought it for $3.27 NZD, about $2.50 US so hardly breaks the bank. Has input sensitivity of 1mA with output capacity in the tens of mA and on
state resistance of 25Ohm AC and 3 ohm DC. Very useful and sensitive enuf to make your design task a little easier.
Check it out...LH1540....6 pin DIL IC
Craig
-
Let's forget the relay for the moment. I'm not sure if the following schematic works?
https://karusisemus.files.wordpress.com/2016/07/sch.png
(http://i1204.photobucket.com/albums/bb407/cncfreakcncfreak/BOB/2017-6-20%20%2005-30-04_zps5cvjzcql.jpg) (http://s1204.photobucket.com/user/cncfreakcncfreak/media/BOB/2017-6-20%20%2005-30-04_zps5cvjzcql.jpg.html)
The PC817 is replaced with 4N35, because I got some spare 4N35.
I have made the board with components soldered, but didn't work...
-
Hi,
the circuit diagram certainly looks like it should work.
Do you have a multimeter or better yet an oscilloscope?
Check for Vcc and Vdd on the board to start with.
Just as a matter of interest how did you make your board?. I note that its double sided and plated thru holes are not an easy proposition
for a hobbyist. Not unreasonable to whip around with your multimeter set on 'continuity' and check any thru holes.
Craig
-
Hi Craig,
I will check the VCC and VDD later with multimeter, might get a Oscilloscope soon since I'm doing a lot of electronic project recently.
I use Diptrace 2.4.02PCB software, double sided works quite well in diptrace but not single layer, I tried before and was rejected by the pcb manufacturer 5 times due to short circuit. Single layer still works depend on complexity.
The pin 7 of 6N137 meant to be NC, is this correct?
(http://i1204.photobucket.com/albums/bb407/cncfreakcncfreak/BOB/pin%207_zpsdvqtilcz.jpg) (http://s1204.photobucket.com/user/cncfreakcncfreak/media/BOB/pin%207_zpsdvqtilcz.jpg.html)
checked Vcc Vdd Gnd1 Gnd2 in Diptrace schematics, looks alright..:
(http://i1204.photobucket.com/albums/bb407/cncfreakcncfreak/BOB/vcc%20vdd%20gnd1%20gnd%202_zpsfnk4wvoa.jpg) (http://s1204.photobucket.com/user/cncfreakcncfreak/media/BOB/vcc%20vdd%20gnd1%20gnd%202_zpsfnk4wvoa.jpg.html)
-
Hi,
do you mean you got a PCB manufacturer to make your board? If so then could probably guess that the vias are intact.
You need to recognise that you have two different earths. To measure a signal you must reference to its correct earth.
Yes, pin 7 of the 6n137's is non connected.
Craig
-
Yes there are vias intacted.
Yes I'm aware there are 2 separate power supply VCC and VDD, gnd 1 and gnd 2.
What should the value of VDD be? 7v?