Is it possible to spec the \"polarity\" of Spin and Coolant I/Os?

From the original Synthetos forum (2011–2025)

Started by jimtellier on in TinyG Support. 5 replies, last activity May 30, 2018.

#

I've got a dual relay board with optoisolator inputs that don't want to work with the 3.?V outputs of Spin and Coolant pins. The board probably wants +5. But I am
able to use an "active low" trigger voltage, which would work just fine (I believe
the optos must have built in weak pullups, but no schematic so just a guess).
I don't see a way to specify Polarity for these control outs; if that's possible,
I'd love to just go that way, otherwise, do you have any suggestions for driving
such a board from TinyG? Anyone used any kind of "interface board" or such?
Thanks for any ideas!
Jim

Staff #

Caution - "optos must have built in weak pullups, but no schematic so just a guess" -- Pullups to what voltage??
If any tinyG in or out sees more than 3.3V, weak or not, death could be imminent.

I would verify first that the opto leads are completely isolated from any potentially large voltages.

It is likely that the tinyG outs can sink more current than it can source, but there is not easy logical(software) way to flip the "on" level for these outputs

Have a look at https://github.com/synthetos/g2/wiki/G2core-on-DUE---External-Interfaces
A single MOSFET switch such as shown in the "External Interface Suggestions" would work for your need.
the DUE and tinyG device hardwrae is similar, 3.3V logic

#

Ah, good call on the pullup speculation! I'll measure it, to be sure!
But looking at your link to interface recommendations, I don't quite
see an exact parallel of my scenario to the DUE interface. I could
clearly use a MOSFET (P-channel, if I understand correctly) IF there
were a voltage source (e.g. +5) such as that available on the DUE.
But all I have available is +24V (TinyG, fan and relay coils), and the
+3V logic outs of Spin and Coolant pins.
I'm kinda flying blind here, without schematic for the relay board (which
btw is a SMAKN 24V 2-channel Opto-isolated board; the only spec they provide
is that it requires "5ma trigger current" - no voltage spec. I figured if it's
a diode drop, 3V ought to do it, but setting the jumpers to "HI" trigger doesn't
respond to +3 from the TinyG I/O's. Jumpering to "LO" active inputs works by
setting the trigger inputs to GND. See my dilema?

Staff #

Optoisolator inputs are typically an led in series with a limiting resistor of some sort. A fully on LED is generally around 2V.

tinyG has a Vmot to 12v regulator on board for driving 12V fans, I have used that to provide bias for interfaces like this. Most opto interfaces are rated for 5v to 18V or higher, but there is by no means a standard.

You may have to experiment a bit to determine if an external resistor would be needed to limit input current to 5ma if a FET switched 12V on and off.

#

Well, I finally "got woke" and decided that since I've got +24V
available for the relay coil, I just found a switching NPN
and calc'd resistors to convert that to a 0 -> +5V emitter output, gated by
the 0 -> +3V. Using the "HI" mode on the relay board now works fine!
Thanks for the helpful info - steered me down the right path!
Jim

Staff #

Good news and good luck with your project.

This topic is from the original forum (May 2018). Your reply starts a new discussion linked to it.

Reply

Different problem? Ask a new question

Back to TinyG Support or latest activity.