Detecting open-circuit or short-circuit

I have several sensors, solenoids, etc., some of which are powered by a 5 volt regulated supply (which is supplied to the Arduino as well), and others of which are powered by a 12 volt supply. I wish to be able to have my Arduino Mega be able to detect if any of these devices have an open or short circuit, and, in the case of a short circuit, ideally be able to identify which of the devices has the short circuit.

What are the best ways to detect this? Is there any straightforward circuit that will be able to output digital LOW/HIGH to the Arduino depending on the existence of an open or short circuit? I'm going to be implementing this on a PCB shield, so it doesn't have to be too simple.

Surely if the same 5v is supplying your arduino, in the event that there is a short circuit, your arduino is already unconscious.

KenF:
Surely if the same 5v is supplying your arduino, in the event that there is a short circuit, your arduino is already unconscious.

Well yes. I would want the short-circuit detector to have circuit-breaker functionality of course.

More details of the sensors and solenoids? Detecting fault states like this requires knowledge of how things are connected up - various voltages and currents may need sampling.

You're in an area here with several potential problems. The first is inductive switching transients in the relays and solenoids. See the following thread reply #6 for a little background, check the references.

http://forum.arduino.cc/index.php?topic=276019.msg1943395#msg1943395

Secondly, you'll want to use NPN or n-MOSFET inverters to switch the relays and solenoids. See various ckts here,

https://www.google.com/search?q=n-mosfet+npn+inverter+relay+driver&rlz=1C1RNLG_enUS517US518&espv=2&source=lnms&tbm=isch&sa=X&ei=v-FTVOzpKMaMyASV4YLoDQ&ved=0CAgQ_AUoAQ&biw=1089&bih=888

Thirdly, note that you DEFINITELY need those reverse-wired diodes across the relay/etc coils to squelch inductive switching transients.

Fourthly, in general, it's not the best idea to power both your logic and inductive loads from the same power source, eg 5V, as there will always be residual voltage level-shifts and noise spikes when the loads switch.

Fifthly, you can probably do a reasonable job monitoring for shorts and opens by connecting a voltage-divider, and/or low-pass filter, to the "top" pin [collector or drain terminal] on the inverter transistors, and connect that to your Ardunio I/O pins. IE, the point where the relays connect to the inverters. You can figure yourself what happens to that voltage as you turn the inverter on and off, and also what it will be if the inverter or relay is open or short.

Also, I would definitely use a filter cap at the I/O pin.

MarkT:
More details of the sensors and solenoids? Detecting fault states like this requires knowledge of how things are connected up - various voltages and currents may need sampling.

Currently the 5 volt sensors consist of several pressure transducers (i.e. they take 5 volts, consume a few milli-amps, and output an analog voltage). In addition, I have frequency-to-voltage converters that require 12 volt power and output a 5 volt signal. Not sure about their current consumption, but probably similar. My 12-volt solenoids are connected through a SainSmart 16 relay board and, depending on the solenoid, require 200-1000mA. The relay board has an on-board regulator which provides the 5 volt output for the Arduino and related sensors.

Sorry, but details matter - which sensors - part numbers, datasheets, etc. The output
impedance of a sensor is a crucial detail.

An existing solenoid driver module could have its current monitored to check this
agrees with the expected current level - perhaps a high-side current monitor chip in
its supply. This would detect most issues as you could check the current changes
appropriately as each relay is switched.

A general method to validate analog sensor inputs is to check the rate of change of
values and that the value is in the expected range.

To verify open circuit issues with a low output impedance a pull-up or pull-down
resistor can be used (but if the sensor has significant impedance this would distort
the reading. Monitoring the supply current per sensor is another approach.

My 12-volt solenoids are connected through a SainSmart 16 relay board and, depending on the solenoid, require 200-1000mA.

You're definitely gonna have large inductive spikes with these, and need to take the precautions mentioned in the first part of my previous reply. And even worse if you have long wires going from the drivers to the inductive loads. Then you'll have large inductive loops in the wires, besides in the coils themselves, and these loops are also called EMI-radiating antennas. Good luck.

Hello,im also new to this arduino life...i really need someone to help me to make a simple short circuit detector using the arduino board.Im in a group of three and we are trying to do something new for our school project. So it would be great if we could get a repply from you ASAP

Detect a short between what and what?

CrossRoads:
Detect a short between what and what?

I also wondered. I thought it might be possible that the instructor left it open ended like that, to see how the students explore the problem space.

okay, we are gonna explain our project to you. we are using the arduino board to make a simple home automation system that also could detect short circuits. we have tried making the home automation circuit. now, we dont know how to make the connections so that our project could also detect short circuit.it will be great if you could help us by teaching us how to make the connections and program the board. :slight_smile:

You still haven't explained what kind of short circuits.

if you are talking about a mains short circuit, the circuit breaker or fuse will detect a short circuit automatically, if your talkin about arc fault detection, perhaps looking for fast changes in amperage draw.

Please give some more detail. Home automation is sorta vague.
Are you using 110 ac volts, 220 ac volts, relays, 12 volts, or what ?
Describe your system please.

our system is based on these link below.
Arduino Smart Home Automation Thailand
http://androidcontrol.blogspot.com/20...
http://www.smart-homecontrol.com/
http://softpowergroup.net/

we are just doing a prototype of the system so we would like to know how do we connect a circuit that detects short circuit to the same board and how do you make the circuit that detects the short circuit?use what materials? thank you for responding ASAP cause this project is very important to us

the starting system we are gonna try is for 5v

HELLO !

The OP is "unmonk" .

This thread was hijacked in Reply#8

(their objectives sound similar but are very different. Answering one, does not answer the other.Who's thread is this ?)

@OP,
You have the right to click on "Report to Moderator" and complain your post has been hijacked in Reply#8.

@itsafrina,
Start your own topic and remove your replies from this thread.

okay, we are sorry cause we thought it was under the same topic. thank you for alerting us about this.

Insert an optocoupler in the circuit, that at normal operation, will provide a output voltage about half scale. Test that voltage with the analog input. It it is about half scale, all is well.
If it goes to low, the ckt is open.
If it goes to high, the ckt is shorted.

You realize that if you have a switch in the ckt, that turns it on and off. You will detect open when the switch is turned off.