EmbeddedRelated.com
Forums
Memfault Beyond the Launch

short / open circuit of a sensor

Started by Tamilmaran S June 30, 2006
hi,
   How can we find out the short circuit / open circuit of a sensor or
something else which are connected to the microcontroller's port pin?
Is there any algorithm available to check the fault of the line which
will be implement into the software?  Thanks

with regards
Tamilmaran s

In comp.arch.embedded,
Tamilmaran S <tamilmaranz@gmail.com> wrote:
> hi, > How can we find out the short circuit / open circuit of a sensor or > something else which are connected to the microcontroller's port pin? > Is there any algorithm available to check the fault of the line which > will be implement into the software? Thanks
Maybe, depends on a lot of details you did not give. OK, to give you a start: Is this uC pin an input or an output? Is it digital or analog? Please feel free to give more details than asked for. -- Stef (remove caps, dashes and .invalid from e-mail address to reply by mail)
We in the controls business often set a sensors active range for .5 to
4.5 volts.  So if we read <.5 or > 4.5 we know the sensor is bad.

Cuts down on the resolution I know, but when cost of believing a bad
sensor is high, as in flight controls we make that tradeoff.



Tamilmaran S wrote:
> hi, > How can we find out the short circuit / open circuit of a sensor or > something else which are connected to the microcontroller's port pin? > Is there any algorithm available to check the fault of the line which > will be implement into the software? Thanks > > with regards > Tamilmaran s
Stef wrote:
> In comp.arch.embedded, > Tamilmaran S <tamilmaranz@gmail.com> wrote: > > hi, > > How can we find out the short circuit / open circuit of a sensor or > > something else which are connected to the microcontroller's port pin? > > Is there any algorithm available to check the fault of the line which > > will be implement into the software? Thanks > > Maybe, depends on a lot of details you did not give. OK, to give you a > start: Is this uC pin an input or an output? Is it digital or analog? > Please feel free to give more details than asked for. > > -- > Stef (remove caps, dashes and .invalid from e-mail address to reply by mail)
Stef, it is the analog input to the microcontroller. It may be a temperature sensor, in that the analog signal is converted into digital signal by using in build ADC for further processing.
rjames.clarke@gmail.com wrote:
> We in the controls business often set a sensors active range for .5 to > 4.5 volts. So if we read <.5 or > 4.5 we know the sensor is bad. > > Cuts down on the resolution I know, but when cost of believing a bad > sensor is high, as in flight controls we make that tradeoff. >
hi, Is there any relation with 'open circuit voltage' and 'short circuit current' for justifying the fault condition? Can you give some circuit diagram explanation for your comments?
> > > Tamilmaran S wrote: > > hi, > > How can we find out the short circuit / open circuit of a sensor or > > something else which are connected to the microcontroller's port pin? > > Is there any algorithm available to check the fault of the line which > > will be implement into the software? Thanks > > > > with regards > > Tamilmaran s
"Tamilmaran S" <tamilmaranz@gmail.com> wrote in message 
news:1151902726.867711.154330@m79g2000cwm.googlegroups.com...
> > Stef wrote: >> In comp.arch.embedded, >> Tamilmaran S <tamilmaranz@gmail.com> wrote: >> > hi, >> > How can we find out the short circuit / open circuit of a sensor or >> > something else which are connected to the microcontroller's port pin? >> > Is there any algorithm available to check the fault of the line which >> > will be implement into the software? Thanks >> >> Maybe, depends on a lot of details you did not give. OK, to give you a >> start: Is this uC pin an input or an output? Is it digital or analog? >> Please feel free to give more details than asked for. > > Stef, > it is the analog input to the microcontroller. It may be a > temperature sensor, in that the analog signal is converted into digital > signal by using in build ADC for further processing.
The classic way of detecting open-circuit sensors is with a pull-up - i.e. the sensor normally provides a voltage in a certain range, and an input signal above this range means it's open-circuit. BTW, it's a little unusual to connect a sensor directly to a microcontroller port pin. Something like a thermocouple provides a voltage in the microvolt/millivolt region, and would need an input amplifier (and cold-junction compensation). In any case, connecting a remote signal directly to a microcontroller is a bad idea from the point of view of robustness - consider what would happen if there were a noise spike exceeding the rails on the input line etc etc. Steve http://www.fivetrees.com
We think in terms of coverage of possible failures.

We do not get 100% coverage of all failures.

But if we set the range for .5 to 4.5 and we get a voltage outside that
range we have a good idea the sensor is not to be trusted.

Further coverage is usually accomplished by using multiple sensors and
comparing the output of the sensors, for example if you have 3 sensors
and 2 of the sensors are reading 1.1 voltage and the third is reading
2.5 then we suspect one of the three is bad.

By using a pull up resistor to the sensor we can detect a sensor open
circuit or short circuit.

                                  +5
                                    |
                                    |
                                    R1
                                    |
                                     --------------------ADC
                                    |
                                    |
                                  Sensor
                                    |
                                    |
                                  Gnd

Note R1 has to be sized with the sensor drive capabilities in mind.


Tamilmaran S wrote:
> rjames.clarke@gmail.com wrote: > > We in the controls business often set a sensors active range for .5 to > > 4.5 volts. So if we read <.5 or > 4.5 we know the sensor is bad. > > > > Cuts down on the resolution I know, but when cost of believing a bad > > sensor is high, as in flight controls we make that tradeoff. > > > hi, > Is there any relation with 'open circuit voltage' and 'short circuit > current' for justifying the fault condition? Can you give some circuit > diagram explanation for your comments? > > > > > > > Tamilmaran S wrote: > > > hi, > > > How can we find out the short circuit / open circuit of a sensor or > > > something else which are connected to the microcontroller's port pin? > > > Is there any algorithm available to check the fault of the line which > > > will be implement into the software? Thanks > > > > > > with regards > > > Tamilmaran s

Memfault Beyond the Launch