Temperature readings into a PC?

This is the place for any magazine-related discussions that don't fit in any of the column discussion boards below.
jimryannz
Posts: 4
Joined: Mon Apr 28, 2003 1:01 am
Location: New Zealand
Contact:

Temperature readings into a PC?

Post by jimryannz »

Our village is putting in a web cam and we want to include the temperature on the picture. The supplier of the web cam software has replied to our question with:
“I would suggest writing the outside temperature into a file and then use the "file" tag from within a ConquerCam caption to read it, e.g.
{file("temperature.txt")}”
Where can we find a temperature sensor to do this? ie plugs into the PC and stores the temperature as a .txt file? Don't want to have to purchase a complete weather station!
Am not a techo so would be great if could get something that is "plug 'n play"
Appreciate if anyone has any suggestions - or could build something for us.
Dimbulb
Posts: 324
Joined: Sun Oct 13, 2002 1:01 am

Re: Temperature readings into a PC?

Post by Dimbulb »

An analog signal such as a voltage from a temperature sensor needs to communicate thru a serial port with for example a 12 bit A/D (analog to digital)card that produces and updates a file with the current temperature.<p>Plug n play ? Good question. Are there alot of non-technical folks plugging in weather station equipment into there serial ports ?<p>[ April 28, 2003: Message edited by: 1206DX ]</p>
greg123
Posts: 361
Joined: Sat Sep 07, 2002 1:01 am
Location: St. John's NFLD Canada
Contact:

Re: Temperature readings into a PC?

Post by greg123 »

I dont think so.... :-)<p>But, the A/D is very simple to wireup with a temp sensor.<p>With about 100 lines of code in c++, you can make a loging program that will log temperature into a text file.<p>Can you read schematics? I can quickly draft a simple circuit for you, and email the program or source code to you as well.<p>Check this link out<p>ADC<p>
Greg
manuka
Posts: 12
Joined: Fri Apr 18, 2003 1:01 am
Location: Wellington, New Zealand
Contact:

Re: Temperature readings into a PC?

Post by manuka »

I know this may seem V E R Y simplistic, but we got round this ( using a trial webcam here in Wellington NZ ) by just placing a good size digital clock/thermo unit in the camera's field of view ! It also indicated if the image was "old" of course & needed refreshing. Electronically the Dallas Semi range (DS1820 & DS18B20 ) are great = 3 wires with temp. already serial encoded
Will
Posts: 310
Joined: Tue Feb 11, 2003 1:01 am
Location: Katy Texas
Contact:

Re: Temperature readings into a PC?

Post by Will »

To add to Greg's reply - that is the way to go but you still need a baord with something on it i.e. you can't plug a temp sensor straight into a PC - There is a way which is slightly more simple and therefore less ezpensive i.e. You can purchase a semiconductor temp sensor - (I forget the part number but I'm sure you could easily gety it Greg) which outputs a bit serial digital representation of the temperature so that all it needs is a buffer and a powersupply and I believe you could get the power supply out of the PC RS 232 port. If you can't find the part number I will dig for it and get it.
BB
User avatar
haklesup
Posts: 3136
Joined: Thu Aug 01, 2002 1:01 am
Location: San Jose CA
Contact:

Re: Temperature readings into a PC?

Post by haklesup »

Many motherboards have one or two temperature sensors built right in and used to monitor HDD or CPU temp etc. It wouldn't be too hard to extend the wires on one of these sensors and put it outside the box.<p>The MB should have a utility for looking at the temp as well as other stats about the PC (fan speed, Voltages). My PC has a screen in BIOS and a GUI for windows. Some even include a program to log these events. Even if you don't have the program, you should be able to access the temp readings via a program written in your choice of C or VB.
greg123
Posts: 361
Joined: Sat Sep 07, 2002 1:01 am
Location: St. John's NFLD Canada
Contact:

Re: Temperature readings into a PC?

Post by greg123 »

The farenheight sensor is the LM34 and the celsius sensor is the LM35. These are linear, three terminal devices that output 10mV per degree celsius or degree farenheight. They both have a range of 180 steps, So full scale and at 10 mV is a full output voltage of 2.56 volts. <p>Vref/2 for the A/D should be 1.28V<p>Check the link i posted above. Page 5 of the document is about the temp sensors.<p>Like i mentioned, it is a three stage system. Temp sensor, A/D and buffer/line driver.<p>Not a hard system, with a breadboard and an hour it can be up and running.<p>g
greg123
Posts: 361
Joined: Sat Sep 07, 2002 1:01 am
Location: St. John's NFLD Canada
Contact:

Re: Temperature readings into a PC?

Post by greg123 »

If you would like a schematic, i can post one for you. I also have the parts but it seems VERY expensive to ship to where you are.<p>g
bodgy
Posts: 1044
Joined: Tue Dec 04, 2001 1:01 am
Location: Australia
Contact:

Re: Temperature readings into a PC?

Post by bodgy »

There is one part of the question that hasn't quite been discussed. how to transform the temperature reading read into the PC to a text file for reading by the cam software.<p>I don't have a definitive answer on this, but some ideas.<p>There are available on the web some Java applets that can be coded to do this sort of thing - look at the Dallas weather station site. Might even be worth searching the Parallax site as well.<p>One easy(ish) way would be to write a small program to read the incoming data and convert it to text, there should be stuff on the web with this especially in VB using the Dallas 1820 or 1620 parts.<p>Another is electronically have a uController take the sensor readings and then serially transmit the results after converting them to ASCII, then a terminal program (even hyperterminal) can read them in to a text file. In fact with VB extensions I know this can be done in Excel, I recall a short series of articles about using Excel in electronics and programming for this sort of thing, but not sure which magazine it was.<p>Colin
On a clear disk you can seek forever.
jimryannz
Posts: 4
Joined: Mon Apr 28, 2003 1:01 am
Location: New Zealand
Contact:

Re: Temperature readings into a PC?

Post by jimryannz »

Hey all you guys – thanks for your input on this one – but remember am not a techo and a lot of it does not mean too much!
If anyone wants to give me a price for putting something together – we may be able to give you citizenship to the village of Arrowtown - http://www.arrowtown.com/ New Zealand – well for a day or two anyway! And to pay for it.
greg123
Posts: 361
Joined: Sat Sep 07, 2002 1:01 am
Location: St. John's NFLD Canada
Contact:

Re: Temperature readings into a PC?

Post by greg123 »

Yeah Colin, thats where my Knowledge ends. I can get the data into the text file fine, but to place it into the camera shot..........<p> :mad: :confused:
jimryannz
Posts: 4
Joined: Mon Apr 28, 2003 1:01 am
Location: New Zealand
Contact:

Re: Temperature readings into a PC?

Post by jimryannz »

Greg - hi - you let me know how and what with to get the temperature into a text file - I can get it into the picture see live cam bottom left - http://homepages.ihug.co.nz/~jim.ryan/. Created a txt file with Notepad - entered 31.6 into the first line - bingo!
Will
Posts: 310
Joined: Tue Feb 11, 2003 1:01 am
Location: Katy Texas
Contact:

Re: Temperature readings into a PC?

Post by Will »

Greg/Stuffed,
I posted a reply yesterday but it didn't seem to take. Problem is that I have some difficulty reemembering as far back as yesterday but I think it went something like this - You can get, from ON Semiconductor (They were formerly a division of Motorola) an LM 75 which measures temperature in the range -55 to + 125 Deg C and hjas, among other things, an on board ADC and a nine bit serial digital output - nine bits is potentially 512 discrete states but, in this case, only 360 bits are used so that one bit represents 0.5 Deg C. The manufacturer accuracy is not this precise but the device can be calibrated. This probably infers measuring the outside temperature once the device is set up and then adjusting the output so that it reads correctly. Which also infers a program which would accomodate this. The device could both transmit into the PC RS 232 port and obtain it's power supply therefrom. I think it might even be possible to connect the device direct to the RS 232 port without an interface board but I'm not enough of an electronics man to determine that. The device is also digitally addressable and you can hang up to eight of them one one cable. I believe also that the Nat Semi LM 34 and 35 devices are also available with the ADC and nine bit output.
Couldn't we make a project out of this. I would like to see a program Preferably in Visual Basic which I would also like to be able to understand)
I already have an LM75 which I can send to anyone who can make a go of it. The spec sheets can be obtained from the ON Semiconductor web site and, presumably, also from the Nat Semi site.
BB
skrallman
Posts: 26
Joined: Tue Jan 07, 2003 1:01 am
Location: Coeur d'Alene, ID
Contact:

Re: Temperature readings into a PC?

Post by skrallman »

Stuffed,
You've already got alot of good info here, but you may want to check out this page DS1621 pc thermometer
Its a simple circuit, he gives you the software and it will log to a .txt file.
good luck
Scott
jimryannz
Posts: 4
Joined: Mon Apr 28, 2003 1:01 am
Location: New Zealand
Contact:

Re: Temperature readings into a PC?

Post by jimryannz »

Scottk - hey thanks for that - looks great - just wish could get as "plug'n play" though - anyone willing to build one for us?!
Many thanks
Post Reply

Who is online

Users browsing this forum: Ahrefs [Bot] and 30 guests