RTD(PT100)测量演示
RTD电阻转换成对应温度的代码,支持-200~+850摄氏度//RTD分度表,1 degree Celsius (-200C to +850C)
//单位ohm
const double RTD_Table[] = {
18.52 , 18.952 , 19.384 , 19.815 , 20.247 , 20.677 , 21.108 , 21.538 , 21.967 , 22.397 ,
22.825 , 23.254 , 23.682 , 24.11 , 24.538 , 24.965 , 25.392 , 25.819 , 26.245 , 26.671 ,
27.096 , 27.522 , 27.947 , 28.371 , 28.796 , 29.22 , 29.643 , 30.067 , 30.49 , 30.913 ,
31.335 , 31.757 , 32.179 , 32.601 , 33.022 , 33.443 , 33.864 , 34.284 , 34.704 , 35.124 ,
35.543 , 35.963 , 36.382 , 36.8 , 37.219 , 37.637 , 38.055 , 38.472 , 38.889 , 39.306 ,
39.723 , 40.14 , 40.556 , 40.972 , 41.388 , 41.803 , 42.218 , 42.633 , 43.048 , 43.462 ,
43.876 , 44.29 , 44.704 , 45.117 , 45.531 , 45.944 , 46.356 , 46.769 , 47.181 , 47.593 ,
48.005 , 48.416 , 48.828 , 49.239 , 49.649 , 50.06 , 50.47 , 50.881 , 51.291 , 51.7 ,
52.11 , 52.519 , 52.928 , 53.337 , 53.746 , 54.154 , 54.562 , 54.97 , 55.378 , 55.786 ,
56.193 , 56.6 , 57.007 , 57.414 , 57.821 , 58.227 , 58.633 , 59.039 , 59.445 , 59.85 ,
60.256 , 60.661 , 61.066 , 61.471 , 61.876 , 62.28 , 62.684 , 63.088 , 63.492 , 63.896 ,
64.3 , 64.703 , 65.106 , 65.509 , 65.912 , 66.315 , 66.717 , 67.12 , 67.522 , 67.924 ,
68.325 , 68.727 , 69.129 , 69.53 , 69.931 , 70.332 , 70.733 , 71.134 , 71.534 , 71.934 ,
72.335 , 72.735 , 73.134 , 73.534 , 73.934 , 74.333 , 74.732 , 75.131 , 75.53 , 75.929 ,
76.328 , 76.726 , 77.125 , 77.523 , 77.921 , 78.319 , 78.717 , 79.114 , 79.512 , 79.909 ,
80.306 , 80.703 , 81.1 , 81.497 , 81.894 , 82.29 , 82.687 , 83.083 , 83.479 , 83.875 ,
84.271 , 84.666 , 85.062 , 85.457 , 85.853 , 86.248 , 86.643 , 87.038 , 87.432 , 87.827 ,
88.222 , 88.616 , 89.01 , 89.404 , 89.798 , 90.192 , 90.586 , 90.98 , 91.373 , 91.767 ,
92.16 , 92.553 , 92.946 , 93.339 , 93.732 , 94.124 , 94.517 , 94.909 , 95.302 , 95.694 ,
96.086 , 96.478 , 96.87 , 97.261 , 97.653 , 98.044 , 98.436 , 98.827 , 99.218 , 99.609 ,
100 , 100.391 , 100.781 , 101.172 , 101.562 , 101.953 , 102.343 , 102.733 , 103.123 , 103.513 ,
103.903 , 104.292 , 104.682 , 105.071 , 105.46 , 105.849 , 106.238 , 106.627 , 107.016 , 107.405 ,
107.794 , 108.182 , 108.57 , 108.959 , 109.347 , 109.735 , 110.123 , 110.51 , 110.898 , 111.286 ,
111.673 , 112.06 , 112.447 , 112.835 , 113.221 , 113.608 , 113.995 , 114.382 , 114.768 , 115.155 ,
115.541 , 115.927 , 116.313 , 116.699 , 117.085 , 117.47 , 117.856 , 118.241 , 118.627 , 119.012 ,
119.397 , 119.782 , 120.167 , 120.552 , 120.936 , 121.321 , 121.705 , 122.09 , 122.474 , 122.858 ,
123.242 , 123.626 , 124.009 , 124.393 , 124.777 , 125.16 , 125.543 , 125.926 , 126.309 , 126.692 ,
127.075 , 127.458 , 127.84 , 128.223 , 128.605 , 128.987 , 129.37 , 129.752 , 130.133 , 130.515 ,
130.897 , 131.278 , 131.66 , 132.041 , 132.422 , 132.803 , 133.184 , 133.565 , 133.946 , 134.326 ,
134.707 , 135.087 , 135.468 , 135.848 , 136.228 , 136.608 , 136.987 , 137.367 , 137.747 , 138.126 ,
138.506 , 138.885 , 139.264 , 139.643 , 140.022 , 140.4 , 140.779 , 141.158 , 141.536 , 141.914 ,
142.293 , 142.671 , 143.049 , 143.426 , 143.804 , 144.182 , 144.559 , 144.937 , 145.314 , 145.691 ,
146.068 , 146.445 , 146.822 , 147.198 , 147.575 , 147.951 , 148.328 , 148.704 , 149.08 , 149.456 ,
149.832 , 150.208 , 150.583 , 150.959 , 151.334 , 151.71 , 152.085 , 152.46 , 152.835 , 153.21 ,
153.584 , 153.959 , 154.333 , 154.708 , 155.082 , 155.456 , 155.83 , 156.204 , 156.578 , 156.952 ,
157.325 , 157.699 , 158.072 , 158.445 , 158.818 , 159.191 , 159.564 , 159.937 , 160.309 , 160.682 ,
161.054 , 161.427 , 161.799 , 162.171 , 162.543 , 162.915 , 163.286 , 163.658 , 164.03 , 164.401 ,
164.772 , 165.143 , 165.514 , 165.885 , 166.256 , 166.627 , 166.997 , 167.368 , 167.738 , 168.108 ,
168.478 , 168.848 , 169.218 , 169.588 , 169.958 , 170.327 , 170.696 , 171.066 , 171.435 , 171.804 ,
172.173 , 172.542 , 172.91 , 173.279 , 173.648 , 174.016 , 174.384 , 174.752 , 175.12 , 175.488 ,
175.856 , 176.224 , 176.591 , 176.959 , 177.326 , 177.693 , 178.06 , 178.427 , 178.794 , 179.161 ,
179.528 , 179.894 , 180.26 , 180.627 , 180.993 , 181.359 , 181.725 , 182.091 , 182.456 , 182.822 ,
183.188 , 183.553 , 183.918 , 184.283 , 184.648 , 185.013 , 185.378 , 185.743 , 186.107 , 186.472 ,
186.836 , 187.2 , 187.564 , 187.928 , 188.292 , 188.656 , 189.019 , 189.383 , 189.746 , 190.11 ,
190.473 , 190.836 , 191.199 , 191.562 , 191.924 , 192.287 , 192.649 , 193.012 , 193.374 , 193.736 ,
194.098 , 194.46 , 194.822 , 195.183 , 195.545 , 195.906 , 196.268 , 196.629 , 196.99 , 197.351 ,
197.712 , 198.073 , 198.433 , 198.794 , 199.154 , 199.514 , 199.875 , 200.235 , 200.595 , 200.954 ,
201.314 , 201.674 , 202.033 , 202.393 , 202.752 , 203.111 , 203.47 , 203.829 , 204.188 , 204.546 ,
204.905 , 205.263 , 205.622 , 205.98 , 206.338 , 206.696 , 207.054 , 207.411 , 207.769 , 208.127 ,
208.484 , 208.841 , 209.198 , 209.555 , 209.912 , 210.269 , 210.626 , 210.982 , 211.339 , 211.695 ,
212.052 , 212.408 , 212.764 , 213.12 , 213.475 , 213.831 , 214.187 , 214.542 , 214.897 , 215.252 ,
215.608 , 215.962 , 216.317 , 216.672 , 217.027 , 217.381 , 217.736 , 218.09 , 218.444 , 218.798 ,
219.152 , 219.506 , 219.86 , 220.213 , 220.567 , 220.92 , 221.273 , 221.626 , 221.979 , 222.332 ,
222.685 , 223.038 , 223.39 , 223.743 , 224.095 , 224.447 , 224.799 , 225.151 , 225.503 , 225.855 ,
226.206 , 226.558 , 226.909 , 227.26 , 227.612 , 227.963 , 228.314 , 228.664 , 229.015 , 229.366 ,
229.716 , 230.066 , 230.417 , 230.767 , 231.117 , 231.467 , 231.816 , 232.166 , 232.516 , 232.865 ,
233.214 , 233.564 , 233.913 , 234.262 , 234.61 , 234.959 , 235.308 , 235.656 , 236.005 , 236.353 ,
236.701 , 237.049 , 237.397 , 237.745 , 238.093 , 238.44 , 238.788 , 239.135 , 239.482 , 239.829 ,
240.176 , 240.523 , 240.87 , 241.217 , 241.563 , 241.91 , 242.256 , 242.602 , 242.948 , 243.294 ,
243.64 , 243.986 , 244.331 , 244.677 , 245.022 , 245.367 , 245.713 , 246.058 , 246.403 , 246.747 ,
247.092 , 247.437 , 247.781 , 248.125 , 248.47 , 248.814 , 249.158 , 249.502 , 249.845 , 250.189 ,
250.533 , 250.876 , 251.219 , 251.562 , 251.906 , 252.248 , 252.591 , 252.934 , 253.277 , 253.619 ,
253.962 , 254.304 , 254.646 , 254.988 , 255.33 , 255.672 , 256.013 , 256.355 , 256.696 , 257.038 ,
257.379 , 257.72 , 258.061 , 258.402 , 258.743 , 259.083 , 259.424 , 259.764 , 260.105 , 260.445 ,
260.785 , 261.125 , 261.465 , 261.804 , 262.144 , 262.483 , 262.823 , 263.162 , 263.501 , 263.84 ,
264.179 , 264.518 , 264.857 , 265.195 , 265.534 , 265.872 , 266.21 , 266.548 , 266.886 , 267.224 ,
267.562 , 267.9 , 268.237 , 268.574 , 268.912 , 269.249 , 269.586 , 269.923 , 270.26 , 270.597 ,
270.933 , 271.27 , 271.606 , 271.942 , 272.278 , 272.614 , 272.95 , 273.286 , 273.622 , 273.957 ,
274.293 , 274.628 , 274.963 , 275.298 , 275.633 , 275.968 , 276.303 , 276.638 , 276.972 , 277.307 ,
277.641 , 277.975 , 278.309 , 278.643 , 278.977 , 279.311 , 279.644 , 279.978 , 280.311 , 280.644 ,
280.978 , 281.311 , 281.643 , 281.976 , 282.309 , 282.641 , 282.974 , 283.306 , 283.638 , 283.971 ,
284.303 , 284.634 , 284.966 , 285.298 , 285.629 , 285.961 , 286.292 , 286.623 , 286.954 , 287.285 ,
287.616 , 287.947 , 288.277 , 288.608 , 288.938 , 289.268 , 289.599 , 289.929 , 290.258 , 290.588 ,
290.918 , 291.247 , 291.577 , 291.906 , 292.235 , 292.565 , 292.894 , 293.222 , 293.551 , 293.88 ,
294.208 , 294.537 , 294.865 , 295.193 , 295.521 , 295.849 , 296.177 , 296.505 , 296.832 , 297.16 ,
297.487 , 297.814 , 298.142 , 298.469 , 298.795 , 299.122 , 299.449 , 299.775 , 300.102 , 300.428 ,
300.754 , 301.08 , 301.406 , 301.732 , 302.058 , 302.384 , 302.709 , 303.035 , 303.36 , 303.685 ,
304.01 , 304.335 , 304.66 , 304.985 , 305.309 , 305.634 , 305.958 , 306.282 , 306.606 , 306.93 ,
307.254 , 307.578 , 307.902 , 308.225 , 308.549 , 308.872 , 309.195 , 309.518 , 309.841 , 310.164 ,
310.487 , 310.81 , 311.132 , 311.454 , 311.777 , 312.099 , 312.421 , 312.743 , 313.065 , 313.386 ,
313.708 , 314.029 , 314.351 , 314.672 , 314.993 , 315.314 , 315.635 , 315.956 , 316.277 , 316.597 ,
316.918 , 317.238 , 317.558 , 317.878 , 318.198 , 318.518 , 318.838 , 319.157 , 319.477 , 319.796 ,
320.116 , 320.435 , 320.754 , 321.073 , 321.391 , 321.71 , 322.029 , 322.347 , 322.666 , 322.984 ,
323.302 , 323.62 , 323.938 , 324.256 , 324.573 , 324.891 , 325.208 , 325.526 , 325.843 , 326.16 ,
326.477 , 326.794 , 327.11 , 327.427 , 327.744 , 328.06 , 328.376 , 328.692 , 329.008 , 329.324 ,
329.64 , 329.956 , 330.271 , 330.587 , 330.902 , 331.217 , 331.533 , 331.848 , 332.162 , 332.477 ,
332.792 , 333.106 , 333.421 , 333.735 , 334.049 , 334.363 , 334.677 , 334.991 , 335.305 , 335.619 ,
335.932 , 336.246 , 336.559 , 336.872 , 337.185 , 337.498 , 337.811 , 338.123 , 338.436 , 338.748 ,
339.061 , 339.373 , 339.685 , 339.997 , 340.309 , 340.621 , 340.932 , 341.244 , 341.555 , 341.867 ,
342.178 , 342.489 , 342.8 , 343.111 , 343.422 , 343.732 , 344.043 , 344.353 , 344.663 , 344.973 ,
345.284 , 345.593 , 345.903 , 346.213 , 346.522 , 346.832 , 347.141 , 347.451 , 347.76 , 348.069 ,
348.378 , 348.686 , 348.995 , 349.303 , 349.612 , 349.92 , 350.228 , 350.536 , 350.844 , 351.152 ,
351.46 , 351.768 , 352.075 , 352.382 , 352.69 , 352.997 , 353.304 , 353.611 , 353.918 , 354.224 ,
354.531 , 354.837 , 355.144 , 355.45 , 355.756 , 356.062 , 356.368 , 356.674 , 356.979 , 357.285 ,
357.59 , 357.896 , 358.201 , 358.506 , 358.811 , 359.116 , 359.42 , 359.725 , 360.029 , 360.334 ,
360.638 , 360.942 , 361.246 , 361.55 , 361.854 , 362.158 , 362.461 , 362.765 , 363.068 , 363.371 ,
363.674 , 363.977 , 364.28 , 364.583 , 364.886 , 365.188 , 365.491 , 365.793 , 366.095 , 366.397 ,
366.699 , 367.001 , 367.303 , 367.604 , 367.906 , 368.207 , 368.508 , 368.81 , 369.111 , 369.412 ,
369.712 , 370.013 , 370.314 , 370.614 , 370.914 , 371.215 , 371.515 , 371.815 , 372.115 , 372.414 ,
372.714 , 373.013 , 373.313 , 373.612 , 373.911 , 374.21 , 374.509 , 374.808 , 375.107 , 375.406 ,
375.704 , 376.002 , 376.301 , 376.599 , 376.897 , 377.195 , 377.493 , 377.79 , 378.088 , 378.385 ,
378.683 , 378.98 , 379.277 , 379.574 , 379.871 , 380.167 , 380.464 , 380.761 , 381.057 , 381.353 ,
381.65 , 381.946 , 382.242 , 382.537 , 382.833 , 383.129 , 383.424 , 383.72 , 384.015 , 384.31 ,
384.605 , 384.9 , 385.195 , 385.489 , 385.784 , 386.078 , 386.373 , 386.667 , 386.961 , 387.255 ,
387.549 , 387.843 , 388.136 , 388.43 , 388.723 , 389.016 , 389.31 , 389.603 , 389.896 , 390.188 ,
};
//查找索引
short findRTDInterpolationIndex (double ohm)
{
unsigned short i;
unsigned short RTD_TableCount = sizeof(RTD_Table)/sizeof(RTD_Table);
for (i=0; i< RTD_TableCount; i++)
{
if (RTD_Table > ohm)
return (i-1);
}
return (RTD_TableCount);
}
//通过电压查找分度表计算对应温度
double ConverRTD2Temperature(double ohm)
{
unsigned short index;
double temperature;
//查找当前电阻在分度表中的位置索引
index = findRTDInterpolationIndex(ohm);
//举例
//RTDTable[] = {1,3,8,10,20};//ohm
//如果输入数据是4.3ohm
//查找到索引得到对应的电阻为3
//用当前电压减索引电阻4.3-3=1.3
//再用上一个刻度减去当前刻度8-3 = 5
//每个刻度为1摄氏度间隔
//1.3/5=0.26 * 1度,得到当前刻度中对应的小数温度
//再用计算后的小数温度+当前索引=1+0.26 = 1.26
//因为索引不是从零度开始,假设从-1开始,那索引1则对应0度
//用1.26+分度表里的最低温度-1即得到0.26为当前计算后的温度
temperature = (ohm - RTD_Table) / (RTD_Table- RTD_Table) + index + RTD_TABLE_TEMP_MIN;
return temperature;
}
附上MSP430的测试工程
**** Hidden Message *****
看看PT100计算代码 看看 看到这个表格就想到当初挨个敲的痛苦,还好敲了十来个忍受不住停下,最终经过思考终于想出了偷懒方式,使用excel使用excel的公式生成上述数据,大大减小了工作量
看上述实现的温度检测精度为1,要是把表格的温度间隔缩小为0.1摄氏度,再通过二分法查表,温度就能达到0.01的精度了:) Tobey 发表于 2017-8-24 22:33
看到这个表格就想到当初挨个敲的痛苦,还好敲了十来个忍受不住停下,最终经过思考终于想出了偷懒方式,使用 ...
上边的例程是TI的一个参考设计提供的
手册里提到美国国家标准技术研究所
(NIST)
这类数据国内是不是也会有对应的机构提供?
你说的使用EXCEL表格生成数据用的什么方法?
这类的数据好像没有规律可循
不然也不会需要这个分度表了 littleshrimp 发表于 2017-8-25 08:07
上边的例程是TI的一个参考设计提供的
手册里提到美国国家标准技术研究所
(NIST)
这类数据国内是不是也 ...
这类数据是指RTD的那张表格吗?
RTD_Table有提供的,我是按照这个数据表做的(-200~625):
说是excel生成,其实还是半人工的,因为我要做的表格温度间隔是0.1摄氏度,如果手工计算再依次填表,不仅容易出错,而且要费很大的时间,所以呢,,就采用excel,先把间隔为1摄氏度的先作为列数据填入(因为这个无规律,只能挨个输入~~)--》接着采用excel的计算公式给第一列的第二行赋值--》直接拖动第一列第二行的数据就可以填充整个表格--》最后温度间隔为0.1摄氏度的数据表就出来了,这样校对只需校对第一列的数据就可以了,而且还方便后期的增删,结果如图所示,,嗯,这么讲貌似不是很好理解,经常使用excel的话就明白了,晚上要是没什么事的话,我给整整,把我之前做的相关代码贴上,顺便讲讲这个技巧好了
你把间隔1度的数据作为第一列 后边的0.1度每列数据是将1度分成十份 既然校准时也只是修改第一列的数据 为什么不把这种计算放在代码里实现呢 因为你这样做实际上只是让数组变大了 会减少一些处理器的运算 对提高精度并没有什么帮助吧? 这个表格我是参考国家标准做的!GB/T 30121-2013 工业铂热电阻及铂感温元件JB-T 8622-1997 工业铂热电阻技术条件及分度表 huixianfxt 发表于 2017-8-25 10:53
这个表格我是参考国家标准做的!GB/T 30121-2013 工业铂热电阻及铂感温元件JB-T 8622-1997 工业铂热电阻 ...
《JBT 8622-1997工业铂热电阻技术条件及分度表》
是PDF文件 ,你是怎么转成代码的
这个文档的数据保留2位小数
TI提供的保留3位小数,精度应该能高些
littleshrimp 发表于 2017-8-25 11:41
《JBT 8622-1997工业铂热电阻技术条件及分度表》
是PDF文件 ,你是怎么转成代码的
这个文档的数据保留2 ...
我是一个一个敲上去的。。。。当时就眼花了。。。。至于精度,不知道你用的PT100是按照那个标准做出来的,另外也不知道这几个文档具体分度表数值上的差别,不好说。。。。 huixianfxt 发表于 2017-8-25 13:17
我是一个一个敲上去的。。。。当时就眼花了。。。。至于精度,不知道你用的PT100是按照那个标准做出来的 ...
一个个敲多麻烦 还容易出错
PT100的精度不高2位小数还是3位小数也没多大影响误差才0.01摄氏度 littleshrimp 发表于 2017-8-25 10:19
既然校准时也只是修改第一列的数据 为什么不把这种计算放在代码里实现呢 因为你这样做实际上只是让数组变大 ...
嗯 这里说的校准是指校准表格中的数据是否输入有误的,如果在输入时出现错误,只要修改第一列的数据,其它相关数据就会动态修改,,, 嗯,发现只要是浮点运算,所得结果确实没什么影响~ 只是计算方式上略有区别 littleshrimp 发表于 2017-8-25 14:12
一个个敲多麻烦 还容易出错
PT100的精度不高2位小数还是3位小数也没多大影响误差才0.01摄氏度
具体哪个提供的数据准确也没个标尺~就TI的表格中的数据就和pdf中的数据有区别~~ 之前测试人员一边对比pt100测温在lcd中显示的数据和外部手持设备测的数值进行比较(用的什么传感器不知道~),一般相差0~2摄氏度之间 Tobey 发表于 2017-8-25 19:20
具体哪个提供的数据准确也没个标尺~就TI的表格中的数据就和pdf中的数据有区别~~ 之前测试人员一边对 ...
2摄氏度这个误差有点大,和传感器精度或者采集电路关系很大
淘宝上卖的几十元温控器标称精度都在0.5度以内 littleshrimp 发表于 2017-8-25 21:00
2摄氏度这个误差有点大,和传感器精度或者采集电路关系很大
淘宝上卖的几十元温控器标称精度都在0.5度以 ...
不是这个问题,标称的话,应该是指稳定后的波动范围吧,那样的话上面说的这个控制器可以标个0.1度以内了,,,我将连接pt100的两端直接接在电阻箱上,调节电阻箱上的阻值,大部分都和表格上的数据吻合,有些直接就吻合,有的差个0.01之类的,小部分几个会差个0~0.2(最大)之间,,,
在此基础上,将电阻箱改成pt100,然后再拿个手持设备检测,两者之间就会有出入,现在想想,当时应该让他们拿开水先试试,到底哪个比较准,不过这样的误差范围在一个大保温箱中符合要求,所以就没再怎么测试了,,,并且采用不一样的几个pt100,得到的结果也会有细微的区别,数据表中的对应关系也是存在一定的误差范围的,并不是绝对的一一对应关系,这个的话大概就和传感器精度或是工艺上有关系了,,
温度采集电路采用了电容倍增器进行了滤波,同时使用了超低纹波线性稳压电源芯片,与ADC有关的两个电阻也都采用了0.1%的电阻,精度的话,我是采用电阻箱测的,拿个电阻箱接上,看ADC的跳动范围,当时从串口助手上显示的数据来看,跳动范围为0.00~0.03(最大),因此,温度采集电路应该是没什么问题的 littleshrimp 发表于 2017-8-25 21:00
2摄氏度这个误差有点大,和传感器精度或者采集电路关系很大
淘宝上卖的几十元温控器标称精度都在0.5度以 ...
扯远了~~其实我就是想表达,数据表中的数据和pdf中的数据究竟哪个准确并没有一个绝对的标准,还得看实际使用的传感器 Tobey 发表于 2017-8-26 08:50
不是这个问题,标称的话,应该是指稳定后的波动范围吧,那样的话上面说的这个控制器可以标个0.1度以内了 ...
如果你使用电阻箱模拟电阻转换成温度后误差很小
实际使用PT100传感器测量时能差2度(最大值)是不可以推断这个PT100的传感器精度不够
不过这个应该还与你电阻箱的精度和手持仪表精度有关 Tobey 发表于 2017-8-26 08:53
扯远了~~其实我就是想表达,数据表中的数据和pdf中的数据究竟哪个准确并没有一个绝对的标准,还得看实 ...
分度表和传感器的关系我找了一下资料没找到对应的解释
根据我的理解分度表应该属于一个标准,对应所有指定的PT100传感器
一个PT100是B类还是A类应该都是与这个标准(PT100的)分度表之间的误差大小来决定的(不知道我这么理解对不对)
不然如果一个传感器对应一个分度表就没有标准可言了
所有的温度控制器都要根据所提供的传感器设计分度表用起来会非常麻烦
littleshrimp 发表于 2017-8-26 13:44
分度表和传感器的关系我找了一下资料没找到对应的解释
根据我的理解分度表应该属于一个标准,对应所有指 ...
嗯,肯定是这样的,这应该是在某种特定的标准下得到的数据,不过pdf中的电阻-温度关系与TI提供的demo中的表格存在出入,这点有点奇怪,我看了好几个相关的资料,对应关系都是我上面截图的那样,所以到对于哪个数据才是正确的就是个未解之谜了,所以我想这是不是和具体的PT100传感器有关,,,以及下面这张数据表,小数点后保留了四位,小数点后两位与pdf中的数据一一对应,,我当时按照0.1度制表就是参考的这个,不过没找到精度达到小数点后四位的数据表,只好使用保留小数点后两位的数据表了,,,
const float pt100_table =/*PT100 0-100度对应的电阻值,0.1度间隔*/
{
100.0000, 100.0391, 100.0782, 100.1172, 100.1563, 100.1954, 100.2345, 100.2736, 100.3126, 100.3517,
100.3908, 100.4298, 100.4689, 100.5080, 100.5470, 100.5861, 100.6252, 100.6642, 100.7033, 100.7424,
100.7814, 100.8205, 100.8595, 100.8986, 100.9377, 100.9767, 101.0158, 101.0548, 101.0939, 101.1329,
101.1720, 101.2110, 101.2501, 101.2891, 101.3282, 101.3672, 101.4062, 101.4453, 101.4843, 101.5234,
101.5624, 101.6014, 101.6405, 101.6795, 101.7185, 101.7576, 101.7966, 101.8356, 101.8747, 101.9137,
101.9527, 101.9917, 102.0308, 102.0698, 102.1088, 102.1478, 102.1868, 102.2259, 102.2649, 102.3039,
102.3429, 102.3819, 102.4209, 102.4599, 102.4989, 102.5380, 102.5770, 102.6160, 102.6550, 102.6940,
102.7330, 102.7720, 102.8110, 102.8500, 102.8890, 102.9280, 102.9670, 103.0060, 103.0450, 103.0840,
103.1229, 103.1619, 103.2009, 103.2399, 103.2789, 103.3179, 103.3569, 103.3958, 103.4348, 103.4738,
103.5128, 103.5518, 103.5907, 103.6297, 103.6687, 103.7077, 103.7466, 103.7856, 103.8246, 103.8636,
103.9025, 103.9415, 103.9805, 104.0194, 104.0584, 104.0973, 104.1363, 104.1753, 104.2142, 104.2532,
104.2921, 104.3311, 104.3701, 104.4090, 104.4480, 104.4869, 104.5259, 104.5648, 104.6038, 104.6427,
104.6816, 104.7206, 104.7595, 104.7985, 104.8374, 104.8764, 104.9153, 104.9542, 104.9932, 105.0321,
105.0710, 105.1100, 105.1489, 105.1878, 105.2268, 105.2657, 105.3046, 105.3435, 105.3825, 105.4214,
105.4603, 105.4992, 105.5381, 105.5771, 105.6160, 105.6549, 105.6938, 105.7327, 105.7716, 105.8105,
105.8495, 105.8884, 105.9273, 105.9662, 106.0051, 106.0440, 106.0829, 106.1218, 106.1607, 106.1996,
106.2385, 106.2774, 106.3163, 106.3552, 106.3941, 106.4330, 106.4719, 106.5108, 106.5496, 106.5885,
106.6274, 106.6663, 106.7052, 106.7441, 106.7830, 106.8218, 106.8607, 106.8996, 106.9385, 106.9774,
107.0162, 107.0551, 107.0940, 107.1328, 107.1717, 107.2106, 107.2495, 107.2883, 107.3272, 107.3661,
107.4049, 107.4438, 107.4826, 107.5215, 107.5604, 107.5992, 107.6381, 107.6769, 107.7158, 107.7546,
107.7935, 107.8324, 107.8712, 107.9101, 107.9489, 107.9877, 108.0266, 108.0654, 108.1043, 108.1431,
108.1820, 108.2208, 108.2596, 108.2985, 108.3373, 108.3762, 108.4150, 108.4538, 108.4926, 108.5315,
108.5703, 108.6091, 108.6480, 108.6868, 108.7256, 108.7644, 108.8033, 108.8421, 108.8809, 108.9197,
108.9585, 108.9974, 109.0362, 109.0750, 109.1138, 109.1526, 109.1914, 109.2302, 109.2690, 109.3078,
109.3467, 109.3855, 109.4243, 109.4631, 109.5019, 109.5407, 109.5795, 109.6183, 109.6571, 109.6959,
109.7347, 109.7734, 109.8122, 109.8510, 109.8898, 109.9286, 109.9674, 110.0062, 110.0450, 110.0838,
110.1225, 110.1613, 110.2001, 110.2389, 110.2777, 110.3164, 110.3552, 110.3940, 110.4328, 110.4715,
110.5103, 110.5491, 110.5879, 110.6266, 110.6654, 110.7042, 110.7429, 110.7817, 110.8204, 110.8592,
110.8980, 110.9367, 110.9755, 111.0142, 111.0530, 111.0917, 111.1305, 111.1693, 111.2080, 111.2468,
111.2855, 111.3242, 111.3630, 111.4017, 111.4405, 111.4792, 111.5180, 111.5567, 111.5954, 111.6342,
111.6729, 111.7117, 111.7504, 111.7891, 111.8279, 111.8666, 111.9053, 111.9441, 111.9828, 112.0215,
112.0602, 112.0990, 112.1377, 112.1764, 112.2151, 112.2538, 112.2926, 112.3313, 112.3700, 112.4087,
112.4474, 112.4861, 112.5248, 112.5636, 112.6023, 112.6410, 112.6797, 112.7184, 112.7571, 112.7958,
112.8345, 112.8732, 112.9119, 112.9506, 112.9893, 113.0280, 113.0667, 113.1054, 113.1441, 113.1828,
113.2215, 113.2602, 113.2988, 113.3375, 113.3762, 113.4149, 113.4536, 113.4923, 113.5309, 113.5696,
113.6083, 113.6470, 113.6857, 113.7243, 113.7630, 113.8017, 113.8404, 113.8790, 113.9177, 113.9564,
113.9950, 114.0337, 114.0724, 114.1110, 114.1497, 114.1884, 114.2270, 114.2657, 114.3043, 114.3430,
114.3817, 114.4203, 114.4590, 114.4976, 114.5363, 114.5749, 114.6136, 114.6522, 114.6909, 114.7295,
114.7681, 114.8068, 114.8454, 114.8841, 114.9227, 114.9614, 115.0000, 115.0386, 115.0773, 115.1159,
115.1545, 115.1932, 115.2318, 115.2704, 115.3091, 115.3477, 115.3863, 115.4249, 115.4636, 115.5022,
115.5408, 115.5794, 115.6180, 115.6567, 115.6953, 115.7339, 115.7725, 115.8111, 115.8497, 115.8883,
115.9270, 115.9656, 116.0042, 116.0428, 116.0814, 116.1200, 116.1586, 116.1972, 116.2358, 116.2744,
116.3130, 116.3516, 116.3902, 116.4288, 116.4674, 116.5060, 116.5446, 116.5831, 116.6217, 116.6603,
116.6989, 116.7375, 116.7761, 116.8147, 116.8532, 116.8918, 116.9304, 116.9690, 117.0076, 117.0461,
117.0847, 117.1233, 117.1619, 117.2004, 117.2390, 117.2776, 117.3161, 117.3547, 117.3933, 117.4318,
117.4704, 117.5090, 117.5475, 117.5861, 117.6247, 117.6632, 117.7018, 117.7403, 117.7789, 117.8174,
117.8560, 117.8945, 117.9331, 117.9716, 118.0102, 118.0487, 118.0873, 118.1258, 118.1644, 118.2029,
118.2414, 118.2800, 118.3185, 118.3571, 118.3956, 118.4341, 118.4727, 118.5112, 118.5497, 118.5883,
118.6268, 118.6653, 118.7038, 118.7424, 118.7809, 118.8194, 118.8579, 118.8965, 118.9350, 118.9735,
119.0120, 119.0505, 119.0890, 119.1276, 119.1661, 119.2046, 119.2431, 119.2816, 119.3201, 119.3586,
119.3971, 119.4356, 119.4741, 119.5126, 119.5511, 119.5896, 119.6281, 119.6666, 119.7051, 119.7436,
119.7821, 119.8206, 119.8591, 119.8976, 119.9361, 119.9746, 120.0131, 120.0516, 120.0900, 120.1285,
120.1670, 120.2055, 120.2440, 120.2824, 120.3209, 120.3594, 120.3979, 120.4364, 120.4748, 120.5133,
120.5518, 120.5902, 120.6287, 120.6672, 120.7056, 120.7441, 120.7826, 120.8210, 120.8595, 120.8980,
120.9364, 120.9749, 121.0133, 121.0518, 121.0902, 121.1287, 121.1672, 121.2056, 121.2441, 121.2825,
121.3210, 121.3594, 121.3978, 121.4363, 121.4747, 121.5132, 121.5516, 121.5901, 121.6285, 121.6669,
121.7054, 121.7438, 121.7822, 121.8207, 121.8591, 121.8975, 121.9360, 121.9744, 122.0128, 122.0513,
122.0897, 122.1281, 122.1665, 122.2049, 122.2434, 122.2818, 122.3202, 122.3586, 122.3970, 122.4355,
122.4739, 122.5123, 122.5507, 122.5891, 122.6275, 122.6659, 122.7043, 122.7427, 122.7811, 122.8195,
122.8579, 122.8963, 122.9347, 122.9731, 123.0115, 123.0499, 123.0883, 123.1267, 123.1651, 123.2035,
123.2419, 123.2803, 123.3187, 123.3571, 123.3955, 123.4338, 123.4722, 123.5106, 123.5490, 123.5874,
123.6257, 123.6641, 123.7025, 123.7409, 123.7792, 123.8176, 123.8560, 123.8944, 123.9327, 123.9711,
124.0095, 124.0478, 124.0862, 124.1246, 124.1629, 124.2013, 124.2396, 124.2780, 124.3164, 124.3547,
124.3931, 124.4314, 124.4698, 124.5081, 124.5465, 124.5848, 124.6232, 124.6615, 124.6999, 124.7382,
124.7766, 124.8149, 124.8533, 124.8916, 124.9299, 124.9683, 125.0066, 125.0450, 125.0833, 125.1216,
125.1600, 125.1983, 125.2366, 125.2749, 125.3133, 125.3516, 125.3899, 125.4283, 125.4666, 125.5049,
125.5432, 125.5815, 125.6199, 125.6582, 125.6965, 125.7348, 125.7731, 125.8114, 125.8497, 125.8881,
125.9264, 125.9647, 126.0030, 126.0413, 126.0796, 126.1179, 126.1562, 126.1945, 126.2328, 126.2711,
126.3094, 126.3477, 126.3860, 126.4243, 126.4626, 126.5009, 126.5392, 126.5775, 126.6157, 126.6540,
126.6923, 126.7306, 126.7689, 126.8072, 126.8455, 126.8837, 126.9220, 126.9603, 126.9986, 127.0368,
127.0751, 127.1134, 127.1517, 127.1899, 127.2282, 127.2665, 127.3048, 127.3430, 127.3813, 127.4195,
127.4578, 127.4961, 127.5343, 127.5726, 127.6109, 127.6491, 127.6874, 127.7256, 127.7639, 127.8021,
127.8404, 127.8786, 127.9169, 127.9551, 127.9934, 128.0316, 128.0699, 128.1081, 128.1464, 128.1846,
128.2228, 128.2611, 128.2993, 128.3376, 128.3758, 128.4140, 128.4523, 128.4905, 128.5287, 128.5670,
128.6052, 128.6434, 128.6816, 128.7199, 128.7581, 128.7963, 128.8345, 128.8728, 128.9110, 128.9492,
128.9874, 129.0256, 129.0638, 129.1021, 129.1403, 129.1785, 129.2167, 129.2549, 129.2931, 129.3313,
129.3695, 129.4077, 129.4459, 129.4841, 129.5223, 129.5605, 129.5987, 129.6369, 129.6751, 129.7133,
129.7515, 129.7897, 129.8279, 129.8661, 129.9043, 129.9425, 129.9807, 130.0188, 130.0570, 130.0952,
130.1334, 130.1716, 130.2098, 130.2479, 130.2861, 130.3243, 130.3625, 130.4006, 130.4388, 130.4770,
130.5152, 130.5533, 130.5915, 130.6297, 130.6678, 130.7060, 130.7442, 130.7823, 130.8205, 130.8586,
130.8968, 130.9350, 130.9731, 131.0113, 131.0494, 131.0876, 131.1257, 131.1639, 131.2020, 131.2402,
131.2783, 131.3165, 131.3546, 131.3928, 131.4309, 131.4691, 131.5072, 131.5453, 131.5835, 131.6216,
131.6597, 131.6979, 131.7360, 131.7742, 131.8123, 131.8504, 131.8885, 131.9267, 131.9648, 132.0029,
132.0411, 132.0792, 132.1173, 132.1554, 132.1935, 132.2317, 132.2698, 132.3079, 132.3460, 132.3841,
132.4222, 132.4603, 132.4985, 132.5366, 132.5747, 132.6128, 132.6509, 132.6890, 132.7271, 132.7652,
132.8033, 132.8414, 132.8795, 132.9176, 132.9557, 132.9938, 133.0319, 133.0700, 133.1081, 133.1462,
133.1843, 133.2224, 133.2604, 133.2985, 133.3366, 133.3747, 133.4128, 133.4509, 133.4889, 133.5270,
133.5651, 133.6032, 133.6413, 133.6793, 133.7174, 133.7555, 133.7935, 133.8316, 133.8697, 133.9078,
133.9458, 133.9839, 134.0220, 134.0600, 134.0981, 134.1361, 134.1742, 134.2123, 134.2503, 134.2884,
134.3264, 134.3645, 134.4025, 134.4406, 134.4786, 134.5167, 134.5547, 134.5928, 134.6308, 134.6689,
134.7069, 134.7450, 134.7830, 134.8211, 134.8591, 134.8971, 134.9352, 134.9732, 135.0112, 135.0493,
135.0873, 135.1253, 135.1634, 135.2014, 135.2394, 135.2774, 135.3155, 135.3535, 135.3915, 135.4295,
135.4676, 135.5056, 135.5436, 135.5816, 135.6196, 135.6577, 135.6957, 135.7337, 135.7717, 135.8097,
135.8477, 135.8857, 135.9237, 135.9617, 135.9997, 136.0377, 136.0757, 136.1137, 136.1517, 136.1897,
136.2277, 136.2657, 136.3037, 136.3417, 136.3797, 136.4177, 136.4557, 136.4937, 136.5317, 136.5697,
136.6077, 136.6456, 136.6836, 136.7216, 136.7596, 136.7976, 136.8355, 136.8735, 136.9115, 136.9495,
136.9875, 137.0254, 137.0634, 137.1014, 137.1393, 137.1773, 137.2153, 137.2532, 137.2912, 137.3292,
137.3671, 137.4051, 137.4431, 137.4810, 137.5190, 137.5569, 137.5949, 137.6329, 137.6708, 137.7088,
137.7467, 137.7847, 137.8226, 137.8606, 137.8985, 137.9365, 137.9744, 138.0123, 138.0503, 138.0882,
138.1262, 138.1641, 138.2020, 138.2400, 138.2779, 138.3158, 138.3538, 138.3917, 138.4296, 138.4676,
138.5055
};
pdf中的电阻-温度对应关系:
页:
[1]
2