PT100: 0-5V analog signal with 10bit resolution over 30m (100ft) distance  - Page 1
Forum section: electronics / beginners

author: DefekC
author_rank: Contributor
timestamp: November 04, 2013, 01:48:25 pm
content: Hi,This is my first post and I am ready to accept even the most severe criticism.I will try to explainproblemas short as possible...This project will be my first "real" project(like a step out of "blinking LEDs" to next level of education).Project in general is quite simple: there aretwo independent heating systemsjoined into one -pellet furnace and solar (heat) collector(actually three of them). At this point thissystem is managed manually, a.k.a. by hand both furnace and solar collector(s). System also has one water pump (0.1kW single-phase induction motor).Mechanically system is ready. What has to be done is:1) valves (5 of them) that control water flow have to be changed to solenoid valves;2) motor commutation have to be changed from circuit beaker to contactor;3) temperature sensors (6 of them) has to be deployed all over the system:• 3 on solar panels;• 1 at the outlet of furnace;• 1 in hot water boiler;• 1 in one (metric) ton water buffer to store excess energy;4) all have to be driven by µC with user-friendly interface.SYSTEM REQUIREMENTS:1)temperature resolution:0.5°Cat worse case scenario;2)temperature readings:slow... like, very slow ... likeonce 30 secondswould be fine;3)temperature range:from+10°C to +70°C with good precision, butfull rangeshould befrom -1°C to +85°C;4)measurement distance:up to(about)30m(100ft);5)working conditions:while µC will be safe and sound, sensors that measure temperature,should be able to withstand temperature rangefrom -30°C to +250°C submersed under max pressure of 15 bar.... this is where PT100 comes into play;Tools I figured I might use:1) µC in use:ATmega164A-PUorATmega164PA-PU(first one simply because it has more features to play with)2) platinum PT100 sensors3) JN12864J 128x64 pixel panel for GUI(ueses ST7920 controller)This is short story of what I want to do.Here comes question part:Question #1:How to read temperature from PT100?How to get out most of it (in means of precision)?Most probably there are going to be some people screaming behind the screen, like "Google it, God d**m it!", but this is a question Google could not answer me...I have seen several solutions, starting from 2 op-amps (one for constant 1mA current source, other for amplifying signal) ending with instrumental amplifiers in combination with analog switches for multiplexing several PT100s to sigma-delta 24bit ADC.Though three things I understood:1) I don't need (nor want) external ADC, I want to try get along with in-built 10bit ADC in ATmegaIF it is possiblewith requirements I gave;(Of course, if it is necessary, I am ready to use external ADC.)2) 4-wire solution - got it!3) self-heating in not going to be an issue as PT100s will be either cooled or heated by constant water flow, or it will have to detect quite high temperatures where self-heating will be irrelevant.Question #2:What is the best way to transmit one analog signal (value) in house from multiple places?Trouble is there are going to be (at least) 6 sensors measuring temperature all around the house. If You think about it, this is 4 wire cable all over the place. If not esthetics's, such amount of wire will cost more than everything else together! Doesn't sound pleasant... but if there is no other solutions, I will go with that!Then i noticed this little guy:nRF24L01.Is this plausible solution?Question #3:... not really question, but ...Any suggestions?Maybe I am missing something from picture I should see?__________________________________________Little background here: I am a master's student of industrial automation, so I have a quite strong background of C/C++ programing, power electronics (by that I meant that I understand difference between 5VDC and 230VAC) blah, blah, blah... If You feel that it is easier for You to use very complicated technical language - go for it, I will get it! Simply (as Dave once mentioned) although I have theoretical background of what I am asking here, "university doesn't teach You a lot about what You really need to know". Well, they taught me how to program PLC's (like, Siemens, ABB or funky Unitronics), but they missed out the most interesting stuff - µCs & µelectronics!

author: Kjelt
author_rank: Super Contributor
timestamp: November 04, 2013, 02:03:20 pm
content: First things that come to mind:QuoteTo make them digital and transmit them digitally, with that kinds of distances I would think of RS485 and use drivers with good ESD protection not the cheap ones.QuoteYou should use wire that is used in millions of km's every year, that is what it makes cheap, and that is 8 wire CAT5 cable.You can then even put two units on the same wire if you like. Just be sure to mark the cable differently so not to confuse the IT peopleQuoteGoing wireless can be option but I would not recommend it for critical systems. You're entire control system depends on the temperature readings, if you have interference from Wifi or other outside sources you have no temperature readings, then what you do, shut down? How many times a month is it allowed to be shutdown due to malfunction/interference before the customer will get sick of it?

author: yogece
author_rank: Contributor
timestamp: November 04, 2013, 02:33:43 pm
content: why do you want 30m distance sensor you could use ultrasonic for that.(do you want to measure the occupancy level of something inside furnace or?)

author: DefekC
author_rank: Contributor
timestamp: November 04, 2013, 03:29:43 pm
content: Quote from: Kjelt on November 04, 2013, 02:03:20 pmI was also considering this. I wanted for someone to comment on positive and negative aspects of both methods.As far as I have read, both methods are valid... I just don't see which one is the best in this case (as I don't have any work experience in either of both).Quote from: Kjelt on November 04, 2013, 02:03:20 pmTemporary signal loss is totally acceptable. As long as signal is established once 30 seconds to 300 seconds (5 min), it is fine. System itself is very inertial and slow, and it will not change its state fast.Long term signal loss is not really critical. System can be set to state where it functions even without any feedback whatsoever, and it will not fail (a.k.a. nothing is going to blow up if I don't receive data).The most critical temperature measurement (from furnace) will be very close to µC (like, next to it), so critical failure point is handled that way.Quote from: yogece on November 04, 2013, 02:33:43 pmOnly thing I am going to measure is temperature with PT100.If we talk about furnace, then I am particularly interested in incoming (back-loop) water temperature, that is coming from radiators. By knowing this number, I can very easy understand (thus calculate) necessary heat to keep house up to a certain temperature.P.S. - furnace gives me several signals that I can use, like condition (working/idle), temperature on outlet pipe (heat to house/boiler), pallet feeder status (working/idle) ... and so on.My main problem here is PT100!

author: Kjelt
author_rank: Super Contributor
timestamp: November 04, 2013, 03:55:01 pm
content: Quote from: DefekC on November 04, 2013, 03:29:43 pmWell:1) your uC wants to have the value digital anyway for its control loop.2) digital transmission through RS485 does not deteriorate over 30meters (even 250meters) nor is it susceptible to interference since it is differential. An analogue voltage over 30meters can be done also but you have to calculate the cable(losses) in your design, design against interference (high voltages) which makes it IMO more difficult. If I look in the industry applications in general I don't see these solutions, all work with digital transmission.3) with RS485 you need only one cable from your main control point to all other devices, with analogue you need one cable per device to the control point so you get a kind of starconnection.

author: yogece
author_rank: Contributor
timestamp: November 04, 2013, 03:59:37 pm
content: if you dont like to use RS-485 for interfacing PT-100 with ADC you could use current loop(4-20mA transmitter and reciever)

author: fcb
author_rank: Super Contributor
timestamp: November 04, 2013, 04:08:13 pm
content: Use 4-20ma interface and buy a PT100>4-20mA converter for £10

author: alxnik
author_rank: Regular Contributor
timestamp: November 04, 2013, 04:18:54 pm
content: The most commonly found sensor interfaces in industrial settings are 4-20mA current loops as yogece & fcb said. 4-20mA is used for actual sensing and 0-4mA for error states. I am pretty sure that there are already transmitters in the market that work like this and in practice, the receiver is an ADC which measures voltage drop over a resistor. I've seen installations with 4-20 which span over 100m so this is applicable for sure.For a bit more upmarket, there is rs485 which I have used for distances over 200m and if you install it correctly - proper termination, cabling etc - you can reach in the km ranges. Naturally you need more complicated equipment on the sensor side. The good thing about rs485 is that you can install in a bus or ring topology so you have less cabling.Practically you can install a micro on each sensor and put an rs485 transceiver chip on the UARTs.Most commonly found wireless installations for sensors are zigbee I think, so the most hobbyist friendly must be the xbee products. Have never used them though.No matter what, _DON'T_ try to read voltage over any length over half a meter, it's a lost cause.Considering the ADC. The embedded ones have absolutely terrible accuracy. Check this:http://www.djerickson.com/arduino/which has a very good analysis of the ADCs in the ATMegas used in arduinos. If you don't want to mess around with calibration or better accuracy discrete ADCs, I would suggest that you find some integrated temperature sensors which output rs485 (or ethernet...) and be done with it.

author: pinkysbrein
author_rank: Contributor
timestamp: November 04, 2013, 04:34:00 pm
content: If you don't want to run wires I'd consider powerline communication before wireless.

author: dfmischler
author_rank: Frequent Contributor
timestamp: November 04, 2013, 05:00:26 pm
content: I know you said 250 C at 15 bar (why?), but if you could live with a temperature sensor range of -55 to 125 C then you could go with1-wire. TheDS18B20sensors would talk directly on the 1-wire bus. I've potted these into copper aquastat wells and stainless probes for use in boilers, soil, etc. I have usedDS2406for discrete logic outputs that can operate anOpto-22 OAC5(or operate a relay through an appropriate driver, etc.). I believe there is a higher integration part for discrete I/O,DS2408, but I have not used this part.

author: DefekC
author_rank: Contributor
timestamp: November 04, 2013, 05:12:25 pm
content: Quote from: dfmischler on November 04, 2013, 05:00:26 pmThese are extremes thattemperature probemight experience during its lifetime and should not give up withing these conditions (although readings at this point would be irrelevant).Okay, You convinced me of two things:1) use digital data transmission, and let it be in wire, soRS485it shall be;2)external ADCis required.... okay, I'll think about several things and will be back with questions when they appear.Thanks for advice everyone for now!

author: DefekC
author_rank: Contributor
timestamp: November 04, 2013, 07:02:08 pm
content: Okay, this sounds interesting...I'll see what I can find about it!Thanks, Pippy!

author: ejeffrey
author_rank: Super Contributor
timestamp: November 04, 2013, 07:28:43 pm
content: While digital transmission is fine, your requirements are not very strict. It would be no problem to measure a Pt100 with 0.5 C accuracy over a 30 meter cable as long as you use 3- or 4- wire measurement, especially as your measurement interval is so slow. This is commonly done in industrial settings when the sensor needs to be exposed to much harsher conditions than the electronics are happy with. You do actually need to pay attention to signal conditioning when you do this, you can't just hook it up directly to a microcontroller input.Another option that is really simple and easy is the AD592. It doesn't have nearly as wide an operating temperature range as a Pt100 or thermocouple (which really shine when you need to measure high temperatures), but it is dead simple to use and only takes two wires.As I said, digital is a fine option as well -- if that suits you, go ahead. Also, if you are doing digital, this is the sort of situation that X10 and UPB are designed for. As long as each node is near a power outlet, that may be the most convenient way to do the communication. You will have to verify that all the outlets are on the same distribution phase or use a bridging capacitor to conduct the signal between them.

author: chibiace
author_rank: Regular Contributor
timestamp: November 04, 2013, 10:34:36 pm
content: go with 4-20ma current loop transmitters

author: dfmischler
author_rank: Frequent Contributor
timestamp: November 05, 2013, 10:42:07 am
content: Quote from: DefekC on November 04, 2013, 05:12:25 pmIt's not clear where you are, but around here safety pressure release valves for hydronic heating systems pop off by around 30 psi (about 2 bar). Checking yourfriendly steam tableyou will note that the temperature of steam at 2 bar is around 133C (more than 125, but nowhere near 250C).

author: DaveW
author_rank: Frequent Contributor
timestamp: November 06, 2013, 08:25:59 am
content: This might be a bit late, but for the temperature sensors I would recommend using AD590 sensors. About 40 years old but fantastic performance and they have a current based output so can be run over long distances easily-a friend of mine has them run over (disused) mains wiring in his house. The output can be converted into a voltage with a single op-amp and can make the required accuracy fairly easily

author: ddavidebor
author_rank: Super Contributor
timestamp: November 06, 2013, 04:50:08 pm
content: just use and industrial 4-20mA sensor