Using a PN-junction diode for temperature measurement usually depends on its 2‑mV/K temperature  coefficient. Conventionally, you must amplify and digitize this voltage with an ADC before you can use the value in a microcontroller. Less well-known is the fact that the reverse current of a PN-junction diode shows a good exponential dependency over temperature; increasing the temperature by approximately 12K doubles the leakage (Figure 1).

An easy way to measure current over such a large range of two to three decades is to charge and discharge a capacitor and measure the time or frequency.

A general-purpose I/O pin of a microcontroller charges a capacitor either by using it temporally as an output or by enabling a pull-up resistor, which is available in some controllers (Figure 2a). After charging the pin, you configure it as a high-impedance input, and a capacitor discharges through the leakage current of the diode (Figure 2b). The discharge time then is proportional to the temperature of the diode; thus, the diode exhibits exponential behavior. Depending on the type of diode, the exponential behavior can be nearly ideal. Calibration of a base point is necessary because the absolute value of the current varies greatly at a given temperature.

Selecting the diode and the value of the capacitor requires some care. The smaller the PN junction, the smaller the reverse current and the longer the discharging time. Periods longer than a few seconds are usually unsuitable. Making the capacitor’s value too low leads to errors because the capacitance of any cable and the capacitance of the PN-junction diode come into effect.

Typically, a power diode, such as a 1N4001 with a capacitance of 1 nF, gives suitable results. The discharge time is approximately 0.3 to 1 sec at room temperature, falling into the millisecond range at 100°C. The PN-junction diode of a power transistor should also work.

Simple microcontroller-temperature measurement uses only a diode and a capacitor的更多相关文章

  1. Driving proportional valves from microcontroller

    Driving proportional valves from microcontroller I am looking to drive a current regulated proportio ...

  2. PID控制器(比例-积分-微分控制器)- I

    形象解释PID算法 小明接到这样一个任务: 有一个水缸点漏水(而且漏水的速度还不一定固定不变),要求水面高度维持在某个位置,一旦发现水面高度低于要求位置,就要往水缸里加水. 小明接到任务后就一直守在水 ...

  3. Overview and Evaluation of Bluetooth Low Energy: An Emerging Low-Power Wireless Technology

    转自:http://www.mdpi.com/1424-8220/12/9/11734/htm Sensors 2012, 12(9), 11734-11753; doi:10.3390/s12091 ...

  4. RFID 仿真/模拟/监控/拦截/检测/嗅探器

    Sound card based RFID sniffer/emulator (Too tired after recon.cx to do draw the schematics better th ...

  5. Architecture of Device I/O Drivers, Device Driver Design

    http://www.kalinskyassociates.com/Wpaper4.html Architecture of Device I/O Drivers Many embedded syst ...

  6. PID控制器(比例-积分-微分控制器)- II

    Table of Contents Practical Process Control Proven Methods and Best Practices for Automatic PID Cont ...

  7. Danfoss Motor - Automotive Motor: What Sensors Are There?

    The   Danfoss Motor     states that the motor sensor control system is the heart of the entire autom ...

  8. bq27441-G1 工作机制

    /*************************************************************************** * bq27441-G1 工作机制 * 声明: ...

  9. 重力加速度陀螺仪传感器MPU-6050(一)

    MPU-60X0 对陀螺仪和加速度计分别用了三个16 位的ADC,将其测量的模拟量转化 为可输出的数字量.为了精确跟踪快速和慢速的运动,传感器的测量范围都是用户可控的,陀螺仪可测范围为±250,±50 ...

随机推荐

  1. puppet overview

    安装 以在Ubuntu server 14.04.2 TLS 为例: 设置机器名. 编辑/etc/host以修改主机名,因为puppet是基于证书的,证书中包含主机名: 更新包源. echo -e & ...

  2. Photon3Unity3D.dll 解析三——OperationRequest、OperationResponse

    OperationRequest 代表Operation操作的Request,包含Code和Parameters OperationCode  Byte类型的值,代表操作,由LiteOpCode定义了 ...

  3. awk中NF,NR的含义

    awk中NF和NR的意义,其实你已经知道NF和NR的意义了,NF代表的是一个文本文件中一行(一条记录)中的字段个数,NR代表的是这个文本文件的行数(记录数).在编程时特别是在数据处理时经常用到.建议你 ...

  4. 半小时分组统计个数sql

    group by 最后一个时间是多少按多少分组 select count(1), trunc(a.refund_insert_time, 'hh24') + case when to_char(ref ...

  5. 一张图总结html5新特性

  6. 开始学习MaxCompute

    https://help.aliyun.com/document_detail/34615.html?spm=a2c4g.11186623.6.688.jVxTMW

  7. 两周撸一个掘金微信小程序

    利益相关 无 声明 这并不是掘金官方小程序(貌似没有搜到掘金 APP 对应的官方小程序),完全为第三者开发者开发,仅用于学习交流,禁止用于其他用途.若要使用官方正版,可访问掘金 官方网站,或下载掘金官 ...

  8. JS函数练习题

    第一题:封装一个输入半径求圆的面积的函数 var banJing = parseInt(prompt("请输入圆的半径")); var x = m(banJing); alert( ...

  9. pyqt5最简单的打开和保存文件

    import sys import os from PyQt5.QtWidgets import QApplication,QWidget,QFileDialog from t import Ui_F ...

  10. 使用 JavaScript 在下拉列表中获取选定的值

    使用 JavaScript 在下拉列表中获取选定的值 演示Demo 使用 JavaScript 在下拉列表中获取选定的值? <!DOCTYPE html> <html> < ...