News:

PROTON pic BASIC Compilers for PIC, PIC24, dsPIC33

Main Menu

Correct use of feedback diode and spike suppression

Started by TimB, Jun 26, 2023, 05:48 PM

Previous topic - Next topic

TimB


Hi all

I'm updating a schematic. It has 2 alarms that are intended to be just to ground the line on the alarm. I started off using a mosfet then decided a NPN prebiased transistor like the MUN2214. It cannot handle much current and I would prefer that. It will have a resistor in line say 100ohm and a surge suppressor. I'm using a PTVS6V5S1UR_115

But I'm not sure now about a adding a feedback diode. They might try and connect it to a small relay and the back emf may kill the transistor. (I think)

But I'm not sure how to wire it.

There may be a small device that can do all that but all I can find are buffers. I only want to just let it float so they can pull the signal up and I will ground it.

Any tips appreciated
Screenshot 2023-06-26 184537.png

Gamboa

Tim,

I use it this way:
Long live for you

ken_k

Hi Tim
If a relay is used Gamboa's suggestion is good, it is the way I do it often using prebiased transistors as they save components on the board.

From your schematic and description it looks like you have an open collector output with the intention of sinking current only.
The low voltage TVS diode seems to suggest the circuit sinking 5V, is this the case? Are you supplying the voltage for the external alarm/relay?
Most 5V relays have a coil resistance of < 220 ohm if this is the case a 100 ohm series resistance will prevent the operation of many relays.

John Lawton

Hi Tim,

we'd need to know more about the alarm and it's power supply before being able to recommend a driver circuit.

John

TimB

My PCB is meant to live in a control panel. It monitors devices linked on an i2c bus and inputs like a temperature chip and a PT100 sensor and then runs a process that produces a result.

The main input voltage to my board is 12v as I step down to 5v. All my system works 5v except the Pt100 side that is 3.3v and I have level converters for that.

I have 4 x 0-5v analogue outputs that can be connected to anything like say a 0-5v to 4-20ma converter

I have 2 inputs that are lines pulled up to 5v that the user grounds to activate. Those are diode protected and have a TVS on the line as well. I will rate the TVS to probably 12v.

I want to add an alarm out. But do not want to add relays as I'm short on space. Hence just a low current sink they can wire to what ever. I want to protect it against the installer stuffing a 12v or higher voltage in and blowing my board up as I sink it.


I will say that I'm going to make a post later on my current despondency ref my development of this system in that I do not know what the hell I'm doing and how no body will buy it due to the lack of adhering to standards.
 

RGV250

Hi Tim,
Are you short of space on the PCB or the enclosure, IMO (and others) make some nice DIN rail relays that are 6mm wide. I think they do 5v ones but could not find them.
https://imoautomation.com/imo_us_usd_view/relay-socket-base-6249fec35df7d.html  The Relays are easily replaceable as well.
Personally I would supply the relays as you cannot guarantee what the customer will do on their side.

Bob

See_Mos

Gamboa's method is the correct way to do it. This way your board will only be damaged if the end user does something stupid that destroys the transistor.

As I mentioned before I still prefer to use MOSFET SSR's to isolate the output, even though they have become a bit expensive.

TimB

Many many thanks

Just to clarify I do not want to use a relay, I have no room for any on my PCB. My original question was in relation to protecting against some one trying to use it to power a relay and the back EMF killing my trani

Remember this a signal to be read not to drive anything. As it just sinks I will say the max applied voltage is 24v as the MUN2214 can cope with MAX of 50 so 50% should be ok.

What was pointed out by Ken-K was that you could not sink enough current with the 100ohm resistor in line to power a relay. So I think my original schematic will work and be safe.

The TVS should as was also pointed out be rated to the right voltage.

Thanks again

Tim

John Lawton

You expressed concern over compatibility with industry standards. Is the alarm a PLC input? On a recent project my custom module had to output a 24V signal into a PLC input and accept 24V control signals from a PLC output.

If you have a similar situation, use this partial circuit. You would need to add a grounded emitter NPN to pull R23 to ground, in turn driven by the PIC to turn on the 24V o/p.

This circuit will output about 24V but at limited current (4.5mA) to protect against a shorted output condition.


TimB

Thanks John

The unit is a pcb in din rail case that would replace a PLC (it includes a 64x128 screen). I thought about a PLC but they are EXPENSIVE for what I want my kit to do the PLC would cost > £1k.

NOTE my system for various reasons runs on 12v. 24v would be a pain to regulate so I think others can run on 24v and I will just sink what ever they are using (24v max)

My board will talk to outside world via:-

4 x 0-5v signals that can be programmed to output particular test results. In practice there will be 0-5 to 4-20ma modules. They will be off the shelf and I hope certified. These will connect to say a chart recorder or a BMS system

2 x inputs. These just need you to ground them to initiate an action (programmable)  Start up, Sleep or start a test. No issues with that and I think I'm protected

2 x Alarm outputs You can set a limit that the alarms will trigger if seen. (I have not thought yet how to mute the alarm :O. This the circuit I'm looking at. How the user interfaces to this I do not know but really if I say it can sink 2 amps they may try and power something and then I have issues with back emf.
The very limited current grounding will force them to use a logic signal and they can then convert that to what ever. Perhaps using a SS relay.
In practice they can configure their monitoring system to trigger alarms. Its up to them. I though do not want my kit to die because they tried to power a klaxon or something using it.