Detect Disconnection

Hey!

I’m working on a magnetic field sensor with a Seeeduino Film, and as it is a wearable application, I can have issues because of wire disconnections…As a result I wonder how to detect if a wire is disconnected from a pin?
Is there a way to detect it? with code? or analog way?

Thanks in advance :slight_smile:

It depends largely on what's connected to the wire.

What is?


Rob

Oh ok. I use digital pins as outputs, analog as inputs. 4 Digital pins are connected to a multiplexer, 1 to a buzzer. 1 analog pin acquire the multiplexer output signal, 3 analog pins acquire other analog signals (alim through voltage divider) and I also use Aref.

As a result I wonder how to detect if a wire is disconnected from a pin?

You can't. You need to make better connections so the wires don't get disconnected.

You can't. You need to make better connections so the wires don't get disconnected.

Should I laugh or cry? haha, anyway thank you :P

My project is to put my Seeeduino in a helmet, to detect magnetic field and produce a sound from the buzzer when the magnetic field is too high. As Seeeduino film is really tiny, and as a helmet can be hurt a lot of time, I'm wondering how to make the user aware if a wire is disconnected. There's no "hazard" from disconnection, but for example if my multiplexer output is disconnected from my Seeeduino, it won't be able to know anything about the magnetic fields, and then my circuit would be useless, at all :astonished: If my buzzer becomes disconnected, I would use a led or something. I read that analogRead() returns random values if not connected, then I can't read if the value remains to 0 (that would mean there's a problem in my case). As a result I'm wondering how to detect a disconnection (if I can't I will just make sure it is as hard as possible to disconnect something).

the question is whether the extra components and coding is worth the result?

I don't want it to require too many extra component, my project has to take as less space as possible.

Seeeduino Film is awesome by it size, but not really practical. I have no more ports available, but I can release one if needed...

Can you add some small components directly on the Arduino board (like 1/10 watt axial resistors soldered point-to-point, etc.)

No :~

Is it practical to fit redundant sensors or indicators, etc.?

Hum, not really...

As you can notice, I have no (or only few) options. I guess I will do what you said, find the difference between connected and disconnected for my circuit and then I'll try to establish a method of detection.

I guess I will do what you said, find the difference between connected and disconnected for my circuit and then I'll try to establish a method of detection.

I suspect the hardware/software required to do that will be much more complex then the original purpose/application of the project.

Lefty

to detect magnetic field and produce a sound from the buzzer when the magnetic field is too high

OK why, magnetic fields aren't dangerous? What effect are they supposed to have that makes exposure undesirable?

Diminator: As you can notice, I have no (or only few) options

You seem to have narrowed it down to "can I detect a disconnected pin only using software". That's going probably going to be complicated. You might need to change something, even if it makes the project one resistor heavier.

Grumpy_Mike:

to detect magnetic field and produce a sound from the buzzer when the magnetic field is too high

OK why, magnetic fields aren't dangerous? What effect are they supposed to have than makes exposure undesirable?

So is this our first example of arduinoizing a tin foil hat application?

What’s with all the negative vibes, folks? Maybe the MagnetowavesTM are beneficial, not harmful! I’d buy one of these in a snap! I can then share the location of these soothing emanations with everyone else!

So is this our first example of arduinoizing a tin foil hat application?

mouhahaha XD

OK why, magnetic fields aren't dangerous? What effect are they supposed to have that makes exposure undesirable?

Scientists didn't find anything that demonstrate magnetic fields are dangerous, but they can't say there's no issue at all. Maybe EMF are acting on something we are not looking at...some studies have been done on the behaviour of exposed rats, and they all became like "hyperactive", smaller testicles etc... By the way, I'm talking about magnetic fields about 3000µT, not the EMF that your microwave/computer/TV produce ! And, you know, even if my project seems useless, I'm pretty sure it could be useful for big companies which have huge security rules for their employees. Just imagine, if one day an employee is in trouble because of a long exposure to a really high magnetic field, it could be a big financial loss. But with my project, they would say : "His hat said to him he was exposed to a high magetic field" !

ok --> :zipper_mouth_face:

I think you are mixing up a static magnetic field with an electromagnetic wave and you are using the term EMF which stands for electro motive force which is what we measure in volts.

some studies have been done on the behaviour of exposed rats,

Have you got a link to the paper on that? Not just someone reporting what they think it says.

Have you see the magnetic fields that they use to levitate a mouse?

Magnetic resonance imaging uses fields of 1.5 Tesla which makes your 3mT rather puny.

if one day an employee is in trouble because of a long exposure to a really high magnetic field, it could be a big financial loss.

I think you don't understand the law. If an employer provides monitoring for something he is admitting that it might be dangerous and so he becomes liable for any damage he causes. If he goes along with the normal scientific thinking and advice that these things are not dangerous he then can't be sued because of negligence because he is following what is believed.

I would give up this hippy nonsense and do something useful with your time, or at least learn a bit about magnetism, electric fields and electro magnetic waves.

Perhaps a helmet that protects against pseudo-science and crackpots could be developed. I reckon it would need a lot of crystals and some quantum components. (Sorry - The CIA/Aliens/Elvis told me to say it via magnetic control of my brain)

or at least learn a bit about magnetism, electric fields and electro magnetic waves.

I'm using http://ocw.mit.edu/courses/physics/8-02-electricity-and-magnetism-spring-2002/video-lectures/ for that.

Jeroen

I would give up this hippy nonsense and do something useful with your time

Wow, peace man.

As many french people, I have issues with my english, that's why you misunderstand me, like with my use of EMF (thought it was ElectroMagnetic field).

[...]or at least learn a bit about magnetism, electric fields and electro magnetic waves.

I don't really mind about this subject. In fact, if you want the truth, a company wants me to do this project. Did you really think I woke up one day saying : "I have to know if I'm not exposed to high magnetic fields !!!!" ....poor you.

By the way, I was asking about, hum, just read the topic title. I'm not a magnetic expert and I DON'T WANT to be, I don't give a **** about that. The first comments asking why I would do that were funny, but now you are just irritating, trying to show people you are smarter than others...

By the way didn't you understand that I was talking about a field of which I don't anything when I wrote :

ok --> :zipper_mouth_face:

Thought it was easy.

Wow, there’s no danger of your sensor being erroneously triggered by your personality.

In terms of your actual question:
Do you have any spare channels on your multiplexer? Perhaps feed this a set voltage at the source and have your setup default to this channel unless a reading is being made. Then you could periodically check that this value is what is being output.

The answer to your original question was answered by the "make sure the wiring is secure" comment. If you are having a project, any project concerning safety, and especially one you are doing on commission you don't construct things so that wires could drop out. It is not even an option here.

didn't you understand that I was talking about a field of which I don't anything when I wrote

No that completely passed me by. See I am not so smart am I?

you don’t construct things so that wires could drop out. It is not even an option here.

You are right, but I have to think about every issues that could happen, and as it could be used by workers, troubles may happen, even if I connected my wires as hard as possible.

Do you have any spare channels on your multiplexer? Perhaps feed this a set voltage at the source and have your setup default to this channel unless a reading is being made. Then you could periodically check that this value is what is being output.

I do have spare channels, and your solution seems great and easy! I don’t know why I didn’t think about it by myself… :cold_sweat:
About my other Analogs input, I know the range of the voltage that I have to read, then I could check if nonsense values are read and then detect a problem (with small probability of a fail detection if read values by Analogread() with not connected pin are really random).
Then it’s ok for analogs inputs. Thank you for your help.
What about digital outputs? any idea?

See I am not so smart am I?

Anyway, your post was not that nice yesterday and it just irritated me. Apologies about my answer.