Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

PT100_Calibration Formula

Status
Not open for further replies.

ajit_nayak87

Member level 5
Member level 5
Joined
Oct 30, 2017
Messages
86
Helped
1
Reputation
2
Reaction score
1
Trophy points
8
Activity points
981
Dear all.

Here I am attaching output of ADC along with Input Given from calibrator for PT100. I am looking for Equation that can provide 0.1 degree accuracy .Can someone suggest me equation based on the input provided.


i thought of using slope and intercept equation . Kindly give me some suggestion


0 - 400 degree
Degree_conv= 0.22701475595913734 * Adc_value - 1817.7071509648126;

-200 degree to 0 degree

Degree_conv= 0.03067484662576687 * Adc_value - 245.61349693251535;

-200 degree to 400 degree

Degree_conv= 0.07244626901714561 * Adc_value - 307.72760202849554;


Let me know any better equation based on reading & suggestion any
 

Attachments

  • Pt100 Reading.txt
    2.1 KB · Views: 160

The equation tends to behave the more linear the smaller the range to be considered, as well as the more lying within the linear region the sensor is operating. By the way, there is no generic equation, instead, what you need to do is look for some online polynomial regression tool that will give you the corresponding function to those inserted values (e.g: https://www.xuru.org/rt/PR.asp). It is important to mention that for ALL sensors of the same batch, you will have to repeat the same procedure if you want to achieve the most optimized acuracy possible.
 

y = 7.801726852·10-3 x2 + 3.373669292 x + 4586.868125

I got equation from link you share. Weather this give good degree of resolution.
 

Here's an ADI application note discussing linearization methods for Pt100. https://www.analog.com/media/en/technical-documentation/application-notes/AN709_0.pdf

You'll surely need more segments in your piecewise linear interpolation to achieve 0.1 K accuracy. Why don't you try yourself with a spread sheet calculator?

- - - Updated - - -

As you'll find out second order polynomial is neither sufficient for 0.1K accuracy over the intended temperature range. Need at least third order. It's a valuable option if you are using float math in your application anyway, but as shown in in the application note, piecewise linear is better in most cases.
 

If i get more reading I could use second order or thrird order regression equation shared . then i could use it for further calaulation
 

Hi,

none of your formulae can be verified without a schematic.

Klaus
 

y = 7.801726852·10-3 x2 + 3.373669292 x + 4586.868125

I got equation from link you share. Weather this give good degree of resolution.

Aren't you even able to fill a spreadsheet with the difference of the calculated and the original values for some inferred functions, as for example with different polinomial degrees? The next step is to assess each one of the given options by yourself by checking which gives the smallest error. It is important to verify the existence of discrepant points due to measurement error, which could be manually removed or moved to closest of the average between neighbor points.
 

I have attached conversion code for reference.For lower temp input i get 1 degree accuacy as input goes beyond 200 degree get offset for -5 degree to -17 degree.
Can someone suggest improvise the calibration so to get better accuacy in result.
I found curve is linear and as per below formula i expected it to calculate result but why this offset?? how can improvise without adding correction factor??


Code:
unsigned int ProDegrs=0;
//signed long ProDegrs=0;
void CountsToDegree() 
{



if(ADCdisplay>=8006 || ADCdisplay<=9989 )
ProDegrs=0.0323*ADCdisplay-258.42; 
else

if(ADCdisplay>1080 ||ADCdisplay<2587)
ProDegrs=0.0332*ADCdisplay+64.053; 
else
if(ADCdisplay>2587&& ADCdisplay<4068)
ProDegrs=0.0338*ADCdisplay+62.567; 
else
ProDegrs=0.0345*ADCdisplay+59.235; 

/* if(ADCdisplay>1487 && ADCdisplay< 8006)
{
ProDegrs=0.0307*ADCdisplay-247.42; 
}*/


}


Code:
Calibration Input In 1		Results				
Calibration Input	ADCdisplay	Slope 	Intercept	Expected  Result	Disply reading	Error
1	8006	0.0323	-258.42	0.1738	1	0.8262
2	8069	0.0323	-258.42	2.2087	2	-0.2087
3	8101	0.0323	-258.42	3.2423		-3.2423
4	8131	0.0323	-258.42	4.2113		-4.2113
5	8163	0.0323	-258.42	5.2449		-5.2449
6	8195	0.0323	-258.42	6.2785		-6.2785
7	8225	0.0323	-258.42	7.2475		-7.2475
8	8256	0.0323	-258.42	8.2488		-8.2488
9	8288	0.0323	-258.42	9.2824		-9.2824
10	8319	0.0323	-258.42	10.2837	10	-0.2837
11	8350	0.0323	-258.42	11.285		-11.285
12	8382	0.0323	-258.42	12.3186		-12.3186
13	8412	0.0323	-258.42	13.2876		-13.2876
14	8444	0.0323	-258.42	14.3212		-14.3212
15	8475	0.0323	-258.42	15.3225		-15.3225
16	8506	0.0323	-258.42	16.3238		-16.3238
17	8537	0.0323	-258.42	17.3251		-17.3251
18	8568	0.0323	-258.42	18.3264		-18.3264
19	8599	0.0323	-258.42	19.3277		-19.3277
20	8631	0.0323	-258.42	20.3613	20	-0.3613
21	8661	0.0323	-258.42	21.3303		-21.3303
22	8692	0.0323	-258.42	22.3316		-22.3316
23	8723	0.0323	-258.42	23.3329		-23.3329
24	8755	0.0323	-258.42	24.3665		-24.3665
25	8786	0.0323	-258.42	25.3678		-25.3678
26	8817	0.0323	-258.42	26.3691		-26.3691
27	8848	0.0323	-258.42	27.3704		-27.3704
28	8878	0.0323	-258.42	28.3394		-28.3394
29	8909	0.0323	-258.42	29.3407		-29.3407
30	8941	0.0323	-258.42	30.3743	30	-0.3743
31	8971	0.0323	-258.42	31.3433		-31.3433
32	9003	0.0323	-258.42	32.3769		-32.3769
33	9034	0.0323	-258.42	33.3782		-33.3782
34	9065	0.0323	-258.42	34.3795		-34.3795
35	9095	0.0323	-258.42	35.3485		-35.3485
36	9126	0.0323	-258.42	36.3498		-36.3498
37	9157	0.0323	-258.42	37.3511		-37.3511
38	9188	0.0323	-258.42	38.3524		-38.3524
39	9219	0.0323	-258.42	39.3537		-39.3537
40	9250	0.0323	-258.42	40.355	40	-0.355
41	9281	0.0323	-258.42	41.3563		-41.3563
42	9311	0.0323	-258.42	42.3253		-42.3253
43	9343	0.0323	-258.42	43.3589		-43.3589
44	9373	0.0323	-258.42	44.3279		-44.3279
45	9404	0.0323	-258.42	45.3292		-45.3292
46	9435	0.0323	-258.42	46.3305		-46.3305
47	9466	0.0323	-258.42	47.3318		-47.3318
48	9497	0.0323	-258.42	48.3331		-48.3331
49	9527	0.0323	-258.42	49.3021		-49.3021
50	9526	0.0323	-258.42	49.2698	50	0.7302
51	9589	0.0323	-258.42	51.3047		-51.3047
52	9620	0.0323	-258.42	52.306		-52.306
53	9651	0.0323	-258.42	53.3073		-53.3073
54	9681	0.0323	-258.42	54.2763		-54.2763
55	9712	0.0323	-258.42	55.2776		-55.2776
56	9743	0.0323	-258.42	56.2789		-56.2789
57	9774	0.0323	-258.42	57.2802		-57.2802
58	9805	0.0323	-258.42	58.2815		-58.2815
59	9836	0.0323	-258.42	59.2828		-59.2828
60	9866	0.0323	-258.42	60.2518	60	-0.2518
61	9897	0.0323	-258.42	61.2531		-61.2531
62	9928	0.0323	-258.42	62.2544		-62.2544
63	9959	0.0323	-258.42	63.2557		-63.2557
64	9989	0.0323	-258.42	64.2247		-64.2247
65	20	0.0323	-258.42	-257.774		257.774
66	50	0.0323	-258.42	-256.805		256.805
67	81	0.0323	-258.42	-255.8037		255.8037
68	112	0.0323	-258.42	-254.8024		254.8024
69	135	0.0323	-258.42	-254.0595		254.0595
70	173	0.0323	-258.42	-252.8321	70	322.8321
71	203	0.0323	-258.42	-251.8631		251.8631
72	234	0.0323	-258.42	-250.8618		250.8618
73	265	0.0323	-258.42	-249.8605		249.8605
74	295	0.0323	-258.42	-248.8915		248.8915
75	326	0.0323	-258.42	-247.8902		247.8902
76	356	0.0323	-258.42	-246.9212		246.9212
77	387	0.0323	-258.42	-245.9199		245.9199
78	417	0.0323	-258.42	-244.9509		244.9509
79	448	0.0323	-258.42	-243.9496		243.9496
80	478	0.0323	-258.42	-242.9806	79	321.9806
81	509	0.0323	-258.42	-241.9793		241.9793
82	539	0.0323	-258.42	-241.0103		241.0103
83	570	0.0323	-258.42	-240.009		240.009
84	600	0.0323	-258.42	-239.04		239.04
85	631	0.0323	-258.42	-238.0387		238.0387
86	662	0.0323	-258.42	-237.0374		237.0374
87	691	0.0323	-258.42	-236.1007		236.1007
88	723	0.0323	-258.42	-235.0671		235.0671
89	753	0.0323	-258.42	-234.0981		234.0981
90	784	0.0323	-258.42	-233.0968	89	322.0968
91	814	0.0323	-258.42	-232.1278		232.1278
92	844	0.0323	-258.42	-231.1588		231.1588
93	874	0.0323	-258.42	-230.1898		230.1898
94	905	0.0323	-258.42	-229.1885		229.1885
95	936	0.0323	-258.42	-228.1872		228.1872
96	966	0.0323	-258.42	-227.2182		227.2182
97	990	0.0323	-258.42	-226.443		226.443
98	1020	0.0323	-258.42	-225.474		225.474
99	1050	0.0323	-258.42	-224.505		224.505
100	1080	0.0332	64.053	99.909	99	-0.909
101	1109	0.0332	64.053	100.8718		-100.8718
102	1141	0.0332	64.053	101.9342		-101.9342
103	1172	0.0332	64.053	102.9634		-102.9634
104	1203	0.0332	64.053	103.9926		-103.9926
105	1232	0.0332	64.053	104.9554		-104.9554
106	1263	0.0332	64.053	105.9846		-105.9846
107	1294	0.0332	64.053	107.0138		-107.0138
108	1324	0.0332	64.053	108.0098		-108.0098
109	1354	0.0332	64.053	109.0058		-109.0058
110	1384	0.0332	64.053	110.0018	109	-1.0018
111	1414	0.0332	64.053	110.9978		-110.9978
112	1444	0.0332	64.053	111.9938		-111.9938
113	1474	0.0332	64.053	112.9898		-112.9898
114	1504	0.0332	64.053	113.9858		-113.9858
115	1534	0.0332	64.053	114.9818		-114.9818
116	1564	0.0332	64.053	115.9778		-115.9778
117	1594	0.0332	64.053	116.9738		-116.9738
118	1624	0.0332	64.053	117.9698		-117.9698
119	1654	0.0332	64.053	118.9658		-118.9658
120	1687	0.0332	64.053	120.0614	119	-1.0614
121	1717	0.0332	64.053	121.0574		-121.0574
122	1747	0.0332	64.053	122.0534		-122.0534
123	1777	0.0332	64.053	123.0494		-123.0494
124	1807	0.0332	64.053	124.0454		-124.0454
125	1837	0.0332	64.053	125.0414		-125.0414
126	1867	0.0332	64.053	126.0374		-126.0374
127	1897	0.0332	64.053	127.0334		-127.0334
128	1927	0.0332	64.053	128.0294		-128.0294
129	1957	0.0332	64.053	129.0254		-129.0254
130	1987	0.0332	64.053	130.0214	128	-2.0214
131	2017	0.0332	64.053	131.0174		-131.0174
132	2047	0.0332	64.053	132.0134		-132.0134
133	2077	0.0332	64.053	133.0094		-133.0094
134	2107	0.0332	64.053	134.0054		-134.0054
135	2137	0.0332	64.053	135.0014		-135.0014
136	2167	0.0332	64.053	135.9974		-135.9974
137	2197	0.0332	64.053	136.9934		-136.9934
138	2227	0.0332	64.053	137.9894		-137.9894
139	2257	0.0332	64.053	138.9854		-138.9854
140	2288	0.0332	64.053	140.0146	138	-2.0146
141	2315	0.0332	64.053	140.911		-140.911
142	2345	0.0332	64.053	141.907		-141.907
143	2375	0.0332	64.053	142.903		-142.903
144	2405	0.0332	64.053	143.899		-143.899
145	2435	0.0332	64.053	144.895		-144.895
146	2465	0.0332	64.053	145.891		-145.891
147	2495	0.0332	64.053	146.887		-146.887
148	2525	0.0332	64.053	147.883		-147.883
149	2555	0.0332	64.053	148.879		-148.879
150	2585	0.0332	64.053	149.875	148	-1.875
151	2617	0.0338	62.567	151.0216		-151.0216
152	2647	0.0338	62.567	152.0356		-152.0356
153	2677	0.0338	62.567	153.0496		-153.0496
154	2706	0.0338	62.567	154.0298		-154.0298
155	2737	0.0338	62.567	155.0776		-155.0776
156	2767	0.0338	62.567	156.0916		-156.0916
157	2796	0.0338	62.567	157.0718		-157.0718
158	2826	0.0338	62.567	158.0858		-158.0858
159	2856	0.0338	62.567	159.0998		-159.0998
160	2886	0.0338	62.567	160.1138	157	-3.1138
161	2915	0.0338	62.567	161.094		-161.094
162	2946	0.0338	62.567	162.1418		-162.1418
163	2976	0.0338	62.567	163.1558		-163.1558
164	3005	0.0338	62.567	164.136		-164.136
165	3035	0.0338	62.567	165.15		-165.15
166	3064	0.0338	62.567	166.1302		-166.1302
167	3094	0.0338	62.567	167.1442		-167.1442
168	3123	0.0338	62.567	168.1244		-168.1244
169	3153	0.0338	62.567	169.1384		-169.1384
170	3183	0.0338	62.567	170.1524	167	-3.1524
171	3212	0.0338	62.567	171.1326		-171.1326
172	3241	0.0338	62.567	172.1128		-172.1128
173	3272	0.0338	62.567	173.1606		-173.1606
174	3301	0.0338	62.567	174.1408		-174.1408
175	3331	0.0338	62.567	175.1548		-175.1548
176	3361	0.0338	62.567	176.1688		-176.1688
177	3390	0.0338	62.567	177.149		-177.149
178	3420	0.0338	62.567	178.163		-178.163
179	3450	0.0338	62.567	179.177		-179.177
180	3479	0.0338	62.567	180.1572	177	-3.1572
181	3509	0.0338	62.567	181.1712		-181.1712
182	3539	0.0338	62.567	182.1852		-182.1852
183	3568	0.0338	62.567	183.1654		-183.1654
184	3598	0.0338	62.567	184.1794		-184.1794
185	3627	0.0338	62.567	185.1596		-185.1596
186	3656	0.0338	62.567	186.1398		-186.1398
187	3686	0.0338	62.567	187.1538		-187.1538
188	3715	0.0338	62.567	188.134		-188.134
189	3745	0.0338	62.567	189.148		-189.148
190	3775	0.0338	62.567	190.162	186	-4.162
191	3803	0.0338	62.567	191.1084		-191.1084
192	3833	0.0338	62.567	192.1224		-192.1224
193	3863	0.0338	62.567	193.1364		-193.1364
194	3892	0.0338	62.567	194.1166		-194.1166
195	3922	0.0338	62.567	195.1306		-195.1306
196	3951	0.0338	62.567	196.1108		-196.1108
197	3981	0.0338	62.567	197.1248		-197.1248
198	4010	0.0338	62.567	198.105		-198.105
199	4039	0.0338	62.567	199.0852		-199.0852
200	4068	0.0338	62.567	200.0654	196	-4.0654
201	4098	0.0345	59.235	200.616		-200.616
202	4127	0.0345	59.235	201.6165		-201.6165
203	4156	0.0345	59.235	202.617		-202.617
204	4185	0.0345	59.235	203.6175		-203.6175
205	4214	0.0345	59.235	204.618		-204.618
206	4243	0.0345	59.235	205.6185		-205.6185
207	4273	0.0345	59.235	206.6535		-206.6535
208	4302	0.0345	59.235	207.654		-207.654
209	4332	0.0345	59.235	208.689		-208.689
210	4362	0.0345	59.235	209.724	205	-4.724
211	4390	0.0345	59.235	210.69		-210.69
212	4420	0.0345	59.235	211.725		-211.725
213	4448	0.0345	59.235	212.691		-212.691
214	4478	0.0345	59.235	213.726		-213.726
215	4508	0.0345	59.235	214.761		-214.761
216	4537	0.0345	59.235	215.7615		-215.7615
217	4567	0.0345	59.235	216.7965		-216.7965
218	4596	0.0345	59.235	217.797		-217.797
219	4625	0.0345	59.235	218.7975		-218.7975
220	4655	0.0345	59.235	219.8325	214	-5.8325
221	4683	0.0345	59.235	220.7985		-220.7985
222	4713	0.0345	59.235	221.8335		-221.8335
223	4744	0.0345	59.235	222.903		-222.903
224	4771	0.0345	59.235	223.8345		-223.8345
225	4801	0.0345	59.235	224.8695		-224.8695
226	4830	0.0345	59.235	225.87		-225.87
227	4859	0.0345	59.235	226.8705		-226.8705
228	4889	0.0345	59.235	227.9055		-227.9055
229	4917	0.0345	59.235	228.8715		-228.8715
230	4946	0.0345	59.235	229.872	224	-5.872
231	4975	0.0345	59.235	230.8725		-230.8725
232	5004	0.0345	59.235	231.873		-231.873
233	5033	0.0345	59.235	232.8735		-232.8735
234	5062	0.0345	59.235	233.874		-233.874
235	5092	0.0345	59.235	234.909		-234.909
236	5121	0.0345	59.235	235.9095		-235.9095
237	5150	0.0345	59.235	236.91		-236.91
238	5179	0.0345	59.235	237.9105		-237.9105
239	5208	0.0345	59.235	238.911		-238.911
240	5237	0.0345	59.235	239.9115	233	-6.9115
241	5266	0.0345	59.235	240.912		-240.912
242	5295	0.0345	59.235	241.9125		-241.9125
243	5324	0.0345	59.235	242.913		-242.913
244	5354	0.0345	59.235	243.948		-243.948
245	5382	0.0345	59.235	244.914		-244.914
246	5411	0.0345	59.235	245.9145		-245.9145
247	5440	0.0345	59.235	246.915		-246.915
248	5470	0.0345	59.235	247.95		-247.95
249	5498	0.0345	59.235	248.916		-248.916
250	5528	0.0345	59.235	249.951	242	-7.951
251	5556	0.0345	59.235	250.917		-250.917
252	5585	0.0345	59.235	251.9175		-251.9175
253	5613	0.0345	59.235	252.8835		-252.8835
254	5643	0.0345	59.235	253.9185		-253.9185
255	5672	0.0345	59.235	254.919		-254.919
256	5702	0.0345	59.235	255.954		-255.954
257	5731	0.0345	59.235	256.9545		-256.9545
258	5760	0.0345	59.235	257.955		-257.955
259	5788	0.0345	59.235	258.921		-258.921
260	5816	0.0345	59.235	259.887	252	-7.887
261	5846	0.0345	59.235	260.922		-260.922
262	5875	0.0345	59.235	261.9225		-261.9225
263	5904	0.0345	59.235	262.923		-262.923
264	5932	0.0345	59.235	263.889		-263.889
265	5961	0.0345	59.235	264.8895		-264.8895
266	5990	0.0345	59.235	265.89		-265.89
267	6018	0.0345	59.235	266.856		-266.856
268	6046	0.0345	59.235	267.822		-267.822
269	6075	0.0345	59.235	268.8225		-268.8225
270	6104	0.0345	59.235	269.823	261	-8.823
271	6133	0.0345	59.235	270.8235		-270.8235
272	6162	0.0345	59.235	271.824		-271.824
273	6191	0.0345	59.235	272.8245		-272.8245
274	6219	0.0345	59.235	273.7905		-273.7905
275	6248	0.0345	59.235	274.791		-274.791
276	6277	0.0345	59.235	275.7915		-275.7915
277	6305	0.0345	59.235	276.7575		-276.7575
278	6334	0.0345	59.235	277.758		-277.758
279	6363	0.0345	59.235	278.7585		-278.7585
280	6391	0.0345	59.235	279.7245	270	-9.7245
281	6420	0.0345	59.235	280.725		-280.725
282	6447	0.0345	59.235	281.6565		-281.6565
283	6476	0.0345	59.235	282.657		-282.657
284	6506	0.0345	59.235	283.692		-283.692
285	6534	0.0345	59.235	284.658		-284.658
286	6564	0.0345	59.235	285.693		-285.693
287	6591	0.0345	59.235	286.6245		-286.6245
288	6620	0.0345	59.235	287.625		-287.625
289	6649	0.0345	59.235	288.6255		-288.6255
290	6678	0.0345	59.235	289.626	279	-10.626
291	6706	0.0345	59.235	290.592		-290.592
292	6735	0.0345	59.235	291.5925		-291.5925
293	6764	0.0345	59.235	292.593		-292.593
294	6792	0.0345	59.235	293.559		-293.559
295	6821	0.0345	59.235	294.5595		-294.5595
296	6848	0.0345	59.235	295.491		-295.491
297	6877	0.0345	59.235	296.4915		-296.4915
298	6906	0.0345	59.235	297.492		-297.492
299	6935	0.0345	59.235	298.4925		-298.4925
300	6962	0.0345	59.235	299.424	289	-10.424
301	6990	0.0345	59.235	300.39		-300.39
302	7020	0.0345	59.235	301.425		-301.425
303	7047	0.0345	59.235	302.3565		-302.3565
304	7076	0.0345	59.235	303.357		-303.357
305	7104	0.0345	59.235	304.323		-304.323
306	7133	0.0345	59.235	305.3235		-305.3235
307	7162	0.0345	59.235	306.324		-306.324
308	7189	0.0345	59.235	307.2555		-307.2555
309	7219	0.0345	59.235	308.2905		-308.2905
310	7248	0.0345	59.235	309.291	298	-11.291
311	7275	0.0345	59.235	310.2225		-310.2225
312	7304	0.0345	59.235	311.223		-311.223
313	7332	0.0345	59.235	312.189		-312.189
314	7361	0.0345	59.235	313.1895		-313.1895
315	7389	0.0345	59.235	314.1555		-314.1555
316	7418	0.0345	59.235	315.156		-315.156
317	7445	0.0345	59.235	316.0875		-316.0875
318	7475	0.0345	59.235	317.1225		-317.1225
319	7502	0.0345	59.235	318.054		-318.054
320	7531	0.0345	59.235	319.0545	305	-14.0545
321	7559	0.0345	59.235	320.0205		-320.0205
322	7588	0.0345	59.235	321.021		-321.021
323	7615	0.0345	59.235	321.9525		-321.9525
324	7645	0.0345	59.235	322.9875		-322.9875
325	7672	0.0345	59.235	323.919		-323.919
326	7701	0.0345	59.235	324.9195		-324.9195
327	7729	0.0345	59.235	325.8855		-325.8855
328	7758	0.0345	59.235	326.886		-326.886
329	7786	0.0345	59.235	327.852		-327.852
330	7814	0.0345	59.235	328.818	316	-12.818
331	7842	0.0345	59.235	329.784		-329.784
332	7870	0.0345	59.235	330.75		-330.75
333	7898	0.0345	59.235	331.716		-331.716
334	7926	0.0345	59.235	332.682		-332.682
335	7954	0.0345	59.235	333.648		-333.648
336	7982	0.0345	59.235	334.614		-334.614
337	8011	0.0345	59.235	335.6145		-335.6145
338	8039	0.0345	59.235	336.5805		-336.5805
339	8068	0.0345	59.235	337.581		-337.581
340	8096	0.0345	59.235	338.547	325	-13.547
341	8125	0.0345	59.235	339.5475		-339.5475
342	8152	0.0345	59.235	340.479		-340.479
343	8181	0.0345	59.235	341.4795		-341.4795
344	8208	0.0345	59.235	342.411		-342.411
345	8236	0.0345	59.235	343.377		-343.377
346	8264	0.0345	59.235	344.343		-344.343
347	8292	0.0345	59.235	345.309		-345.309
348	8320	0.0345	59.235	346.275		-346.275
349	8348	0.0345	59.235	347.241		-347.241
350	8376	0.0345	59.235	348.207	334	-14.207
351	8404	0.0345	59.235	349.173		-349.173
352	8432	0.0345	59.235	350.139		-350.139
353	8459	0.0345	59.235	351.0705		-351.0705
354	8488	0.0345	59.235	352.071		-352.071
355	8515	0.0345	59.235	353.0025		-353.0025
356	8543	0.0345	59.235	353.9685		-353.9685
357	8571	0.0345	59.235	354.9345		-354.9345
358	8599	0.0345	59.235	355.9005		-355.9005
359	8627	0.0345	59.235	356.8665		-356.8665
360	8654	0.0345	59.235	357.798	343	-14.798
361	8682	0.0345	59.235	358.764		-358.764
362	8710	0.0345	59.235	359.73		-359.73
363	8738	0.0345	59.235	360.696		-360.696
364	8766	0.0345	59.235	361.662		-361.662
365	8794	0.0345	59.235	362.628		-362.628
366	8823	0.0345	59.235	363.6285		-363.6285
367	8850	0.0345	59.235	364.56		-364.56
368	8879	0.0345	59.235	365.5605		-365.5605
369	8906	0.0345	59.235	366.492		-366.492
370	8934	0.0345	59.235	367.458	352	-15.458
371	8961	0.0345	59.235	368.3895		-368.3895
372	8989	0.0345	59.235	369.3555		-369.3555
373	9016	0.0345	59.235	370.287		-370.287
374	9045	0.0345	59.235	371.2875		-371.2875
375	9072	0.0345	59.235	372.219		-372.219
376	9100	0.0345	59.235	373.185		-373.185
377	9128	0.0345	59.235	374.151		-374.151
378	9155	0.0345	59.235	375.0825		-375.0825
379	9183	0.0345	59.235	376.0485		-376.0485
380	9211	0.0345	59.235	377.0145	361	-16.0145
381	9239	0.0345	59.235	377.9805		-377.9805
382	9266	0.0345	59.235	378.912		-378.912
383	9294	0.0345	59.235	379.878		-379.878
384	9322	0.0345	59.235	380.844		-380.844
385	9350	0.0345	59.235	381.81		-381.81
386	9377	0.0345	59.235	382.7415		-382.7415
387	9405	0.0345	59.235	383.7075		-383.7075
388	9432	0.0345	59.235	384.639		-384.639
389	9459	0.0345	59.235	385.5705		-385.5705
390	9488	0.0345	59.235	386.571	370	-16.571
391	9514	0.0345	59.235	387.468		-387.468
392	9543	0.0345	59.235	388.4685		-388.4685
393	9570	0.0345	59.235	389.4		-389.4
394	9598	0.0345	59.235	390.366		-390.366
395	9626	0.0345	59.235	391.332		-391.332
396	9655	0.0345	59.235	392.3325		-392.3325
397	9681	0.0345	59.235	393.2295		-393.2295
398	9710	0.0345	59.235	394.23		-394.23
399	9736	0.0345	59.235	395.127		-395.127
400	9763	0.0345	59.235	396.0585	379	-17.0585
401	9791	0.0345	59.235	397.0245	380	-17.0245
402	9819	0.0345	59.235	397.9905	381	-16.9905
403	9847	0.0345	59.235	398.9565	382	-16.9565
404	9875	0.0345	59.235	399.9225	383	-16.9225
405	9901	0.0345	59.235	400.8195	384	-16.8195
406	9930	0.0345	59.235	401.82	384	-17.82
407	9957	0.0345	59.235	402.7515	385	-17.7515
408	9985	0.0345	59.235	403.7175	386	-17.7175
 

Attachments

  • PT100.pdf
    29.2 KB · Views: 187
  • Degree_1.pdf
    55.2 KB · Views: 157

I have changed my code bit. I used get better accuracy for positive temp value.

Now i am trying to implement same for negative temperature reading .

I have attached output display for below reading. How can make it to display -100 input -100 only.

I tried changing unsigned to signed in display the same


-100 degree input -> display show -437
-90degree input -> display show -447
-80degree input -> display show -457

Code:
unsigned int ProDegrs=0;

void Degree_cov()
{
   if( ADCdisplay>=8000 && ADCdisplay<=9989)
            {
             ProDegrs=0.0323*ADCdisplay-258.32; Minus=0;
            }
        else
            if(ADCdisplay>=18654)
            {
                   ProDegrs= 0.0361*ADCdisplay- 313.51; Minus=0;
            }
            else if(ADCdisplay>9989 &&ADCdisplay<11080) 
            {
                    ProDegrs= 0.0329*ADCdisplay- 264.42; Minus=0;
            } else if(ADCdisplay>4664 &&ADCdisplay<7999)
                  {
                      // LEDBuffer[3] =  DISPTABLE[14];
                      Minus=1;
                      ProDegrs=0.0313*ADCdisplay-251.09;
                     
                  }
                  else 
                  {
                    ProDegrs=0.0344*ADCdisplay-282.66;Minus=0;   
                  }


}
 

Attachments

  • Neg_reading.pdf
    29.8 KB · Views: 163

when i change code with below line . how can i calibrate negative value get appropriate reading

if(ADCdisplay>4664 &&ADCdisplay<7999)
{
// LEDBuffer[3] = DISPTABLE[14];
Minus=1;
ProDegrs=(0.0313*ADCdisplay-251.09)+202;

}

Input Output
-100 -100
-90 -112
-80 -122
-70 -132
-60 -142
-50 -152
-40 -162
-30 -172
-20 -182
-10 -192
 

Just pasting here the code is useless unless you tell precisely what polynomial equation you are trying to implement. By the way, this latest version of the code has little resemblance to the one originally posted before.
 

here is my code for calibration. I am using slope and intercept equation for calculation. I have attached adc display and reading in previous pdf file. I am getting proper output from input given from calibrator. Now i am trying for negetive part

the reading between ADCdisplay>4664 &&ADCdisplay<7999 check -100 to 0 degree value. but if i give input i am getting offset as mentioned

How can i get proper value . variable declarion are mentioned in previous thread


Input_calibrator Output_display
-100 -100
-90 -112
-80 -122
-70 -132
-60 -142
-50 -152
-40 -162
-30 -172
-20 -182
-10 -192

Code:
unsigned int ProDegrs=0;

void Degree_cov()
{
   if( ADCdisplay>=8000 && ADCdisplay<=9989)
            {
             ProDegrs=0.0323*ADCdisplay-258.32; Minus=0;
            }
        else
            if(ADCdisplay>=18654)
            {
                   ProDegrs= 0.0361*ADCdisplay- 313.51; Minus=0;
            }
            else if(ADCdisplay>9989 &&ADCdisplay<11080) 
            {
                    ProDegrs= 0.0329*ADCdisplay- 264.42; Minus=0;
            } else if(ADCdisplay>4664 &&ADCdisplay<7999)
                  {
                      // LEDBuffer[3] =  DISPTABLE[14];
                      Minus=1;
                      ProDegrs=0.0313*ADCdisplay-251.09;
                     
                  }
                  else 
                  {
                    ProDegrs=0.0344*ADCdisplay-282.66;Minus=0;   
                  }


}
 

If I calibrate PT1000 sensors using two points i.e., boiling water and ice, which gives me ADC values at 100 C and at 0 C. If I use this linearity curve from the two points then by extending the curve at -150 C how much PT1000 will be off in degree C ? Accuracy of 1 degree centigrade is is totally fine at -150 C in my application.
 

Hi,

The hardware, the circuit and the calculation needs to ensure to give true, linear resistance values.
This is the most important...

Klaus
 

what about if readout electronics stay outside the temperature chamber at room temperature then I guess it's just reading analog signal and the dynamic range of ADC
 

If I calibrate PT1000 sensors using two points i.e., boiling water and ice, which gives me ADC values at 100 C and at 0 C. If I use this linearity curve from the two points then by extending the curve at -150 C how much PT1000 will be off in degree C ? Accuracy of 1 degree centigrade is is totally fine at -150 C in my application.
You have asked effectively the same question before https://www.edaboard.com/showthread.php?377694-Linearity-of-PT1000-at-negative-temperature

You also posted Pt1000 resistance table in a previous thread, a hand calculation indicates an error > 5 K when extrapolating 0/100 °C line to -150 °C

what about if readout electronics stay outside the temperature chamber at room temperature then I guess it's just reading analog signal and the dynamic range of ADC
Yes.
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top