I need help with a temperature monitoring project which
It consists of a thermal probe connected to an arduino one. make the connection
and everything works perfect I can read the temperature without problem.
the problem arose in the place where I want to locate the project where
in some moments the probe sending an erroneous signal (-127.00)
but it is alternated, then resets the correct reading.
In the place there are several signals and electrical equipment working.
I think the mistake is difficult because of the noise in the place.
I was reading a bit and saw the option of placing an optocoupler to remove
the noise in the probe reading. Is this a good option? what kind of opcocoupler
Should use?
Try using a stiffer (lower value) pull-up resistor on the OneWire signal, 4k7 or 3k3.
I suspect the cable isn't shielded allowing noise in. If you can break the cable near the sensor and add a
100nF ceramic decoupling capacitor between 5V and ground in the cable that might help.
Colorambal:
I am using the sensor DS18B20 (10 meters) and arduino uno..
the connection cable is the one that brings the probe
The DS18B20 is digital, not analog.
But MarkT's suggestion of a smaller pullup resistor should help. Put the resistor at the sensor end, not the Arduino end.
I use similar probes. I read the probe every ten seconds, the arduino sleeps for eight seconds between readings, and then it powers up the radio, and takes the reading. I ignore temperatures below -50 when I save the data. I also get odd values of -500 as the battery goes flat, but the -127 is the probe function., iirc. Have a look at the Dallas data sheet, you may be better connecting it as one wire., or not. I expect the cable is unscreened.