PDA

View Full Version : Water Temperature Sensor



rpfoh
09-19-2008, 10:57 AM
Hello Everyone,

I'm new to the forum and microcontrollers(But I do have prior programming experience). I'm about to start my first ever microcontroller project and I'm hoping to run into someone with some experience.

Ultimately, I plan to use a BS2 to display a temperature(and later, temperatures) on either a 2x16 or 4x20 display. The snag is, I'm trying to use the water temp sensor on my motorcycle as the input, and I don't know anything about the part. Any chance someone has a resource they might point me to, so I can learn more about figuring this out? All I know now is that the bike is probably in the 150 to 250 deg.F when running.

Post Edited (rpfoh) : 9/19/2008 4:08:22 AM GMT

Mike Green
09-19-2008, 11:01 AM
For a start, add a subject to your message. Use the pencil icon in the right upper corner of the message box to change it.

rpfoh
09-19-2008, 11:06 AM
Thanks. Missed that.

Edit: Omitted a piece of info. The sensor has two wires.

Post Edited (rpfoh) : 9/19/2008 4:23:17 AM GMT

SRLM
09-19-2008, 12:11 PM
It's probably some sort of analog device. Take a look at the sensor and see if there is any sort of chip in there. If I'm correct and it is analog, then you'll want to use an oscilloscope or multimeter to see what kind of voltages there are for different temperatures. While you probably can't use this dirrectly, it's a starting point.

I'd then look around at some of the online electronics stores / auto supply outlets for a device that is similar to yours. See how that device is set up, then see if it matches your measurements.

rpfoh
09-19-2008, 12:29 PM
Thanks SRLM. Checking the voltages is no problem, I intend to do that as soon as I get a chance to pull the fairings off. I'm wondering it if might be easier to put a T on the hose and put a temp sensor with known values in... as long as I can make that fit under the bodywork it wouldn't be bad.

Jonathan
09-19-2008, 09:43 PM
rpfoh,

If you do use another temp sensor, look into the LM34 in a TO-92 package. It fits nicely into a 1/4" brass tube, and as such is easy to integrate into plumbing. I use them in my solar hot tub, they are easy to use and reliable.

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
www.madlabs.info (http://www.madlabs.info) - Home of the Hydrogen Fuel Cell Robot

SRLM
09-19-2008, 09:46 PM
If you can get you own sensor in that would be best. You'll have replacements and you void the warranty on your bike. Plus then you could test at your computer with a glass of hot water.

rpfoh
09-19-2008, 10:26 PM
The LM34 looks good, thanks Jonathan. Looks like I can even get them cheap at digikey.

I love voiding warranties.

Jonathan
09-19-2008, 10:55 PM
Warrenties are made to voided. :-0

Here is my probe construction. Get some 1/4" brass tube. Get a 1/4" compression to 1/2" NPT adapter. Drill it through with a bit just large enough to allow the tube to pass through.

Items needed:
1/4" brass tube
1/4" compression to 1/2" NPT fitting
1/4" compression nut and ferrel
3 or more wire cable that fits into a 1/4" tube. I use direct burial phone wire.
Waterproof heat shrink tubing
Silver solder and flux
Thermal grease

Take the tube and put a dab of flux in one end, then crimp aprox. 3/8" of the end in a vise. Find a way to hold the tube vertical, so that the crimped end is down. Take a little solder and drop it down the tube. Heat the crimped until you see the solder wick through the crimp. Use silver solder for this, not electronics solder. Make sure to use the right flux.

Put a little alcohol in the tube, shake and drain. Do this a few times to get rid of the leftover flux. Put some thermal greas in a syringe, and attach a little tube that fits into the brass sensor tube. Squirt a little grease into the crimped end. you can also just put a little grease in the tube and push it down, but I suspect that most of it winds up on the sides of the tube. You can feel the air compress when you do it this way, which must be pushing the grease past the LM34.

Solder the LM34 to the cable. Leave the sheath as long as possible, it makes the sensor easier to insert into the tube.

Insert the tube through the drilled out fitting. Slide the ferral and nut onto the tube and loosely thread the nut to the fitting, but don't tighten it. Put the heat shrink on the wire. Slide the sensor into the tube. Shrink the tubing. Thread the 1/2" NPT into your plumbing, then tighten the compression fitting. Done!

HTH,

Jonathan

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
www.madlabs.info (http://www.madlabs.info) - Home of the Hydrogen Fuel Cell Robot

rpfoh
09-19-2008, 11:32 PM
Jonathan,

What do you usually use for A2D with the LM34?

Dave-W
09-19-2008, 11:43 PM
Jonathan (http://forums.parallax.com/member.php?u=41162)
How do you make the LM34 water proof. I have tried epoxy with only marginal results.

Dave





If you do use another temp sensor, look into the LM34 in a TO-92 package. It fits nicely into a 1/4" brass tube, and as such is easy to integrate into plumbing. I use them in my solar hot tub, they are easy to use and reliable.

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
www.madlabs.info (http://www.madlabs.info/) - Home of the Hydrogen Fuel Cell Robot

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Dave W.

stephenwagner
09-19-2008, 11:59 PM
RPFOH

Your sensor is probably a negative temperature coefficient thermistor. Parallax has published a paper on using a NTC as a temp. sensor.
·
See Application note 7 of the attached document. http://www.parallax.com/Portals/0/Downloads/appnt/stamps/bs1Appnotes.pdf (http://www.parallax.com/Portals/0/Downloads/appnt/stamps/bs1Appnotes.pdf)
·
Although the code is for a BS1 and the thermistor is from radio shack, the principals are the same. You may have to remove the sensor from the motor cycle and place it in boiling water, measure the resistance and then do the same in ice water. They all follow a log curve.
·
What is the sensor currently connected to on your motor cycle? Do you have a wiring diagram for the motor cycle?
·
SJW

rpfoh
09-19-2008, 11:59 PM
Dave-W said...
Jonathan (http://forums.parallax.com/member.php?u=41162)
How do you make the LM34 water proof. I have tried epoxy with only marginal results.

Dave




He isn't. From what I can tell, the crimped end of the pipe is in the water flow, so it doesn't need to be.

Jonathan
09-20-2008, 12:06 AM
rpfoh,

What the heck is your name? :-0

As to ADC, what I use depends on the project. Two suggestions are the LTC1298 (12bit,2channels) or the TLC2543 (12 bit, 11 channels). Both of those have sample code for the Stamp available.

Dave, I have never made a truly submersible probe. The one that measures the temp in my hot tub gets submerged sometimes, but usually is above the water line, and it has been working for a couple of years. The waterproof heat shrink does pretty well it seems. After all, it is meant to get wet with 220VAC under constant submersion. None of the other sensors in the system (of which there are 5) ever see any water on the wire end.

Also, take a look aty Tracy Allen's site for more LM34 probe construction techniques.

Jonathan

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
www.madlabs.info (http://www.madlabs.info) - Home of the Hydrogen Fuel Cell Robot

Jonathan
09-20-2008, 12:36 AM
Oh, I forgot to mention this above, you also need some small heat shrink for the leads of the LM34. And Stephan is right that you can use the sensor that is already there, but I really like the LM34's ease of use and accuracy without complex calibration.

Another note, if you want rea accuracy, make sure the length of brass tube sticking out from the assembly is less than an inch, and shield/insulate the probe end and brass tee that it is in. Windflow on a bike might influence the readings. I have encountered this on very cold nights with the output/input sensors on my thermal panel array.

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
www.madlabs.info (http://www.madlabs.info) - Home of the Hydrogen Fuel Cell Robot

Geekgirl
09-20-2008, 11:35 AM
· Having just made a set of immersible/submersible sensors for a project myself (using LM34s), let me share my experience as they work well.

I used a 1/4" hose to 1/8" pipe hose barb fitting so I could thread them into what they need to monitor.
I used stereo headphone extension cable for the wiring, as it has the 3 conductors and is easy and round to work with and fits the ID of the hose barb fitting very nicely.
I fed the wires thru the fitting from the hose side with a piece of heatshrink to shrink onto the wire where it comes out of the hose barb and soldered them to the sensor leads and used tiny heat shrink on each.
I put a wrap of scotch tape around the threads, sticking up about 1/8" past them and cut slots in a small cardboard box to set them in so they'd stay in a verticle position so that I could fill the cavity in the pipethread end of the fitting encasing the sensor.· (let the sensor sit up a bit untill you fill the epoxy in, then pull the wire and pull the sensor down into the cavity a little)
I found that epoxy that sets in 30 minutes and comes in a dispenser that mixes the stuff in the nozzle works best.
I got nicely encapsulated LM34 sensors that screw into a 1/8 NPT hole with a 1/8" stereo plug on the end to they can be installed, removed, swapped around, used fairly universally,·very easily.

Now as far as using a setup like that for a motorcycle where there is pressure and high temperature, It ain't gonna fly.

There are metal can versions of the LM34 that are rated for the higher temps required.

Probably the easiest way to make a suitable sensor would be to take a small·(1/8" or 1/4") brass pipe nipple, braze one end closed and have a machinist mill the inside of the closed end·flat with an end mill so you could put a metal can sensor up against it and backfill it with Marine-Tex or J-B Weld.


· Darlene

gth629e
09-21-2008, 02:33 AM
Hey,

Just to weigh in a bit, take a look at these

http://www.thermaltake.com/product/Liguid/Upgrade/cl-w0033/cl-w0033.asp

I have two of these that are doing nothing but collecting dust. Even if you still wanted to use a basic stamp which I encourage, you could still use the temperature probe which is already prepped for fluid. It has adapters for a lot of different tube sizes. Anyway, just let me know if your interested. I would love to help out and good luck with your project!!!

Regards,
Brian

sam_sam_sam
09-21-2008, 03:12 AM
· (http://forums.parallax.com/member.php?u=54065)rpfoh (http://forums.parallax.com/member.php?u=54203)
Take a look at this one

http://www.omega.com/ppt/pptsc.asp?ref=OS36SM&Nav=tema10

Take a look at this one also

http://www.omega.com/ppt/pptsc.asp?ref=BT-000_BT-090&Nav=tema04

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
··Thanks for any·http://forums.parallax.com/images/smilies/idea.gif·that you may have and all of your time finding them

·
·
·
·
Sam

Post Edited (sam_sam_sam) : 9/20/2008 8:28:53 PM GMT