Netduino controller issues

Homebrew Talk - Beer, Wine, Mead, & Cider Brewing Discussion Forum

Help Support Homebrew Talk - Beer, Wine, Mead, & Cider Brewing Discussion Forum:

This site may earn a commission from merchant affiliate links, including eBay, Amazon, and others.

cobolstinks

Well-Known Member
Joined
Sep 24, 2008
Messages
226
Reaction score
2
Location
Rochester, MN
Last edited by a moderator:
Im not exactly using 1 wire, im using lm35 sensors with a netduino. The netduino only puts out 3v, I don't know whats going on because my sensor is all over the place with a 7 foot run, but accurate and stable with a 2 foot run...
 
I might suggest noise. Need decoupling capacitors on A/D lines? 0.1uF was recommended to me on my project, and I have yet to experiment with it.

Or, if it's not "too late" and you have a digital pin available, try tinkering with the 1-wire sensor. I'm not using them, but at this point I'm kind of kicking myself for not. Digital seems to be the way to go.
 
since that LM35 puts out an analog signal, you are definately going to need to calibrate it for whatever wires you end up using. also, if you could use 5v instead of 3, it would give you a better SNR. i dont see a need for larger than 22ga cable, and there is such a thing as too much here.

if you can switch to a digital sensor, like the popular DS18B20, that would fix all your problems itself. i have 6 of those sensors, and all of them use just two wires in a single piece of cat-6 ethernet cable (26 ga i think).

I don't know whats going on because my sensor is all over the place with a 7 foot run, but accurate and stable with a 2 foot run...

thats analog noise for you. might want to look into some shielded twisted pair cable. larger gauge isnt going to mean better, though. i would keep it between 22ga and 28ga.
 
cobolstinks said:
Ok I'm going to try the one wire sensors. If I still get noise won't that induce some crc errors?

I use one wire sensors with my arduino and don't have any issues with noise. I have about 6 ft of wire running to the sensors.
 
Hopefully I can be of some help, I'm an electrical engineer. Length of cable shouldn't be a problem unless you are pulling a lot of current through it. Do you have a schematic of what the sensor excitation (power source) and sensor output look like? Really need to know what the output of the sensor is driving.

You could be picking up noise, especially if it is near a condenser that switches on and off. But seems like you would be picking up the noise no matter if it were 2 foot or 7 foot.
 
Ok I'm going to try the one wire sensors. If I still get noise won't that induce some crc errors?

like i said, i have 6 sensors spliced in at various points in a 30+ foot, 26AWG cable without issue. they are supposedly good for 300+ feet of cable legnth before you run into serious issues that would corrupt the digital signal.

Do you have a schematic of what the sensor excitation (power source) and sensor output look like? Really need to know what the output of the sensor is driving.
if you google "LM35" the #2 result is a datasheet for it. there is ground and VCC in, and then a variable voltage output that is ratiometric to the temperature (+10mV per degree C). if you put a multimeter on a 7 foot loop of wire, you will see anywhere up to maybe 100mV or more induced into it just from moving the wire around. thats a +/- of 10 or more degreees, which is an enormous range for what its being used for. i would really only use a LM35 sensor on a fixed circuit board with short leads, and where i could control the noise very well. over many feet you should be using something digital.
 
audger said:
if you google "LM35" the #2 result is a datasheet for it. there is ground and VCC in, and then a variable voltage output that is ratiometric to the temperature (+10mV per degree C). if you put a multimeter on a 7 foot loop of wire, you will see anywhere up to maybe 100mV or more induced into it just from moving the wire around. thats a +/- of 10 or more degreees, which is an enormous range for what its being used for. i would really only use a LM35 sensor on a fixed circuit board with short leads, and where i could control the noise very well. over many feet you should be using something digital.

if you're seeing that much movement, then the sensor is bad or it is picking up a bunch of noise. Physically moving the wire doesnt induce any more or less electric field. Moving it towards a noise source does. Using twisted shielded cable will certainly help with any noise.

You could also amplify the signal output from the sensor (making the noise a much smaller part of the error). An op amp in a non inverting amp configuration could do this for you.

Again, I need to know what the sensor is connected to. If it is sourcing a lot of current then the resistance of the cable will drop a lot of voltage, throwing your reading off.

Either way, I don't think that much noise should be seen at 100 ft of cable, much less 7 ft.

edit: also, looking at the datasheet, if there is a large capacitance hanging on the output at the receive end, the output can't drive the capacitance, and it could be oscillating. the resistance of the wire could play a large role in that.
 
with a 7 foot cable is was getting +/-30 degrees F but was +/- 1 on the breadboard. +/-30 F is way not cool. Ordered the 1wire sensors yesterday so I'll try them out when they get in. At $1.75 a sensor for the DS18B20 I can't really go wrong. I should have tried them out first.
 
The DS18B20's are awesome, should have gone digital to start. Ill post a thread when I'm done. My hardware is all assembled just working on the code. Got it to join my lan and serve a basic html page with 4 temps on it, but im going to have it serve JSON so i can use this JS library. Highcharts - Interactive JavaScript charts for your webpage. Ill post the code as well incase someone wants to use.
 
The DS18B20's are awesome, should have gone digital to start. Ill post a thread when I'm done. My hardware is all assembled just working on the code. Got it to join my lan and serve a basic html page with 4 temps on it, but im going to have it serve JSON so i can use this JS library. Highcharts - Interactive JavaScript charts for your webpage. Ill post the code as well incase someone wants to use.

Absolutely! I just picked up a FEZ Panda II & I'm looking forward to adding some automation to my setup.
 
The Netdiuno only supports one wire temp sensors in a branch release of 4.1
Plus the netduino has some serious difficulty with regulating power over USB. You may have more stable readings if you use the power block instead.

And one more downer, I have a lot of trouble with reliable sockets and the netdiunos smallish memory space limits its capability.

Reliability is extremely important for something like running a heating element. My opinion is choose a different micro controller to work with. FEZ for example. The hydra is similarly priced and way more capable, stable and supports gadgeteering.
 
Back
Top