If i connect 5 or more sensors to Arduino, i should get the confirmation that all the sensors connected are working fine. I need this output as beep or double beep by a buzzer initially when i start the system.
This ensures all the sensors are not faulty.
Later the output for individual sensors is based on their characteristic.
Perhaps you should start by saying what sensors they are, and how you would know if any one is actually working?
Let's say one is an ultrasonic, just as an example. The only way you know it's working is to put something in front at a known distance measured with a tape, and see if it reports the right value. Or if one's a temperature sensor, you could see what value it says and compare that to a known-good calibrated thermometer.
Some, like the DHTs, if I recall do have the means in their libraries to test the presence of the sensor, but even then, how to tell if the values it reports are close to reality?
But I think you should at least start by giving the forum a clue as to what sensors you have.
sayHovis:
Perhaps you should start by saying what sensors they are, and how you would know if any one is actually working?
Let's say one is an ultrasonic, just as an example. The only way you know it's working is to put something in front at a known distance measured with a tape, and see if it reports the right value. Or if one's a temperature sensor, you could see what value it says and compare that to a known-good calibrated thermometer.
Some, like the DHTs, if I recall do have the means in their libraries to test the presence of the sensor, but even then, how to tell if the values it reports are close to reality?
But I think you should at least start by giving the forum a clue as to what sensors you have.
Hi,
Thanks for replying.
As you said, i really need to know the presence of the sensors. i can keep any sensor.
Taking your example of ultrasonic sensor, i need to know whether the sensor itself is good when i start the arduino to which it is connected.
To explain more clearly, if i have a bulb which the filament is blown. i can say before switching it on that it will not give the light as output.
Hope i'm clear to you ?
Can you tell us your electronics, programming, arduino, hardware experience?
You will have to write code to get what you need done.
Tom....
Hi, Thanks for replying.
I'm passionate about DIY electronics kits.
i don't have much experience in the above you mentioned.
That's the reason i have posted in the forum for help
RANGADURAI:
Hi,
To explain more clearly, if i have a bulb which the filament is blown. i can say before switching it on that it will not give the light as output.
You can tell that by visual inspection, with an electronic sensor there's not likely to be any way to see whether it's working or not.
About the only way I can see to do what you want is to have multiple sensors of the same type and throw an error if they don't agree to some predefined tolerance.
RANGADURAI:
If i connect 5 or more sensors to Arduino, i should get the confirmation that all the sensors connected are working fine. I need this output as beep or double beep by a buzzer initially when i start the system.
This ensures all the sensors are not faulty.
Later the output for individual sensors is based on their characteristic.
pl help
You can do that.
setup() code for a MPU9250.
/ start communication with IMU
status = IMU.begin();
if (status < 0) {
Serial.println("IMU initialization unsuccessful");
Serial.println("Check IMU wiring or try cycling power");
Serial.print("Status: ");
Serial.println(status);
while(1) {}
}
In the above you can see that there is code to detect the proper initialization of the MPU9250, and some code in the section for when the MPU9250 fails, in the failure part you can write your own code to sound bells, light lights, launch nuclear warheads or what ever.
So its easy to detect the sensor and it is up to you to write the code to do so.
RANGADURAI:
If i connect 5 or more sensors to Arduino, i should get the confirmation that all the sensors connected are working fine. I need this output as beep or double beep by a buzzer initially when i start the system.
This ensures all the sensors are not faulty.
Later the output for individual sensors is based on their characteristic.
pl help
Post us full details of all the hardware you refer to. That would be datasheet links or product pages. We need to know what you are talking about. Please please don't expect us to google stuff from a description, provide the concrete links please.