Hi, Mel
Happy to read from you !!!
Of course, those sensors exist ... ( you have forgotten to give us the price ... lol ), but are totally out of our Hobbiysts galaxy ...
Have a Happy new Year
Regards
Alain
Hi, Mel
Happy to read from you !!!
Of course, those sensors exist ... ( you have forgotten to give us the price ... lol ), but are totally out of our Hobbiysts galaxy ...
Have a Happy new Year
Regards
Alain
************************************************** ***********************
Why insist on using 32 Bits when you're not even able to deal with the first 8 ones ??? ehhhhhh ...
************************************************** ***********************
IF there is the word "Problem" in your question ...
certainly the answer is " RTFM " or " RTFDataSheet " !!!
*****************************************
Happy New Year to you and everyone too...
Aa a rough guide about 25 Euro's in singles, falling to below about 18 Euro's at 100 pcs, and about 10 Euro's at 1000 pcs.
Yes of course, you can't beat the few cents a DS1820 costs, but then it's not a bare chip, but a fully enclosed product with attached leads and connectors, post sensor processor, integral noise immunity, etc etc with integral seals all ready to bolt straight into your pipework or manifold.
If you want cheap, then just use an NTC Thermistor and plot it's curve into a PIC. You can easilly get better than 0.1C accuracy through simple interpolation across 90% of the curve. It's the way it's done in 99.9% of the cheaper Industrial and domestic Controls. I really don't see the point of DS1820's, LM35's etc, they're a waste of money for something that can be done so much simpler if only folks stopped and thought about the problem. OK, if you've only got a single I/O and a dozen items on the interconnecting bus, then fine, but otherwise why?
Ok, Mel
You're talking resolution while I'm talking accuracy ...
DS already give .0625°C resolution ... but that do not mean anything because you only know you are inside the +/- 0.5 °C error gap.
LM 335 have your ADC resolution ... but always an "out of the box" +/- 0.5 °C precision
That is why I say ( and repeat ... ) you can't get a better reading WITHOUT a calibration ... or comparison with a known reference.
Even the MS5534 ( 16 bits! ) which comes with its calibration coeffs ... is given for a GUARANTEED +/- .8°C accuracy ...
For NTC's the problem is the +/- 5 to 20% value tolerance ... that need an individual curve adjustment to each sensor ( only 1 point ... yes... but one point calibration ! )
The only **predictable** High accuracy sensors are Platinium RTD's ... But , ... How much to pay for a class A probe ??? ...
Temp and Thermal measurements are always funny ... and make you humble !!!
Alain
************************************************** ***********************
Why insist on using 32 Bits when you're not even able to deal with the first 8 ones ??? ehhhhhh ...
************************************************** ***********************
IF there is the word "Problem" in your question ...
certainly the answer is " RTFM " or " RTFDataSheet " !!!
*****************************************
Thank you for replays !!!
I wish to all a happy NEW YEAR 2009 !
I think I go crazzy with this little thermostat probleme ; I write ( based on Yours great codes) four routines ; everyone display a different temperature. Which of them is -in yours opinion - the best ?
1.OWOut DQ, 1, [$CC, $BE]
OWIn DQ, 2, [Temperature.Lowbyte, Temperature.Highbyte]
Convert_Temp:
Dummy = 625 * Temperature
TempC = DIV32 10
TempC = (Temperature & $7FF) >> 4
Float = ((Temperature.Lowbyte & $0F ) * 25 )>>2
Temperature = TempC*100 + Float
2.OWOut DQ, 1, [$CC, $BE]
OWIn DQ, 2, [RAWTEMP.Lowbyte, RAWTEMP.Highbyte]
Convert_Temp:
dummy = RAWTEMP * 625
TempC = DIV32 100
Temperature = TempC
3.OWOut DQ, 1, [$CC, $BE]
OWIn DQ, 2, [Temperature.Lowbyte, Temperature.Highbyte]
Convert_Temp:
TempC = (Temperature & $7FF) >> 4
Float = ((Temperature.Lowbyte & $0F ) * 25 )>>2
Temperature = TempC*100 + Float
4.OWOut DQ, 1, [$CC, $BE]
OWIn DQ, 0, [Temperature.LowByte, Temperature.HighByte, Skip 4, Count_Remain, Count_Per_C]
Convert_Temp :
Temperature = (((Temperature >> 1) * 100) - 25) + (((Count_Per_C - Count_Remain) * 100) / Count_Per_C)
if Temperature > 32767 then '32767 check if BIT12=1
Temperature= ~Temperature
temperature=temperature>>3 ; divide by 8
Thanks in advance for your support ; I hope I don't became boring !!!!
Hi, Fratello
Too wide a question ... It's on your own now.
Here it's yours to take :
1) your Datasheets, and do not mix different sensors ( ! ), see how values are coded for each.
2) your PbP Manual, and look at how PbP can calculate and see where roundings can lead to ( small ...) outputted value differences.
...
Alain
************************************************** ***********************
Why insist on using 32 Bits when you're not even able to deal with the first 8 ones ??? ehhhhhh ...
************************************************** ***********************
IF there is the word "Problem" in your question ...
certainly the answer is " RTFM " or " RTFDataSheet " !!!
*****************************************
I use the same sensor, the same circuit, just I re-write the code...the results are never the same...![]()
I intend to start tomorrow with the same project, using the same sensor DS18S20. May i use it without changing the code?
Bookmarks