DS18B20 单线温度传感器外文翻译

合集下载

机械毕业设计英文外文翻译8DS18B20的研究与应用

机械毕业设计英文外文翻译8DS18B20的研究与应用

附录Research and Application of DS18B20Communication to the DS18B20 is via a 1-Wire port. With the 1-Wire port, the memory and control functions will not be available before the ROM function protocol has been established. The master must first provide one of five ROM function commands: 1) Read ROM, 2) Match ROM, 3) Search ROM, 4) Skip ROM, or 5) Alarm Search. These commands operate on the 64-bit lasered ROM portion of each device and can single out a specific device if many are present on the 1-Wire line as well as indicate to the bus master how many and what types of devices are present. After a ROM function sequence has been successfully executed, the memory and control functions are accessible and the master may then provide any one of the six memory and control function commands.One control function command instructs the DS18B20 to perform a temperature measurement. The result of this measurement will be placed in the DS18B20’s scr atch-pad memory, and may be read by issuing a memory function command which reads the contents of the scratchpad memory. The temperature alarm triggers TH and TL consist of 1 byte EEPROM each. If the alarm search command is not applied to the DS18B20, theseregisters may be used as general purpose user memory. The scratchpad also contains a configuration byte to set the desired resolution of the temperature to digital conversion. Writing TH, TL, and the configuration byte is done using a memory function command. Read access to these registers is through the scratchpad. All data is read and written least significant bit first.In order for the DS18B20 to be able to perform accurate temperature conversions, sufficient power must be provided over the DQ line when a temperature conversion is taking place. Since the operating current of the DS18B20 is up to 1.5 mA, the DQ line will not have sufficient drive due to the 5k pullup resistor. This problem is particularly acute if several DS18B20s are on the same DQ and attempting to convert simultaneously.There are two ways to assure that the DS18B20 has sufficient supply current during its active conversion cycle. The first is to provide a strong pullup on the DQ line whenever temperature conversions or copies to the E2 memory are taking place. This may be accomplished by using a MOSFET to pull the DQ line directly to the power supply as shown in Figure 2. The DQ line must beissuing any protocol that involves copying to the E2 memory or initiates temperature conversions. When using the parasite powermode, the VDD pin must be tied to ground.Another method of supplying current to the DS18B20 is through the use of an external power supply tied to the VDD pin. The advantage to this is that the strong pullup is not required on the DQ line, and the bus master need not be tied up holding that line high during temperature conversions.This allows other data traffic on the 1-Wire bus during the conversion time. In addition, any number of DS18B20s may be placed on the 1-Wire bus, and if they all use external power, they may all simultaneously perform temperature conversions by issuing the Skip ROM command and then issuing the Convert T command. Note that as long as the external power supply is active, the GND pin may not be floating.The core functionality of the DS18B20 is its direct-to-digital temperature sensor. The resolution of the DS18B20 is configurable (9, 10, 11, or 12 bits), with 12-bit readings the factory default state.command, a temperature conversion is performed and the thermal data is stored in the scratchpad memory in a 16-bit, sign-extended two’s complement format. The temperature information can be retrieved over the 1-Wire interface by issuing a Read Scratchpad [BEh] command once the conversion has been performed. The datais transferred over the 1-Wire bus, LSB first. The MSB of the temperature register contains the “sign” (S) bit, denoting whether the temperature is positive or negative.Each DS18B20 contains a unique ROM code that is 64-bits long. The first 8 bits are a 1-Wire family code (DS18B20 code is 28h). The next 48 bits are a unique serial number. The last 8 bits are a CRC of the first 56 bits. The 64-bit ROM and ROM Function Control section allow the DS18B20 to operate as a 1-Wire device and follow the 1-Wire protocol detailed in the section “1-Wire Bus System.” The functions required to control sections of the DS18B20 are not accessible until the ROM function protocol has been satisfied. This protocol is described in the ROM function protocol flowchart. The 1-Wire bus master must first provide one of five ROM function commands: 1) Read ROM, 2) Match ROM, 3) Search ROM, 4) Skip ROM, or 5) Alarm Search. After a ROM function sequence has been successfully executed, the functions specific to the DS18B20 are accessible and the bus master may then provide one of the six memory and control function commands.The DS18B20 has an 8-bit CRC stored in the most significant byte of the 64-bit ROM. The bus master can compute a CRC value from the first 56-bits of the 64-bit ROM and compare it to the value stored within the DS18B20 to determine if the ROM data has beenreceived error-free by the bus master. The equivalent polynomial function of this CRC is:CRC = X8 + X5 + X4 + 1The DS18B20 also generates an 8-bit CRC value using the same polynomial function shown above and provides this value to the bus master to validate the transfer of data bytes. In each case where a CRC is used for data transfer validation, the bus master must calculate a CRC value using the polynomial function given above and compare the calculated value to either the 8-bit CRC value stored in the 64-bitROM portion of the DS18B20 (for ROM reads) or the 8-bit CRC value computed within the DS18B20(which is read as a ninth byte when the scratchpad is read). The comparison of CRC values and decision to continue with an operation are determined entirely by the bus master. There is no circuitry inside the DS18B20 that prevents a command sequence from proceeding if the CRC stored in or calculated by the DS18B20 does not match the value generated by the bus master.The scratchpad is organized as eight bytes of memory. The first 2 bytes contain the LSB and the MSB of the measured temperature information, respectively. The third and fourth bytes are volatile copies of TH and TL and are refreshed with every power-on reset.The fifth byte is a volatile copy of the configuration register and is refreshed with every power-on reset. The configuration register will be explained in more detail later in this section of the datasheet. The sixth, seventh, and eighth bytes are used for internal computations, and thus will not read out any predictable pattern.It is imperative that one writes TH, TL, and config in succession;i.e. a write is not valid if one writes only to TH and TL, for example, and then issues a reset. If any of these bytes must be written, all three must be written before a reset is issued.There is a ninth byte which may be read with a Read Scratchpad [BEh] command. This byte contains a cyclic redundancy check (CRC) byte which is the CRC over all of the eight previous bytes. This CRC is implemented in the fashion described in the section titled “CRC Generation”.DS18B20的研究与应用DS18B20的通信是通过一个1 - Wire端口。

单总线温度传感器DS18B20简介

单总线温度传感器DS18B20简介

单总线温度传感器DS18B20简介DS18B20是DALLAS公司生产的单总线式数字温度传感器,它具有微型化、低功耗、高性能、搞干扰能力强、易配处理器等优点,特别适用于构成多点温度测控系统,可直接将温度转化成串行数字信号(提供9位二进制数字)给单片机处理,且在同一总线上可以挂接多个传感器芯片。

它具有3引脚TO-92小体积封装形式,温度测量范围为-55℃~+125℃,可编程为9位~12位A/D转换精度,测温分辨率可达0.0625℃,被测温度用符号扩展的16位数字量方式串行输出,其工作电源既可在远端引入,也可采用寄生电源方式产生,多个DS18B20可以并联到3根或2根线上,CPU只需一根端口线就能与多个DS18B20通信,占用微处理器的端口较少,可节省大量的引线和逻辑电路。

以上特点使DS18B20非常适用于远距离多点温度检测系统。

DS18B20外形及引脚说明外形及引脚如图2所示:图2 管脚排列图在TO-92和SO-8的封装中引脚有所不同,具体差别请查阅PDF手册,在TO-92封装中引脚分配如下:1(GND):地2(DQ):单线运用的数据输入输出引脚3(VDD):可选的电源引脚DS18B20工作过程及时序DS18B20内部的低温度系数振荡器是一个振荡频率随温度变化很小的振荡器,为计数器1提供一频率稳定的计数脉冲。

高温度系数振荡器是一个振荡频率对温度很敏感的振荡器,为计数器2提供一个频率随温度变化的计数脉冲。

初始时,温度寄存器被预置成-55℃,每当计数器1从预置数开始减计数到0时,温度寄存器中寄存的温度值就增加1℃,这个过程重复进行,直到计数器2计数到0时便停止。

初始时,计数器1预置的是与-55℃相对应的一个预置值。

以后计数器1每一个循环的预置数都由斜率累加器提供。

为了补偿振荡器温度特性的非线性性,斜率累加器提供的预置数也随温度相应变化。

计数器1的预置数也就是在给定温度处使温度寄存器寄存值增加1℃计数器所需要的计数个数。

温度传感器DS18B20_外文翻译

温度传感器DS18B20_外文翻译

DS18B20Programmable Resolution1-WireDigital Thermometer1、DS18B20FEATURES(1)Unique1-Wire interface requires only one Port pin for communication,requires no external components(2)Each device has a unique64-bit serial code stored in an onboard ROM(3)Can be powered form data line.Power supply range is3.0Vto5.5V(4)Measures temperatures form-55℃to+125℃,±0.5℃accuracy from-10℃to +85℃(5)Thermometer resolution is user-selected from9to12bits(6)Converts temperature to12-bit digital word in750ms(max)(7)Alarm search command identifies and addresses devices whose temperature is outside of programmed limits(temperature alarm condition)(8)Available in8-pin SOIC,and3-bin TO-92packages2、DS18B20BLOCK DIAFRAMFigure1shows a block diagram of the DS18B20,The64-bite ROM stores the device’s serial code.The scratchpad memory contains the2-byte temperature egister that stores the digital output from the temperature sensor.In addition,the scratchpad provides access to the1-byte upper and lower alarm trigger register(TH and TL),and the1-byte configuratuion register.The configuration register allows the user to set the resolution of the temperature-to-digital conversion to9,10,11or12bits.The TH,TL and configuration registers are nonvolatile(EEPROM),so they will retain data when the device is powered down.Figure1block diagram of the DS18B203、DS18B20ROM COMMANDS(1)SEARCH ROM[0F0H]When a system is initially powered up,the master must identify the ROM codes of all slave devices on the bus,which allows the master to determine the number of slaves and their device types.The master learns the ROM codes through a process of elimination that requires the master to perform a Search ROM cycle as many times as necessary to identify all of the slave’s64-bit ROM devices.(2)READ ROM[55H]This command can only be used when there is one slave on the bus.It allows the bus master to read the slave`64-bit ROM code without using the Search ROM procedure.If this command is used when there is more than one slave present on the bus,a data collision will occur when all the slaves attempt to respond at the same time.(3)MATCH ROM[55H]The match ROM command followed by a64-bit ROM code sequence allows the bus master to address a specific DS18B20on a multidrop or single-drop bus.Only the DS18B20that exactly matches the64-bitROM code sequence will respond to thefunction command issued by the master;all other slaves on the bus will wait for a reset pulse.(4)SKIP ROM[0CCH]The master can use this command to address all devices on the bus simultaneously without sending out any ROM code information.Note that the Read Scratchpad command can follow the Skip ROM command only if there is a single slave device on the bus.In this case time is saved by allowing the master to read from the slave without sending the device’s64-bit ROM code.A Skip ROM command followed by a Read Scratchpad command will cause a data collision on the bus if there is more than one slave since multiple devices will attempt to transmit data simultaneously.(5)ALARM SEARCH[0ECH]The operation of this command is identical to the operation of the Search ROM command except that only slaves with a set alarm flag will respond.This command allows the master device to determine if any DS18B20s experienced an alarm condition during the most recent temperature conversion.Refer to the OPERATION-ALARM SIGNAING section for an explanation of alarm flag operation.(6)CONVERTT[44H]This command initiates a single temperature conversion.Following the conversion,the resulting thermal data is stored in the2-bute temperature register in the scratchpad memory and the DS18B20returns to its low-power idle state.If the device is being used in parasite power mode,within10us after this command is issued the master must enable a strong pullup on the1-Wire bus for the duration of the conversion as described in the POWERING THE DS18320section.If the DS18B20 is powered by an external supply,the master can issue read time slots after the Convert T command and the DS18B20will respond by transmitting a0while the temperature conversion is in Progress and a1when the conversion is done.In parasite power mode this notification technique cannot be used since the bus1is pulled high by the strong pullup during the conversion.(7)WRITE SCRACHPAD[4EH]This command allows the master to write3bytes of the data to the DS18B20’s scratchpad.The first data byte is writer into the TH register,the second byte is written into the TL register,and the third byte is written into the configuration register. Data must be transmitted least significant bit first.All three bytes must be written before the master issues a reset,or the data may be corrupted.(8)READ SCRACHPAD[0BEH]This command allows the master to read the contents of the scratchpad.The data transfer starts with the least significant bit of byte0and continues through the scratchpad until9byte(byte8-CRC)is read.The master may issue a reset to terminate reading at any time if only partof the scratchpad data is needed.(9)COPY SCRATCHPAD[48H]This command copies the contents of the scratchpad TH,TL and configuration registers to EEPROM.If the device is being used in parasite power mode,within 10us(max)after this command is issued the master must enable a strong pullup on the 1-Wire bus for at least10ms as described in the POWERING THE DS18B20section.(10)RECALL E2[B8H]This command recalls the alarm trigger values(TH and TL)and configuration data from EEPROM,respectively,in the scratchpad memory.The master device can issue read time slots following the Recall E2command and the DS18B20will indicate the status of the recall by transmitting0while the recall is in progress and1 when the recall is done.The recall operation happens automatically at power-up,so valid data is available in the scratchpad as soon as power is applied to the device.DS18B20单总线数字温度计1、DS18B20的特性(1)独特的单总线接口只占用一个I/O端口,而无需外围元件;(2)可以由总线提供电源,电压适用范围为3.0V~5.5V;(3)测量温度范围为-55℃~+125℃,在-10℃~+85℃范围内精度为±0.5℃;(4)每个DS18B20含有一个唯一的64位ROM编码;(5)用户可以通过编程实现9~12位的温度分辨率;(6)分辨率为12时最大转换时间为750ms;(7)报警搜索命令可识别哪片DS18B20温度超限;(8)采用3脚T0-92或8脚SOIC封装。

DS18B20的中英文翻译

DS18B20的中英文翻译

DS18B20的中英文翻译DS18B20 Single - wire temperature sensor 一. FEATURES● Unique 1-Wireinterface requires only one port pin for communication● Each device has a unique 64-bit serial code stored in an onboard ROM● Multidrop capability simplifies distributed temperature sensing applications ● Requires no external components● Can be powered from data line. Power supply range is 3.0V to 5.5V● Measures temperatures from –55°C to +125°C (–67°F to +257°F) 0.5 Caccuracy from –10°C to +85°C● Thermometer resolution is user-selectable from 9 to 12 bits●Converts temperature to 12-bit digital word in 750ms (max.)●User-definable nonvolatile (NV) alarm settings● Alarm search command identifies and addresses devices whose temperature isoutside of programmed limits (temperature alarm condition)● Available in 8-pin SO (150mil), 8-pin SOP, and 3-pin TO-92 packages● Software compatible with the DS1822● Applications include thermostatic controls, ind ustrial systems, consumerproducts, thermometers, or any thermally sensitive二. DESCRIPTIONThe DS18B20 Digital Thermometer provides 9 to 12–bit centigrade temperature measurements and has an alarm function with nonvolatile user-programmable upper and lowertrigger points. The DS18B20 communicates over a 1-Wire bus that by definition requires only one data line (and ground) for communication with a central microprocessor. It has an operating temperature range of –55°C to +125°Cand is accurate to 0.5 C over the range of –10°C to +85°C. In addition, the DS18B20 can derive powerdirectly from the data line (“parasite power”), eliminating the need for an external power supply.Each DS18B20 has a unique 64-bit serial code, which allows multiple DS18B20s to function on the same 1–wire bus; thus, it is simple to use one microprocessor to control many DS18B20s distributed over a large area. Applications that can benefit from this feature include HVAC environmental controls, temperature monitoring systems inside buildings, equipment or machinery, and process monitoring and control systems.三. OVERVIEWFigure 1 shows a block diagram of the DS18B20, and pin descriptions are given in Table 1. The 64-bit ROM stores the device’s unique serial code. The scratchpad memory contains the 2-byte temperature register that stores the digital output from the temperature sensor. In addition, the scratchpad provides access to the 1-byte upper and lower alarm trigger registers (TH and TL), and the 1-byte configuration register. The configuration register allows the user to set the resolution of the temperature-to-digital conversion to 9, 10, 11, or 12 bits. The TH, TL and configuration registers are nonvolatile (EEPROM), so they will retain data when the device is powered down.The DS18B20 uses Dallas’ exclusive 1-Wire bus protocol that implements bus communication using one control signal. The control line requires a weak pullup resistor since all devices are linked to the bus via a 3-state or open-drain port (the DQ pinin the case of the DS18B20). In this bus system, the microprocessor (the master device) identifies and addresses devices on the bus using each device’s unique 64-bit code. Because each device has a unique code, the number of devices that can be addressed on one bus is virtually unlimited. The 1-Wire bus protocol, including detailed explanations of the commands an d “time slots,” is covered in the 1-WIRE BUS SYSTEM section of this datasheet。

DS1820 单总线数字温度计外文翻译

DS1820 单总线数字温度计外文翻译

外文资料DS18B20 Programmable Resolution 1-Wire DigitalThermometerThe DS18B20 Digital Thermometer provides 9 to 12-bit (configurable) temperature readings which indicate the temperature of the device. Information is sent to/from the DS18B20 over a 1-Wire interface, so that only one wire (and ground) needs to be connected from a central microprocessor to a DS18B20. Power for reading, writing, and performing temperature conversions can be derived from the data line itself with no need for an external power source. Because each DS18B20 contains a unique silicon serial number, multiple DS18B20s can exist on the same 1-Wire bus. This allows for placing temperature sensors in many different places. Applications where this feature is useful include HV AC environmental controls, sensing temperatures inside buildings, equipment or machinery, and process monitoring and control.The block diagram of Figure 1 shows the major components of the DS18B20. The DS18B20 has four main data components: 1) 64-bit laser ROM, 2) temperature sensor, 3) nonvolatile temperature alarm triggers TH and TL, and 4) a configuration register. The device derives its power from the 1-Wire communication line by storing energy on an internal capacitor during periods of time when the signal line is high and continues to operate off this power source during the low times of the 1-Wire line until it returns high to replenish the parasite (capacitor) supply. As an alternative, the DS18B20 may also be powered from an external 3V - 5.5V supply.Communication to the DS18B20 is via a 1-Wire port. With the 1-Wire port, the memory and control functions will not be available before the ROM function protocol has been established. The master must first provide one of five ROM function commands: 1) Read ROM, 2) Match ROM, 3) Search ROM, 4) Skip ROM, or 5) Alarm Search. These commands operate on the 64-bit laser ROM portion of each device and can single out a specific device if many are present on the 1-Wire line as well as indicate to the bus master how many and what types of devices are present. After a ROM function sequence has been successfully executed, the memory and control functions are accessible and the master may then provide any one of the six memory and control function commands.One control function command instructs the DS18B20 to perform a temperature measurement. The result of this measurement will be placed in the DS18B20’s scratch-pad memory, and may be read by issuing a memory function command which reads the contents of the scratchpad memory. The temperature alarm triggers TH and TL consist of 1 byte EEPROM each. If the alarm search command is not applied to the DS18B20, these registers may be used as general purpose user memory. The scratchpad also contains a configuration byte to set the desired resolution of the temperature to digital conversion. Writing TH, TL, and the configuration byte is done using a memory function command. Read access to these registers is through the scratchpad.All data is read and written least significant bit first.The block diagram (Figure 1) shows the parasite-powered circuitry. This circuitry “steals” power whenever the DQ or VDD pins are high. DQ will provide sufficient power as long as the specified timing and voltage requirements are met (see the section titl ed “1-Wire Bus System”). The advantages of parasite power are twofold: 1) by parasiting off this pin, no local power source is needed for remote sensing of temperature, and 2) the ROM may be read in absence of normal power.In order for the DS18B20 to be able to perform accurate temperature conversions, sufficient power must be provided over the DQ line when a temperature conversion is taking place. Since the operating current of the DS18B20 is up to 1.5 mA, the DQ line will not have sufficient drive due to the 5k pull up resistor. This problem is particularly acute if several DS18B20s are on the same DQ and attempting to convert simultaneously.There are two ways to assure that the DS18B20 has sufficient supply current during its active conversion cycle. The first is to provide a strong pull up on the DQ line whenever temperature conversions or copies to the E2 memory are taking place. This may be accomplished by using a MOSFET to pull the DQ line directly to the power supply as shown in Figure 2. The DQ line must be switched over to the strong pull up within 10 us maximum after issuing any protocol that involves copying to the E2 memory or initiates temperature conversions. When using the parasite power mode, the VDD pin must be tied to ground.Another method of supplying current to the DS18B20 is through the use of an external power supply tied to the VDD pin, as shown in Figure 3. The advantage to this is that the strong pull up is not required on the DQ line, and the bus master need not be tied up holding that line high during temperature conversions. This allows other data traffic on the 1-Wire bus during the conversion time. In addition, any number of DS18B20s may be placed on the 1-Wire bus, and if they all use external power, they may all simultaneously perform temperature conversions by issuing the Skip ROM command and then issuing the Convert T command. Note that as long as the external power supply is active, the GND pin may not be floating.The use of parasite power is not recommended above 100 C, since it may not be able to sustain communications given the higher leakage currents the DS18B20 exhibits at these temperatures. For applications in which such temperatures are likely, it is strongly recommended that VDD be applied to the DS18B20.For situations where the bus master does not know whether the DS18B20s on the bus are parasite powered or supplied with external VDD, a provision is made in the DS18B20 to signal the power supply scheme used. The bus master can determine if any DS18B20 are on the bus which require the strong pull up by sending a Skip ROM protocol, then issuing the read power supply command. After this command is issued, the master then issues read time slots. The DS18B20 wi ll send back “0” on the 1-Wire bus if it is parasite powered; it will send back a “1” if it is powered from the VDD pin. If the master receives a “0,” it knows that it must supply the strong pull up on the DQ line during temperature conversions. See “Memory Command Functions”section for more detail on this command protocol.The DS18B20 has an 8-bit CRC stored in the most significant byte of the 64-bit ROM. The bus master can compute a CRC value from the first 56-bits of the 64-bit ROM and compare it to the value stored within the DS18B20 to determine if the ROM data has been received error-free by the bus master. The equivalent polynomial function of this CRC is:1458+++=X X X CRCThe DS18B20 also generates an 8-bit CRC value using the same polynomial function shown above and provides this value to the bus master to validate the transfer of data bytes. In each case where a CRC is used for data transfer validation, the bus master must calculate a CRC value using the polynomial function given above and compare the calculated value to either the 8-bit CRC value stored in the 64-bit ROM portion of the DS18B20 (for ROM reads) or the 8-bit CRC value computed within the DS18B20(which is read as a ninth byte when the scratchpad is read). The comparison of CRC values and decision to continue with an operation are determined entirely by the bus master. There is no circuitry inside the DS18B20 that prevents a command sequence from proceeding if the CRC stored in or calculated by the DS18B20 does not match the value generated by the bus master.The 1-Wire CRC can be generated using a polynomial generator consisting of a shift register and XOR gates as shown in Figure 6. Additional information about the Dallas 1-Wire Cyclic Redundancy Check is available in Application Note 27 entitled “Understanding and Using Cyclic Redundancy Checks with Dallas Semiconductor Touch Memory Products.”The shift register bits are initialized to 0. Then starting with the least significant bit of the family code, 1 bit at a time is shifted in. After the 8th bit of the family code has been entered, then the serial number is entered. After the 48th bit of the serial number has been entered, the shift register contains the CRC value. Shifting in the 8 bits of CRC should return the shift register to all 0s.中文翻译DS1820 单总线数字温度计DSl820数字温度计提供9位(二进制)温度读数指示器件的温度。

DS18B20资料中英文翻译

DS18B20资料中英文翻译

The DS-18B20 number temperature spreads a feeling machine The DS-18B20 number temperature spreads a feeling machine, the product adoption's United States' DALLAS company produces of DS18 B20 can set net number the temperature spread the feeling machine chip to pack but become and have to bear to whet to bear to touch, the physical volume is small, use convenience, seal to pack a form diverse, be applicable to various narrow and small space equipments number to measure moderate control realm.1、the technique function describe:1.1 special single lines connect a people's method, DS18 B20 while linking with microprocessor only need a line can immediately carry out the double of microprocessor and DS18 B20 toward the communication.1.2 measure scope-55 ℃ ~ +125 ℃ , proper measure resolution's0.5 ℃ .1.3 support several set nets function, several DS18 B20s can merge at unique three on-line, the most can merge 8, if amount was excessive, it would make power supply the power electric voltage over low, result in thus the signal delivers of unsteady, the realizations order to measure more1.4 work the power:3~5V|DC1.5 don't need any outer circle component in the use1.6 measure the result measure a way string with 9~12 numbers line transmission1.7 stai nless steels protect to take care of diameter Φ 61.8 be applicable to DN15~25, DN 40~ DN250 various equipments that lie industrial piping of quality and narrow and small space measure1.9 standards install the thread M10 X1, M12 X1.5, the G 1|2 term chooses1.10 PVC electric cable direct the line or virtuous type ball type connect line box line, the easy to and other electric appliances equipments links.2、Application2.1 products are applicable to cold storage, food Cang, keep a bottle, tele-communications engine room, electric power engine room, cable slot etc. measures moderate control realm2.2 stalk tiles, urn body, the Fang machine, the air condition, waits industrial equipments of narrow and small space to measure a moderate control.2.3 car air condition, refrigerator, cold cabinet, and medium low temperature dry box of etc.s.2.4 provide hot|make cold piping calories to calculate, the central air condition divides a thermal energy to calculate to measure a moderate control with industrial realm3、Product model number and specificationThe model number measures scope to install thread electric cable length to apply pipingThe B20 -55~125s TS-18s have no 1.5 msTS-18B20A -55~125 M10X1 1.5m DN15~25The B20 TS-181|s Bs-55~125ses 2 Gs connects line box DN40~ 60 4、Connect line elucidationThe characteristics special front line connects, needs a line to correspond by letter to order more ability and simplified a distribute type the temperature spread the feeling application didn't need an external component to use data total line power supply, the electric voltage scope has never needed to provide for use the power diagraph temperature scope for the 3.0-5.5 Vs BE-55 ℃ to+125 ℃ .The Fahrenheit is equal hence-67-257 Fahrenheit degree-10 ℃ go to+85 ℃accuracy inside the scope is ±0.5 ℃The temperature spreads a feeling machine's programmable resolution to convert into 12 number formats for 9~12 temperatures biggest be worth to 750 a milli- of second the customer can define of not and easily lose sex temperature to report to the police to establish an application to include a constant temperature control, industrial system, consume electronics product thermometer, or any hot sensitive systemThe number thermometer that describes the DS18 B20 provides9-12(the programmable equipments temperature read a number.The information is disheveled hair to send to|connect through a line from the DS18 B20, so central microprocessor and DS18 B20 only have a per line conjunction.For read and write and the temperature conversion can acquire energy from the data line, don't need to circumscribe the power.Because each DS18 B20 includes a special ordinal number, several ds 18 bs 20 seses can be existed to a total line at the same time.This makes the temperature spread a feeling machine to place in many different places.Its use is a lot of, include an air condition environment control, detect equipments inside the building or machine, and carry on process monitor and control.The DS18 B20 internal structure mainly constitutes to°from thefour-part cent:64 temperatures that only engrave ROM and temperature to spread a feeling machine and don't vaporize report to the police to trigger a machine TH and TL and allocation to deposit a machine.While equiping signal line Gao, the internal capacitor stores an energy from a line and corresponds by letter circuit to the film power supply, and at low electricity even period for film power supply until next Gao Dian Ping's arrival re- refreshes.The power of the DS18 B20 can also.5V electric voltages get from 3 Vs-5s in the exterior.The DS18 B20 adopts front line correspondence to connect.Because the front line correspondence connects, have to previously complete ROM enactment, otherwise memory and control function will can not use.Mainly provide following function to orderany first of a:1、read ROM2、ROM match3、search ROM4、jump ROM5、report to the police a check.These instruction operation the function has no 64 sequences that only engrave ROM of a spare part, can be hanging several spare parts on the front line to make selection a certain spare part, at the same time, the total line can also knowalways on-line hang how much, what kind of equipments.If the instruction successfully makes the DS18 B20 completion temperature measure, the data saves in the saving machine of DS18 B20.The performance of a control function conductor designation DS18 B20 measures.Measure result will be placed in the DS18 B20 memorieses, and can let reading to send out the conductor of remembering the function, reading contents of slice ascend saving machine.The temperature reports to the police to trigger machine TH and TLs to all have one word stanza EEPROM data.If DS18 B20 not the use report to the police to check instruction, these deposit a machine to be a general customer to remember use.Still carry to there is allocation word's the stanza converting by ideal solution temperature number on the slice.Write TH, TL instruction and allocation word stanza makes use of instruction completion that remembers function.Pass to slowly save a machine to read to deposit a machine.All datas read writing all a beginning from the lowest.The DS18 B20 has 4 main data partses:(1)only engrave 64 sequences in ROM are what factory front be only engraved likes, it can see make the address sequence that is the DS18 B20 code.64 alignments that only engrave ROM are:Starting 8(28 Hs) is the product type mark number, immediately after of 48 sequences that is the DS18 B20 oneselfses, last 8 is 56 front circulating redundancy schools to check code.(CRC=X 8+ Xs 5+ Xs 4+s 1)The function that only engraves ROM is to make each DS18 B20 all each not same, so can carry out a purpose that is always on-line to hang to connect several DS18 B20s.(2) the temperature in the DS18 B20 spread a feeling machine to complete the diagraph to the temperature and take 12 conversions as an example:The binary system expanding with 16 signs repairs code to read to count a form to provide, with 0.0625 ℃ |the LSB form express, among them, the S is a sign.The saving machine of DS18 B20 includes high speed to temporary save machine RAM and can give or get an electric shock to wipe in addition to RAM, can give or get an electric shock to wipe in additionto RAM includes temperature to trigger machine TH and TL again, and an allocation deposits a machine.Saving machine ability the integrity really settle the communication of front-line port, the number starts using to write the order of depositing the machine to write into deposit a machine, immediately after can also use order of reading to deposit the machine to confirm these numbers.After confirming can use the order that the replication deposits a machine can give or get an electric shock to wipe to transfering these numbers to in addition to RAM in.While once modifying to deposit the number in the machine, this process can ensure the integrity of number.The high speed temporary saves machine RAM to constitute to°from the saving machine of 8 word stanzas;The first and the second word stanza are temperatures to show.The fourth Sha-ho word stanza is to make duplicate TH and TL, at the same time the fourth Sha-ho number of word stanza can renew;The fifth word stanza is to make duplicate allocation to deposit a machine, the fifth number of word stanza can renew at the same time;6, 7, 8, three word stanzas are calculator oneselfs ing reads that the order that deposit a machine can read the ninth word stanza, this word stanza is eight word stanzas to the front to carry on schools to check.648 ex- oneself codes that is a DS18 B20 that only engrave ROM, next 48 are a continuous number code, 8 of end is to 56 ex- of the CRC schools check.64-the light of engrave ROM and include the function order of 5 ROMs:Read ROM, match ROM, jump up ROM, check to seek ROM and report to the police to check to seek.The DS18 B20 can use external power VDD as well as use the power in the living on of inner part.When the VDD port connects the electric voltage with 3.0 Vs ~Vs-5.5ses is use external power;When the VDD port connects ground used the power in the living on of inner part.No matter is an inner part to live on the power or an external power supply, I|the O line want to connect a 5 K Ω to or soly and up pull electric resistance.Allocation's depositing a machine is the conversion that installs different number to make sure temperature and number.R1, the R0 is the decision of temperature, from the R1, the different combination of R0 can install for 9, 10, 11, 12 temperatures show.So can know a different temperature conversion to should of conversion time, four kinds of resolutions of allocations distinguish to 0.5 ℃ , 0.25 ℃ , 0.125 ℃ and 0.0625 ℃ , factory take installing as 12. DS18 B20 at factory with install for 12, read temperature totally read 16, so the empress is 112 enter make to convert into 10 enter make after at multiply 0.0625 is then measure of temperature, also need to be judged plus or minus.Front 5 piece words are signs, current 5 is 1:00, read of temperature is minus quantity;5 is 0:00, read at present of temperature is plus quantity.16 numbers put from low to Gao Wei.The instruction agrees on code operating instructions:The temperature converts the 44 H start DS18 B20 to carry on a temperature conversionRead to temporary save machine BEH to read to temporary save machine 9 word stanza contentsesWrite temporary and save the machine 4 EHs to write in a data temporary TH of saving the machine and TL word stanzaThe replication temporary saves the machine 48 Hs temporary save the TH of machine and TL word stanza to write E2 RAMRe- adjust the E2 RAM B8's Hs write the E2 TH within RAMs and TL word stanza to arrive to temporary save machine TH and TL word stanza and read that the signal that the B4 H start DS18 B20 of the power supply method sends out the power supply method gives lord CPUThe beginning of DS18 B20 starts to turn.(1) place data line first Gao Dian Ping"1".(2) postpone(what the time request isn't very strict, but possibly a little bit shorter)(3) the data line pull a low electricity even"0".(4) postpone 750.(the horary time scope can from 480-960)(5) the data line pull Gao Dian Ping"1".(6) wait for while postponing(if is early to start to become anachievement then in 15-60 time inside produce a low electricity that is returned by the DS18 B20 even"0".Can make sure its existence according to the status, but should notice can not be infinitely carry on waiting for, otherwise will make procedure get into to die circulating, so control while wanting to carry on to be super).(7) if CPU read the data is on-line low to give or get an electric shock even"0" after, while also needing to do to postpone time for it to postpones from send out of Gao Dian Ping start to calculate to at least want 480.(8) pull data line again Gao Dao Gao to end after giving or getting an electric shock is even"1".DS-18B20 数字温度传感器DS-18B20数字温度传感器,该产品采用美国DALLAS公司生产的DS18B20可组网数字温度传感器芯片封装而成,具有耐磨耐碰,体积小,使用方便,封装形式多样,适用于各种狭小空间设备数字测温和控制领域。

数字温度传感器毕业论文中英文资料外文翻译文献[管理资料]

数字温度传感器毕业论文中英文资料外文翻译文献[管理资料]

毕业论文中英文资料外文翻译文献外文资料DS1722 Digital ThermometerWith scientific and technological progress and development of the types of temperature sensors increasingly wide range of application of the increasingly widespread, and the beginning analog toward digital, single-bus, dual-bus and bus-3 direction. And the number of temperature sensors because they apply to all microprocessor interface consisting of automatic temperature control system simulation can be overcome sensor and microprocessor interface need signal conditioning circuit and A / D converters advant ages of the drawbacks, has been widely used in industrial control, electronic transducers, medical equipment and other temperature control system. Among them, which are more representative of a digital temperature sensor DS18B20, MAX6575, the DS1722, MAX6636 other. This paper introduces the DS1722 digital temperature sensor characteristics, the use of the method and its timing. Internal structure and other relevant content.FEATURES:Temperature measurements require no external components;Measures temperatures from -55°C to +120°C. Fahrenheit equivalent is -67°F to +248°F;Thermometer accuracy is ±°C;Thermometer resolution is configurable from 8 to 12 bits (°C to °C resolution);Data is read from/written to via a Motorola Serial Peripheral Interface (SPI) or standard 3-wire serial interface;Wide analog power supply range ( - );Separate digital supply allows for logic;Available in an 8-pin SOIC (150 mil), 8-pin USOP, and flip chip package;PIN ASSIGNMENTFIGURE 1 PIN ASSIGNMENTPIN DESCRIPTION:SERMODE - Serial Interface Mode.CE - Chip Enable.SCLK - Serial Clock.GND – Ground.VDDA - Analog Supply Voltage.SDO - Serial Data Out.SDI - Serial Data In.VDDD - Digital Supply Voltage.DESCRIPTION:The DS1722 Digital Thermometer and Thermostat with SPI/3-Wire Interface provides temperature readings which indicate the temperature of the device. No additional components are required; the device is truly a temperature-to-digital converter. Temperature readings are communicated from the DS1722 over a Motorola SPI interface or a standard 3-wire serial interface. The choice of interface standard is selectable by the user. For applications that require greater temperature resolution, the user can adjust the readout resolution from 8 to 12 bits. This is particularly useful in applications where thermal runaway conditions must be detected quickly.For application flexibility, the DS1722 features a wide analog supply rail of - . A separate digital supply allows a range of to . The DS1722 is available in an 8-pin SOIC (150-mil), 8-pin USOP, and flip chip package.Applications for the DS1722 include personal computers/servers/workstations, cellular telephones, office equipment, or any thermally-sensitive system.OVERVIEW:A block diagram of the DS1722 is shown in Figure 2. The DS1722 consists offour major components:1. Precision temperature sensor.2. Analog-to-digital converter.3. SPI/3-wire interface electronics.4. Data registers.The factory-calibrated temperature sensor requires no external components. The DS1722 is in a power conserving shutdown state upon power-up. After power-up, the user may alter the configuration register to place the device in a continuous temperature conversion mode or in a one-shot conversion mode. In the continuous conversion mode, the DS1722 continuously converts the temperature and stores the result in the temperature register. As conversions are performed in the background, reading the temperature register does not affect the conversion in progress. In the one-shot temperature conversion mode, the DS1722 will perform one temperature conversion, store the result in the temperature register, and then eturn to the shutdown state. This conversion mode is ideal for power sensitive applications. More information on the configuration register is contained in the “OPERATION-Programming”section. The temperature conversion results will have a default resolution of 9 bits. In applications where small incremental temperature changes are critical, the user can change the conversion resolution from 9 bits to 8, 10, 11, or 12. This is accomplished by programming the configuration register. Each additional bit of resolution approximately doubles the conversion time. The DS1722 can communicate using either a Motorola Serial Peripheral Interface (SPI) or standard 3-wire interface. The user can select either communication standard through the SERMODE pin, tying it to VDDD for SPI and to ground for 3-wire. The device contains both an analog supply voltage and a digital supply voltage (VDDA and VDDD, respectively). The analog supply powers the device for operation while the digital supply provides the top rails for the digital inputs and outputs. The DS1722 was designed to be Logic-Ready.DS1722 FUNCTIONAL BLOCK DIAGRAM Figure 2OPERATION-Measuring Temperature:The core of DS1722 functionality is its direct-to-digital temperature sensor. The DS1722 measures temperature through the use of an on-chip temperature measurement technique with an operating range from -55°to +120°C. The device powers up in a power-conserving shutdown mode. After power-up, the DS1722 may be placed in a continuous conversion mode or in a one-shot conversion mode. In the continuous conversion mode, the device continuously computes the temperature and stores the most recent result in the temperature register at addresses 01h (LSB) and 02h (MSB). In the one-shot conversion mode, the DS1722 performs one temperature conversion and then returns to the shutdown mode, storing temperature in the temperature register. Details on how to change the setting after power up are contained in the “OPERATION-Programming”section. The resolution of the temperature conversion is configurable (8, 9, 10, 11, or 12 bits), with 9-bit readings the default state. This equates to a temperature resolution of °C, °C, °C, °C, or °C. Following each conversion, thermal data is stored in the thermometer register in two’s complement format; the information can be retrieved over the SPI or 3-wire interface with the address set to the temperature register, 01h (LSB) and then 02h (MSB). Table 2 describesthe exact relationship of output data to measured temperature. The table assumes the DS1722 is configured for 12-bit resolution; if the evince is configured in a lower resolution mode, those bits will contain 0s. The data is transmitted serially over the digital interface, MSB first for SPI communication and LSB first for 3-wire communication. The MSB of the temperature register contains the “sign” (S) bit, denoting whether the temperature is positive or negative. For Fahrenheit usage, a lookup table or conversion routine must be used.AddressLocation S 2625242322212002h MSB (unit = ℃) LSB2-12-22-32-40 0 0 0 01hTEMPERATURE DIGITAL OUTPUT(BINARY) DIGITAL OUTPUT(HEX)+120℃0111 1000 0000 0000 7800h+ 0001 1001 0001 0000 1910h+ 0000 1010 0010 0000 0a20h+ 0000 0000 1000 0000 0080h0 0000 0000 0000 0000 0000h1111 1111 1000 0000 Ff80h1111 0101 1110 0000 F5e0h1110 0110 1111 0000 E6f0h-55 1100 1001 0000 0000 C900h OPERATION-Programming:The area of interest in programming the DS1722 is the Configuration register. All programming is done via the SPI or 3-wire communication interface by selecting the appropriate address of the desired register location. Table 3 illustrates the addresses for the two registers (configuration and temperature) of the DS1722.Register Address Structure Table 3CONFIGURATION REGISTER PROGRAMMING:The configuration register is accessed in the DS1722 with the 00h address for reads and the 80h address for writes. Data is read from or written to the configuration register MSB first for SPI communication and LSB first for 3-wire communication. The format of the register is illustrated in Figure 2. The effect each bit has on DS1722 functionality is described below along with the power-up state of the bit. The entire register is volatile, and thus it will power-up in the default state.CONFIGURATION/STATUS REGISTER Figure 21SHOT = One-shot temperature conversion bit. If the SD bit is "1", (continuous temperature conversions are not taking place), a "1" written to the 1SHOT bit will cause the DS1722 to perform one temperature conversion and store the results in the temperature register at addresses 01h (LSB) and 02h (MSB). The bit will clear itself to "0" upon completion of the temperature conversion. The user has read/write access to the 1SHOT bit, although writes to this bit will be ignored if the SD bit is a "0", (continuous conversion mode). The power-up default of the one-shot bit is "0".R0, R1, R2 = Thermometer resolution bits. Table 4 below defines the resolution of the digital thermometer, based on the settings of these 3 bits. There is a direct tradeoff between resolution and conversion time, as depicted in the AC Electrical Characteristics. The user has read/write access to the R2, R1 and R0 bits and the power-up default state is R2="0", R1="0", and R0="1" (9-bit conversions).THERMOMETER RESOLUTION CONFIGURATION Table 4SD = Shutdown bit. If SD is "0", the DS1722 will continuously perform temperature conversions and store the last completed result in the temperature register. If SD is changed to a "1", the conversion in progress will be completed and stored and then the device will revert to a low-power shutdown mode. The communication port remains active. The user has read/write access to the SD bit and the power-up default is "1" (shutdown mode).SERIAL INTERFACE:The DS1722 offers the flexibility to choose between two serial interface modes. The DS1722 can communicate with the SPI interface or with a standard 3-wire interface. The interface method used is determined by the SERMODE pin. When this pin is connected to VDDD SPI communication is selected. When this pin is connected to ground, standard 3-wire communication is selected.SERIAL PERIPHERAL INTERFACE (SPI):The serial peripheral interface (SPI) is a synchronous bus for address and data transfer. The SPI mode of serial communication is selected by tying the SERMODE pin to VDDD. Four pins are used for the SPI. The four pins are the SDO (Serial Data Out), SDI (Serial Data In), CE (Chip Enable), and SCLK (Serial Clock). The DS1722 is the slave device in an SPI application, with the microcontroller being the master. The SDI and SDO pins are the serial data input and output pins for the DS1722, respectively. The CE input is used to initiate and terminate a data transfer. The SCLK pin is used to synchronize data movement between the master (microcontroller) and the slave (DS1722) devices. The shift clock (SCLK), which is generated by the microcontroller, is active only when CE is high and during address and data transfer to any device on the SPI bus. The inactive clock polarity is programmable in somemicrocontrollers. The DS1722 offers an important feature in that the level of the inactive clock is determined by sampling SCLK when CE becomes active. Therefore, either SCLK polarity can be accommodated. There is one clock for each bit transferred. Address and data bits are transferred in groups of eight, MSB first.3-WIRE SERIAL DATA BUS:The 3-wire communication mode operates similar to the SPI mode. However, in 3-wire mode, there is one bi-directional I/O instead of separate data in and data out signals. The 3-wire consists of the I/O (SDI and SDO pins tied together), CE, and SCLK pins. In 3-wire mode, each byte is shifted in LSB first unlike SPI mode where each byte is shifted in MSB first. As is the case with the SPI mode, an address byte is written to the device followed by a single data byte or multiple data bytes.外文资料译文DS1722数字温度传感器随着科学技术的不断进步和发展,温度传感器的种类日益繁多,应用逐渐广泛,并且开始由模拟式向着数字式、单总线式、双总线式和三总线式发展。

毕业设计外文翻译:DS18S20 数字温度传感器

毕业设计外文翻译:DS18S20 数字温度传感器

特征。

独特的单线接口只需1 个接口引脚即可通信。

每个器件有独特的 64位序列码,储存在面板的 ROM 中。

多点测量性能简化了分布式温度的测量。

不需要任何外围器件。

能从数据线获得工作能源。

功率补给范围是从 5.5 V 到 3.0 V。

处理温度范围从 55 ℃到+125 ℃ (从67 ℉到 +257 ℉)。

从 10 ℃到 +85 ℃,误差不超过0.5 ℃。

9位的温度读数。

750 ms 的温度变化反应时间 (最大.)。

用户自定义告警设定。

指令监测和超出额定温度测量范围的地址器件的搜索 (温度警报条件)。

应用范围:包括温度调节装置的控制,工业的系统,消费者产品,温度计, 或任何的热敏感系统管脚描述GND –接地DQ- 数据输入/输出VDD-补给电压收据控制 - 没有连接描述DS18S20 数字温度传感器提供 9 位C数字温度测量而且有一个稳定的用户自定义告警装置,可设计较高和较低的引发点。

DS18S20在一个 1线总线之上数据传送只需要一个数据线 ( 和地线)就可保持与一个中央的微处理器的数据传输。

资讯科技有从 55C到+125 C的温度操作范围而且对从 10C到+85C的的范围内,有0.5 C的温度分辨力。

除此之外, DS18S20的能源供给可直接从数据线获得(寄生功率),而不需要外部的功率供给能源。

每个DS18S20 有独特的 64位序列码, 允许多个 DS18S20s 在同一条1线总线上工作; 因此, 在大的区域使用一个微处理器控制许多 DS18S20s 是方便的。

能受益于这一个特征的应用包括在HVAC环境下的温度控制,在建筑物,仪器或机器里的温度监控系统, 和进程监测控制系统。

概观图 1 所示的是DS18S20的一个块图表,而且管脚的描述表 1也已经给出。

那 64位ROM存储器件有独特的序列编码。

便笺式寄存器包含来自温度传感器的那一片存储器传输出的2个字节的温度记录。

除此之外,便笺式寄存器提供 1字节高位和低位的告警记录(TH 和 TL) 。

DS18B20温度传感器资料

DS18B20温度传感器资料

FEATURES Unique 1-Wire interface requires only one port pin for communicationMultidrop capability simplifies distributed temperature sensing applications Requires no external componentsCan be powered from data line. Power supply range is 3.0V to 5.5VZero standby power requiredMeasures temperatures from -55°C to +125°C. Fahrenheit equivalent is -67°F to +257°F±0.5°C accuracy from -10°C to +85°C Thermometer resolution is programmable from 9 to 12 bitsConverts 12-bit temperature to digital word in 750 ms (max.)User-definable, nonvolatile temperature alarm settingsAlarm search command identifies and addresses devices whose temperature is outside of programmed limits (temperature alarm condition)Applications include thermostatic controls,industrial systems, consumer products,thermometers, or any thermally sensitive systemPIN ASSIGNMENTPIN DESCRIPTIONGND - Ground DQ - Data In/OutV DD - Power Supply Voltage NC- No ConnectDESCRIPTIONThe DS18B20 Digital Thermometer provides 9 to 12-bit (configurable) temperature readings which indicate the temperature of the device.Information is sent to/from the DS18B20 over a 1-Wire interface, so that only one wire (and ground)needs to be connected from a central microprocessor to a DS18B20. Power for reading, writing, and performing temperature conversions can be derived from the data line itself with no need for an external power source.Because each DS18B20 contains a unique silicon serial number, multiple DS18B20s can exist on the same 1-Wire bus. This allows for placing temperature sensors in many different places. Applications where this feature is useful include HVAC environmental controls, sensing temperatures inside buildings,equipment or machinery, and process monitoring and control.DS18B20Programmable Resolution 1-Wire ®Digital ThermometerG N D D Q V DDDS18B20 To-92PackageNC NC NC GNDNC NCV DD DQDS18B20Z8-Pin SOIC (150 mil)DETAILED PIN DESCRIPTION Table 1PIN8PIN SOICPINTO92SYMBOL DESCRIPTION51GND Ground.42DQ Data Input/Output pin. For 1-Wire operation: Opendrain. (See “Parasite Power” section.)33V DD Optional V DD pin. See “Parasite Power” section fordetails of connection. V DD must be grounded foroperation in parasite power mode.DS18B20Z (8-pin SOIC): All pins not specified in this table are not to be connected.OVERVIEWThe block diagram of Figure 1 shows the major components of the DS18B20. The DS18B20 has four main data components: 1) 64-bit lasered ROM, 2) temperature sensor, 3) nonvolatile temperature alarm triggers TH and TL, and 4) a configuration register. The device derives its power from the 1-Wire communication line by storing energy on an internal capacitor during periods of time when the signal line is high and continues to operate off this power source during the low times of the 1-Wire line until it returns high to replenish the parasite (capacitor) supply. As an alternative, the DS18B20 may also be powered from an external 3 volt - 5.5 volt supply.Communication to the DS18B20 is via a 1-Wire port. With the 1-Wire port, the memory and control functions will not be available before the ROM function protocol has been established. The master must first provide one of five ROM function commands: 1) Read ROM, 2) Match ROM, 3) Search ROM, 4) Skip ROM, or 5) Alarm Search. These commands operate on the 64-bit lasered ROM portion of each device and can single out a specific device if many are present on the 1-Wire line as well as indicate to the bus master how many and what types of devices are present. After a ROM function sequence has been successfully executed, the memory and control functions are accessible and the master may then provide any one of the six memory and control function commands.One control function command instructs the DS18B20 to perform a temperature measurement. The result of this measurement will be placed in the DS18B20’s scratch-pad memory, and may be read by issuing a memory function command which reads the contents of the scratchpad memory. The temperature alarm triggers TH and TL consist of 1 byte EEPROM each. If the alarm search command is not applied to the DS18B20, these registers may be used as general purpose user memory. The scratchpad also contains a configuration byte to set the desired resolution of the temperature to digital conversion. Writing TH, TL, and the configuration byte is done using a memory function command. Read access to these registers is through the scratchpad. All data is read and written least significant bit first.DS18B20 BLOCK DIAGRAM Figure 1PARASITE POWERThe block diagram (Figure 1) shows the parasite-powered circuitry. This circuitry “steals” power whenever the DQ or V DD pins are high. DQ will provide sufficient power as long as the specified timing and voltage requirements are met (see the section titled “1-Wire Bus System”). The advantages of parasite power are twofold: 1) by parasiting off this pin, no local power source is needed for remote sensing of temperature, and 2) the ROM may be read in absence of normal power.In order for the DS18B20 to be able to perform accurate temperature conversions, sufficient power must be provided over the DQ line when a temperature conversion is taking place. Since the operating current of the DS18B20 is up to 1.5 mA, the DQ line will not have sufficient drive due to the 5k pullup resistor.This problem is particularly acute if several DS18B20s are on the same DQ and attempting to convert simultaneously.There are two ways to assure that the DS18B20 has sufficient supply current during its active conversion cycle. The first is to provide a strong pullup on the DQ line whenever temperature conversions or copies to the E 2 memory are taking place. This may be accomplished by using a MOSFET to pull the DQ line directly to the power supply as shown in Figure 2. The DQ line must be switched over to the strong pull-up within 10 µs maximum after issuing any protocol that involves copying to the E 2 memory or initiates temperature conversions. When using the parasite power mode, the V DD pin must be tied to ground.Another method of supplying current to the DS18B20 is through the use of an external power supply tied to the V DD pin, as shown in Figure 3. The advantage to this is that the strong pullup is not required on the DQ line, and the bus master need not be tied up holding that line high during temperature conversions.This allows other data traffic on the 1-Wire bus during the conversion time. In addition, any number of DS18B20s may be placed on the 1-Wire bus, and if they all use external power, they may all simultaneously perform temperature conversions by issuing the Skip ROM command and then issuing the Convert T command. Note that as long as the external power supply is active, the GND pin may not be floating.The use of parasite power is not recommended above 100°C, since it may not be able to sustain communications given the higher leakage currents the DS18B20 exhibits at these temperatures. For applications in which such temperatures are likely, it is strongly recommended that V DD be applied to the DS18B20.DQVFor situations where the bus master does not know whether the DS18B20s on the bus are parasite powered or supplied with external V DD, a provision is made in the DS18B20 to signal the power supply scheme used. The bus master can determine if any DS18B20s are on the bus which require the strong pullup by sending a Skip ROM protocol, then issuing the read power supply command. After this command is issued, the master then issues read time slots. The DS18B20 will send back “0” on the 1-Wire bus if it is parasite powered; it will send back a “1” if it is powered from the V DD pin. If the master receives a “0,” it knows that it must supply the strong pullup on the DQ line during temperature conversions. See “Memory Command Functions” section for more detail on this command protocol. STRONG PULLUP FOR SUPPLYING DS18B20 DURING TEMPERATURE CONVERSION Figure 2USING V DD TO SUPPLY TEMPERATURE CONVERSION CURRENT Figure 3TO OTHER 1-WIRE DEVICESOPERATION - MEASURING TEMPERATUREThe core functionality of the DS18B20 is its direct-to-digital temperature sensor. The resolution of the DS18B20 is configurable (9, 10, 11, or 12 bits), with 12-bit readings the factory default state. This equates to a temperature resolution of 0.5°C, 0.25°C, 0.125°C, or 0.0625°C. Following the issuance of the Convert T [44h] command, a temperature conversion is performed and the thermal data is stored in the scratchpad memory in a 16-bit, sign-extended two’s complement format. The temperature information can be retrieved over the 1-Wire interface by issuing a Read Scratchpad [BEh] command once the conversion has been performed. The data is transferred over the 1-Wire bus, LSB first. The MSB of the temperature register contains the “sign” (S) bit, denoting whether the temperature is positive or negative.Table 2 describes the exact relationship of output data to measured temperature. The table assumes 12-bit resolution. If the DS18B20 is configured for a lower resolution, insignificant bits will contain zeros. For Fahrenheit usage, a lookup table or conversion routine must be used.Temperature/Data Relationships Table 2232221202-12-22-32-4LSBMSb(unit = °C)LSbS S S S S262524MSBTEMPERATURE DIGITAL OUTPUT(Binary)DIGITAL OUTPUT (Hex)+125°C0000 0111 1101 000007D0h+85°C0000 0101 0101 00000550h*+25.0625°C0000 0001 1001 00010191h+10.125°C0000 0000 1010 001000A2h+0.5°C0000 0000 0000 10000008h0°C0000 0000 0000 00000000h-0.5°C1111 1111 1111 1000FFF8h-10.125°C1111 1111 0101 1110FF5Eh-25.0625°C1111 1110 0110 1111FF6Fh-55°C1111 1100 1001 0000FC90h*The power on reset register value is +85°C.OPERATION - ALARM SIGNALINGAfter the DS18B20 has performed a temperature conversion, the temperature value is compared to the trigger values stored in TH and TL. Since these registers are 8-bit only, bits 9-12 are ignored for comparison. The most significant bit of TH or TL directly corresponds to the sign bit of the 16-bit temperature register. If the result of a temperature measurement is higher than TH or lower than TL, an alarm flag inside the device is set. This flag is updated with every temperature measurement. As long as the alarm flag is set, the DS18B20 will respond to the alarm search command. This allows many DS18B20s to be connected in parallel doing simultaneous temperature measurements. If somewhere the temperature exceeds the limits, the alarming device(s) can be identified and read immediately without having to read non-alarming devices.64-BIT LASERED ROMEach DS18B20 contains a unique ROM code that is 64-bits long. The first 8 bits are a 1-Wire family code (DS18B20 code is 28h). The next 48 bits are a unique serial number. The last 8 bits are a CRC of the first 56 bits. (See Figure 4.) The 64-bit ROM and ROM Function Control section allow the DS18B20 to operate as a 1-Wire device and follow the 1-Wire protocol detailed in the section “1-Wire Bus System.” The functions required to control sections of the DS18B20 are not accessible until the ROM function protocol has been satisfied. This protocol is described in the ROM function protocol flowchart (Figure 5). The 1-Wire bus master must first provide one of five ROM function commands: 1) Read ROM, 2) Match ROM, 3) Search ROM, 4) Skip ROM, or 5) Alarm Search. After a ROM function sequence has been successfully executed, the functions specific to the DS18B20 are accessible and the bus master may then provide one of the six memory and control function commands.CRC GENERATIONThe DS18B20 has an 8-bit CRC stored in the most significant byte of the 64-bit ROM. The bus master can compute a CRC value from the first 56-bits of the 64-bit ROM and compare it to the value stored within the DS18B20 to determine if the ROM data has been received error-free by the bus master. The equivalent polynomial function of this CRC is:CRC = X8 + X5 + X4 + 1The DS18B20 also generates an 8-bit CRC value using the same polynomial function shown above and provides this value to the bus master to validate the transfer of data bytes. In each case where a CRC is used for data transfer validation, the bus master must calculate a CRC value using the polynomial function given above and compare the calculated value to either the 8-bit CRC value stored in the 64-bit ROM portion of the DS18B20 (for ROM reads) or the 8-bit CRC value computed within the DS18B20 (which is read as a ninth byte when the scratchpad is read). The comparison of CRC values and decision to continue with an operation are determined entirely by the bus master. There is no circuitry inside the DS18B20 that prevents a command sequence from proceeding if the CRC stored in or calculated by the DS18B20 does not match the value generated by the bus master.The 1-Wire CRC can be generated using a polynomial generator consisting of a shift register and XOR gates as shown in Figure 6. Additional information about the Dallas 1-Wire Cyclic Redundancy Check is available in Application Note 27 entitled “Understanding and Using Cyclic Redundancy Checks with Dallas Semiconductor Touch Memory Products.”The shift register bits are initialized to 0. Then starting with the least significant bit of the family code, 1 bit at a time is shifted in. After the 8th bit of the family code has been entered, then the serial number is entered. After the 48th bit of the serial number has been entered, the shift register contains the CRC value. Shifting in the 8 bits of CRC should return the shift register to all 0s.64-BIT LASERED ROM Figure 48-BIT CRC CODE48-BIT SERIAL NUMBER 8-BIT FAMILY CODE(28h)MSB LSB MSB LSB MSB LSBROM FUNCTIONS FLOW CHART Figure 51-WIRE CRC CODE Figure 6MEMORYThe DS18B20’s memory is organized as shown in Figure 8. The memory consists of a scratchpad RAM and a nonvolatile, electrically erasable (E 2) RAM, which stores the high and low temperature triggers TH and TL, and the configuration register. The scratchpad helps insure data integrity when communicating over the 1-Wire bus. Data is first written to the scratchpad using the Write Scratchpad [4Eh] command.It can then be verified by using the Read Scratchpad [BEh] command. After the data has been verified, a Copy Scratchpad [48h] command will transfer the data to the nonvolatile (E 2) RAM. This process insures data integrity when modifying memory. The DS18B20 EEPROM is rated for a minimum of 50,000writes and 10 years data retention at T = +55°C.The scratchpad is organized as eight bytes of memory. The first 2 bytes contain the LSB and the MSB of the measured temperature information, respectively. The third and fourth bytes are volatile copies of TH and TL and are refreshed with every power-on reset. The fifth byte is a volatile copy of the configuration register and is refreshed with every power-on reset. The configuration register will be explained in more detail later in this section of the datasheet. The sixth, seventh, and eighth bytes are used for internal computations, and thus will not read out any predictable pattern.It is imperative that one writes TH, TL, and config in succession; i.e. a write is not valid if one writes only to TH and TL, for example, and then issues a reset. If any of these bytes must be written, all three must be written before a reset is issued.There is a ninth byte which may be read with a Read Scratchpad [BEh] command. This byte contains a cyclic redundancy check (CRC) byte which is the CRC over all of the eight previous bytes. This CRC is implemented in the fashion described in the section titled “CRC Generation”.Configuration RegisterThe fifth byte of the scratchpad memory is the configuration register.It contains information which will be used by the device to determine the resolution of the temperature to digital conversion. The bits are organized as shown in Figure 7.DS18B20 CONFIGURATION REGISTER Figure 70R1R011111MSbLSbBits 0-4 are don’t cares on a write but will always read out “1”.Bit 7 is a don’t care on a write but will always read out “0”.R0, R1: Thermometer resolution bits. Table 3 below defines the resolution of the digital thermometer,based on the settings of these 2 bits. There is a direct tradeoff between resolution and conversion time, as depicted in the AC Electrical Characteristics. The factory default of these EEPROM bits is R0=1 and R1=1 (12-bit conversions).Thermometer Resolution Configuration Table 3R1R0Thermometer Resolution Max ConversionTime009 bit 93.75 ms (t conv/8)0110 bit 187.5 ms (t conv /4)1011 bit 375 ms (t conv /2)1112 bit750 ms (t conv )DS18B20 MEMORY MAP Figure 8SCRATCHPADBYTE012345678E 2RAM1-WIRE BUS SYSTEMThe 1-Wire bus is a system which has a single bus master and one or more slaves. The DS18B20 behaves as a slave. The discussion of this bus system is broken down into three topics: hardware configuration, transaction sequence, and 1-Wire signaling (signal types and timing).HARDWARE CONFIGURATIONThe 1-Wire bus has only a single line by definition; it is important that each device on the bus be able to drive it at the appropriate time. To facilitate this, each device attached to the 1-Wire bus must have open drain or 3-state outputs. The 1-Wire port of the DS18B20 (DQ pin) is open drain with an internal circuit equivalent to that shown in Figure 9. A multidrop bus consists of a 1-Wire bus with multiple slaves attached. The 1-Wire bus requires a pullup resistor of approximately 5 kΩ.HARDWARE CONFIGURATION Figure 9The idle state for the 1-Wire bus is high. If for any reason a transaction needs to be suspended, the bus MUST be left in the idle state if the transaction is to resume. Infinite recovery time can occur between bits so long as the 1-Wire bus is in the inactive (high) state during the recovery period. If this does not occur and the bus is left low for more than 480 µs, all components on the bus will be reset. TRANSACTION SEQUENCEThe protocol for accessing the DS18B20 via the 1-Wire port is as follows:InitializationROM Function CommandMemory Function CommandTransaction/DataINITIALIZATIONAll transactions on the 1-Wire bus begin with an initialization sequence. The initialization sequence consists of a reset pulse transmitted by the bus master followed by presence pulse(s) transmitted by the slave(s).The presence pulse lets the bus master know that the DS18B20 is on the bus and is ready to operate. For more details, see the “1-Wire Signaling” section.ROM FUNCTION COMMANDSOnce the bus master has detected a presence, it can issue one of the five ROM function commands. All ROM function commands are 8 bits long. A list of these commands follows (refer to flowchart in Figure 5):Read ROM [33h]This command allows the bus master to read the DS18B20’s 8-bit family code, unique 48-bit serial number, and 8-bit CRC. This command can only be used if there is a single DS18B20 on the bus. If more than one slave is present on the bus, a data collision will occur when all slaves try to transmit at the same time (open drain will produce a wired AND result).Match ROM [55h]The match ROM command, followed by a 64-bit ROM sequence, allows the bus master to address a specific DS18B20 on a multidrop bus. Only the DS18B20 that exactly matches the 64-bit ROM sequence will respond to the following memory function command. All slaves that do not match the 64-bit ROM sequence will wait for a reset pulse. This command can be used with a single or multiple devices on the bus.Skip ROM [CCh]This command can save time in a single drop bus system by allowing the bus master to access the memory functions without providing the 64-bit ROM code. If more than one slave is present on the bus and a Read command is issued following the Skip ROM command, data collision will occur on the bus as multiple slaves transmit simultaneously (open drain pulldowns will produce a wired AND result). Search ROM [F0h]When a system is initially brought up, the bus master might not know the number of devices on the 1-Wire bus or their 64-bit ROM codes. The search ROM command allows the bus master to use a process of elimination to identify the 64-bit ROM codes of all slave devices on the bus.Alarm Search [ECh]The flowchart of this command is identical to the Search ROM command. However, the DS18B20 will respond to this command only if an alarm condition has been encountered at the last temperature measurement. An alarm condition is defined as a temperature higher than TH or lower than TL. The alarm condition remains set as long as the DS18B20 is powered up, or until another temperature measurement reveals a non-alarming value. For alarming, the trigger values stored in EEPROM are taken into account. If an alarm condition exists and the TH or TL settings are changed, another temperature conversion should be done to validate any alarm conditions.Example of a ROM SearchThe ROM search process is the repetition of a simple three-step routine: read a bit, read the complement of the bit, then write the desired value of that bit. The bus master performs this simple, three-step routine on each bit of the ROM. After one complete pass, the bus master knows the contents of the ROM in one device. The remaining number of devices and their ROM codes may be identified by additional passes.The following example of the ROM search process assumes four different devices are connected to the same 1-Wire bus. The ROM data of the four devices is as shown:ROM100110101...ROM210101010...ROM311110101...ROM400010001...The search process is as follows:1.The bus master begins the initialization sequence by issuing a reset pulse. The slave devices respondby issuing simultaneous presence pulses.2.The bus master will then issue the Search ROM command on the 1-Wire bus.3.The bus master reads a bit from the 1-Wire bus. Each device will respond by placing the value of thefirst bit of their respective ROM data onto the 1-Wire bus. ROM1 and ROM4 will place a 0 onto the 1-Wire bus, i.e., pull it low. ROM2 and ROM3 will place a 1 onto the 1-Wire bus by allowing the line to stay high. The result is the logical AND of all devices on the line, therefore the bus master sees a 0. The bus master reads another bit. Since the Search ROM data command is being executed, all of the devices on the 1-Wire bus respond to this second read by placing the complement of the first bit of their respective ROM data onto the 1-Wire bus. ROM1 and ROM4 will place a 1 onto the 1-Wire, allowing the line to stay high. ROM2 and ROM3 will place a 0 onto the 1-Wire, thus it will be pulled low. The bus master again observes a 0 for the complement of the first ROM data bit. The bus master has determined that there are some devices on the 1-Wire bus that have a 0 in the first position and others that have a 1.The data obtained from the two reads of the three-step routine have the following interpretations:00There are still devices attached which have conflicting bits in this position.01All devices still coupled have a 0-bit in this bit position.10All devices still coupled have a 1-bit in this bit position.11There are no devices attached to the 1-Wire bus.4.The bus master writes a 0. This deselects ROM2 and ROM3 for the remainder of this search pass,leaving only ROM1 and ROM4 connected to the 1-Wire bus.5.The bus master performs two more reads and receives a 0-bit followed by a 1-bit. This indicates thatall devices still coupled to the bus have 0s as their second ROM data bit.6.The bus master then writes a 0 to keep both ROM1 and ROM4 coupled.7.The bus master executes two reads and receives two 0-bits. This indicates that both 1-bits and 0-bitsexist as the 3rd bit of the ROM data of the attached devices.8.The bus master writes a 0-bit. This deselects ROM1, leaving ROM4 as the only device stillconnected.9.The bus master reads the remainder of the ROM bits for ROM4 and continues to access the part ifdesired. This completes the first pass and uniquely identifies one part on the 1-Wire bus.10.The bus master starts a new ROM search sequence by repeating steps 1 through 7.11.The bus master writes a 1-bit. This decouples ROM4, leaving only ROM1 still coupled.12.The bus master reads the remainder of the ROM bits for ROM1 and communicates to the underlyinglogic if desired. This completes the second ROM search pass, in which another of the ROMs was found.13.The bus master starts a new ROM search by repeating steps 1 through 3.14.The bus master writes a 1-bit. This deselects ROM1 and ROM4 for the remainder of this search pass,leaving only ROM2 and ROM3 coupled to the system.15.The bus master executes two Read time slots and receives two 0s.16.The bus master writes a 0-bit. This decouples ROM3 leaving only ROM2.17.The bus master reads the remainder of the ROM bits for ROM2 and communicates to the underlyinglogic if desired. This completes the third ROM search pass, in which another of the ROMs was found.18.The bus master starts a new ROM search by repeating steps 13 through 15.19.The bus master writes a 1-bit. This decouples ROM2, leaving only ROM3.20.The bus master reads the remainder of the ROM bits for ROM3 and communicates to the underlyinglogic if desired. This completes the fourth ROM search pass, in which another of the ROMs was found.NOTE:The bus master learns the unique ID number (ROM data pattern) of one 1-Wire device on each ROM Search operation. The time required to derive the part’s unique ROM code is:960 µs + (8 + 3 x 64) 61 µs = 13.16 msThe bus master is therefore capable of identifying 75 different 1-Wire devices per second.I/O SIGNALINGThe DS18B20 requires strict protocols to insure data integrity. The protocol consists of several types of signaling on one line: reset pulse, presence pulse, write 0, write 1, read 0, and read 1. All of these signals, with the exception of the presence pulse, are initiated by the bus master.The initialization sequence required to begin any communication with the DS18B20 is shown in Figure 11. A reset pulse followed by a presence pulse indicates the DS18B20 is ready to send or receive data given the correct ROM command and memory function command.The bus master transmits (TX) a reset pulse (a low signal for a minimum of 480 µs). The bus master then releases the line and goes into a receive mode (RX). The 1-Wire bus is pulled to a high state via the 5k pullup resistor. After detecting the rising edge on the DQ pin, the DS18B20 waits 15-60 µs and then transmits the presence pulse (a low signal for 60-240 µs).MEMORY COMMAND FUNCTIONSThe following command protocols are summarized in Table 4, and by the flowchart of Figure 10.Write Scratchpad [4Eh]This command writes to the scratchpad of the DS18B20, starting at the TH register. The next 3 bytes written will be saved in scratchpad memory at address locations 2 through 4. All 3 bytes must be written before a reset is issued.Read Scratchpad [BEh]This command reads the contents of the scratchpad. Reading will commence at byte 0 and will continue through the scratchpad until the ninth (byte 8, CRC) byte is read. If not all locations are to be read, the master may issue a reset to terminate reading at any time.Copy Scratchpad [48h]This command copies the scratchpad into the E2memory of the DS18B20, storing the temperature trigger bytes in nonvolatile memory. If the bus master issues read time slots following this command, the DS18B20 will output 0 on the bus as long as it is busy copying the scratchpad to E2; it will return a 1 when the copy process is complete. If parasite-powered, the bus master has to enable a strong pullup for at least 10 ms immediately after issuing this command. The DS18B20 EEPROM is rated for a minimum of 50,000 writes and 10 years data retention at T=+55°C.Convert T [44h]This command begins a temperature conversion. No further data is required. The temperature conversion will be performed and then the DS18B20 will remain idle. If the bus master issues read time slots following this command, the DS18B20 will output 0 on the bus as long as it is busy making a temperature conversion; it will return a 1 when the temperature conversion is complete. If parasite-powered, the bus master has to enable a strong pullup for a period greater than t conv immediately after issuing this command.Recall E2 [B8h]This command recalls the temperature trigger values and configuration register stored in E2 to the scratchpad. This recall operation happens automatically upon power-up to the DS18B20 as well, so valid data is available in the scratchpad as soon as the device has power applied. With every read data time slot issued after this command has been sent, the device will output its temperature converter busy flag: 0=busy, 1=ready.Read Power Supply [B4h]With every read data time slot issued after this command has been sent to the DS18B20, the device will signal its power mode: 0=parasite power, 1=external power supply provided.。

DS18B20中文资料

DS18B20中文资料

DS18B20中文资料在现代电子技术领域,温度测量是一项非常重要的任务。

而DS18B20 作为一款常用的数字温度传感器,以其出色的性能和简单的接口,在各种温度测量应用中得到了广泛的应用。

DS18B20 是由美国达拉斯半导体公司(Dallas Semiconductor)推出的一款单线数字温度传感器。

它具有体积小、硬件开销低、抗干扰能力强、精度高等优点。

从外观上看,DS18B20 通常采用小型的TO-92 封装或者SOP 封装,这使得它能够轻松集成到各种电路中,占用极小的空间。

在性能方面,DS18B20 的测量范围非常广泛,从-55℃到+125℃,能够满足大多数实际应用场景的温度测量需求。

其测量精度在-10℃到+85℃范围内可达到 ±05℃,这对于很多对温度精度要求较高的场合来说,是非常出色的表现。

DS18B20 之所以能够在众多温度传感器中脱颖而出,很大程度上得益于其独特的单线接口。

这意味着它只需要一根数据线就可以与微控制器进行通信,大大简化了电路设计和布线工作。

在使用 DS18B20 进行温度测量时,首先需要将其正确连接到微控制器。

通常,将 DS18B20 的数据线连接到微控制器的一个通用输入输出引脚(GPIO)上。

然后,通过微控制器发送特定的指令来启动温度转换,并读取转换后的温度值。

DS18B20 的工作原理基于其内部的温度敏感元件和模数转换电路。

当接收到温度转换指令后,传感器内部的温度敏感元件会感知当前环境温度,并将其转换为对应的数字信号,然后通过单线接口传输给微控制器。

在编程方面,不同的微控制器平台可能会有一些差异,但基本的流程大致相同。

一般来说,需要先初始化单线接口,然后发送复位脉冲和搜索 ROM 指令来识别总线上的 DS18B20 设备。

接着,发送启动温度转换指令,并等待转换完成。

最后,读取转换后的温度数据,并进行相应的处理和显示。

为了确保测量的准确性和稳定性,在实际应用中还需要注意一些问题。

dallas DS18B20中文资料

dallas DS18B20中文资料
报警搜索操作 DS1820 完成一次温度转换后,就拿温度值和存储在 TH 和 TL 中的值进行比较。因为这些寄存 器是 8 位的,所以 0.5℃位被忽略不计。TH 或 TL 的最高有效位直接对应 16 位温度寄存器的 符号位。如果测得的温度高于 TH 或低于 TL,器件内部就会置位一个报警标识。每进行一次 测温就对这个标识进行一次更新。当报警标识置位时,DS1820 会对报警搜索命令有反应。这 样就允许许多 DS1820 并联在一起同时测温,如果某个地方的温度超过了限定值,报警的器件 就会被立即识别出来并读取,而不用读未报警的器件。 64 位(激)光刻 ROM 每只 DS1820 都有一个唯一的长达 64 位的编码。最前面 8 位是单线系列编码(DS1820 的编码 是 19h)。下面 48 位是一个唯一的序列号。最后 8 位是以上 56 位的 CRC 码。(见图 5)64 位 ROM 和 ROM 操作控制区允许 DS1820 做为单线制器件并按照详述于“单线总线系统”一节的 单线协议工作。只有建立了 ROM 操作协议,才能对 DS1820 进行控制操作。这个协议用 ROM 操 作协议流程图来描述(图 6)。单线总线控制器必须得天独厚提供 5 个 ROM 操作命令其中之 一:1)Read ROM,2)Match ROM,3)Search Rom,4)Skip ROM,5)Alarm Search。成功 进行一次 ROM 操作后,就可以对 DS1820 进行特定的操作,总线控制器可以发出六个存储器和 控制操作命令中的任一个。
16 脚 SSOP PR35 符号
说明
9
1 GND 接地
8
2 DQ 数据输入/输出脚。对于单线操作:漏极开路(见“寄生电源”节)

7
3 VDD 可选的 VDD 引脚。具体接法见“寄生电源”节

外文资料翻译---智能温度传感器DS18B20的原理及其应用

外文资料翻译---智能温度传感器DS18B20的原理及其应用

外文资料翻译资料来源:第七届国际测试技术研讨会文章名:The Principle of the Intelligent Temperature Sensor DS18B20and Its Application作者:LI Shuo LI Xiaomi文章译名:智能温度传感器DS18B20的原理与测量姓名:学号:指导教师(职称):专业:班级:所在学院:译文智能温度传感器DS18B20的原理及其应用摘要:功能和结构的数字本文介绍了温度测量芯片DS18B20的温度测量系统的介绍,8051单片机作为其作品CPU和DALLAS18B20其温度数据收集 - 转换。

硬件的原理,软件程图和一个短暂的时间延迟子程序也都给予列出。

关键词:DS18B20温度传感器,单片机微机,硬件设计一、导言单轨数字温度传感器DS18B20的生产由美国DALLAS公司。

它可以转换的温度信号成字信号提供的微电脑处理直接。

与传统的相比热敏电阻器,它可以直接读出的措施温度并根据实际它可以actualize 9〜12的数值读数方式通过简单的编程。

信息读取或写入DS18B20的,只需要一个单一的线。

温度变换功率来源于为主线,主线本身可以供电源DS18B20的,不需要额外的电源。

因此,如果使用DS18B20的,系统的结构会更简单,更可靠。

因为每个DS18B20包含一个独特的硅序列号,多个DS18B20s 可以存在于相同的1-Wire总线。

这允许浇筑温度传感器在许多不同的地方。

应用场合此功能是有用的,包括HVAC环境控制,检测建筑物内的温度,设备或机械,过程监测和控制。

二、 DS18B20的结构DS18B20的四个组成部分的主要数据:(1)64位光刻ROM(2)温度传感器(3)非易失性温度报警触发器TH和TL(4)配置寄存器。

设备源于其权力从1-Wire通信线通过储能在一段时间的内部电容当信号线为高,并继续操作此期间的低倍的电源关闭1-Wire线,直到它返回来补充高寄生虫(电容器)供应。

DS18B20中英文数据手册1233

DS18B20中英文数据手册1233
器用来存储温度传感器输出的数据。除此之外,高速暂存器提供一个直接的温度 报警值寄存器(TH和TL),和一个字节的的配置寄存器。配置寄存器允许用户 将温度的精度设定为9,10,11 或12 位。TH,TL 和配置寄存器是非易失性的 可擦除程序寄存器(EEPROM),所以存储的数据在器件掉电时不会消失。 DS18B20通过达拉斯公司独有的单总线协议依靠一个单线端口通讯。当全部器 件经由一个3态端口或者漏极开路端口(DQ引脚在DS18B20上的情况下)与总线 连接的时候,控制线需要连接一个弱上拉电阻。在这个总线系统中,微控制器(主 器件)依靠每个器件独有的64位片序列号辨认总线上的器件和记录总线上的器 件地址。由于每个装置有一个独特的片序列码,总线可以连接的器件数目事实上 是无限的。单总线协议,包括指令的详细解释和“时序”见单总线系统节。 DS18B20的另一个功能是可以在没有外部电源供电的情况下工作。当总线处于 高电平状态,DQ与上拉电阻连接通过单总线对器件供电。同时处于高电平状态 的总线信号对内部电容(Cpp)充电,在总线处于低电平状态时,该电容提供能 量给器件。这种提供能量的形式被称为“寄生电源”。作为替代选择,DS18B20 同样可以通过VDD引脚连接外部电源供电。 DS18B20方框图图1
数据也可以通过召回EEPROM命令从暂存器载入EEPROM。总线控制器在发出 这条 命令后发出读时序,DS18B20返回0表示正在召回中,返回1表示操作结束。 DS18B20 存储器图图7
*上电状态依赖于EEPROM中的值
配置寄存器
存储器的第4位为配置寄存器,其组织见图8。用户可以通过按表3所示设置R0 和R1位来设定DS18B20的精度。上电默认设置:R0=1,R1=1(12位精度)。注 意: 精度和转换时间之间有直接的关系。暂存器的位7和位0-4被器件保留,禁止写 入;在读回数据时,它们全部表现为逻辑1。 配置寄存器图8

DS18B20(公司下载的原版英文数据手册)

DS18B20(公司下载的原版英文数据手册)

GND DQ VDD
DQ N.C. N.C. GND
1 2 3 N.C.
1 2 3
(BOTTOM VIEW)
µSOP (DS18B20U)
18B20
TO-92 (DS18B20)
1-Wire is a registered trademark of Maxim Integrated Products, Inc.
PIN DESCRIPTION
PIN SO 1, 2, 6, 7, 8 3 4 5 µSOP 2, 3, 5, 6, 7 8 1 4 TO-92 — 3 2 1 NAME N.C. VDD DQ GND No Connection Optional VDD. VDD must be grounded for operation in parasite power mode. Data Input/Output. Open-drain 1-Wire interface pin. Also provides power to the device when used in parasite power mode (see the Powering the DS18B20 section.) Ground FUNCTION
Figure 1 shows a block diagram of the DS18B20, and pin descriptions are given in the Pin Description table. The 64-bit ROM stores the device’s unique serial code. The scratchpad memory contains the 2-byte temperature register that stores the digital output from the temperature sensor. In addition, the scratchpad provides access to the 1-byte upper and lower alarm trigger registers (TH and TL) and the 1-byte configuration register. The configuration register allows the user to set the resolution of the temperatureto-digital conversion to 9, 10, 11, or 12 bits. The TH, TL, and configuration registers are nonvolatile (EEPROM), so they will retain data when the device is powered down. The DS18B20 uses Maxim’s exclusive 1-Wire bus protocol that implements bus communication using one control signal. The control line requires a weak pullup resistor since all devices are linked to the bus via a 3-state or open-drain port (the DQ pin in the case of the DS18B20). In this bus system, the microprocessor (the master device) identifies and addresses devices on the bus using each device’s unique 64-bit code. Because each device has a unique code, the number of devices that can be addressed on one
  1. 1、下载文档前请自行甄别文档内容的完整性,平台不提供额外的编辑、内容补充、找答案等附加服务。
  2. 2、"仅部分预览"的文档,不可在线预览部分如存在完整性等问题,可反馈申请退款(可完整预览的文档不适用该条件!)。
  3. 3、如文档侵犯您的权益,请联系客服反馈,我们会尽快为您处理(人工客服工作时间:9:00-18:30)。

毕业设计(论文)外文资料翻译学院(系):机电一体化专业:电气自动化专业姓名:学号:外文出处:http://(用外文写)2012年4月5日附件: 1.外文资料翻译译文;2.外文原文。

附件1:外文资料翻译译文DS18B20 单线温度传感器1.特征:●独特的单线接口,只需 1 个接口引脚即可通信●每个设备都有一个唯一的64位串行代码存储在光盘片上●多点能力使分布式温度检测应用得以简化●不需要外部部件●可以从数据线供电,电源电压范围为3.0V至5.5V●测量范围从-55 ° C至+125 ° C(-67 ° F至257 ° F),从-10℃至+85 ° C的精度为0.5 °C●温度计分辨率是用户可选择的9至12位●转换12位数字的最长时间是750ms●用户可定义的非易失性的温度告警设置●告警搜索命令识别和寻址温度在编定的极限之外的器件(温度告警情况)●采用8引脚SO(150mil),8引脚SOP和3引脚TO - 92封装●软件与DS1822兼容●应用范围包括恒温控制工业系统消费类产品温度计或任何热敏系统2.简介该DS18B20的数字温度计提供9至12位的摄氏温度测量,并具有与非易失性用户可编程上限和下限报警功能。

信息单线接口送入 DS1820 或从 DS1820 送出,因此按照定义只需要一条数据线(和地线)与中央微处理器进行通信。

它的测温范围从-55 °C到 +125 ° C,其中从-10 °C至+85 °C可以精确到0.5°C 。

此外,DS18B20可以从数据线直接供电(“寄生电源”),从而消除了供应需要一个外部电源。

每个 DS18B20 的有一个唯一的64位序列码,它允许多个DS18B20s的功能在同一1-巴士线。

因此,用一个微处理器控制大面积分布的许多DS18B20s是非常简单的。

此特性的应用范围包括 HVAC、环境控制、建筑物、设备或机械内的温度检测以及过程监视和控制系统。

3.综述64位ROM存储设备的独特序号。

存贮器包含2个字节的温度寄存器,它存储来自温度传感器的数字输出。

此外,暂存器可以访问的1个字节的上下限温度告警触发器(TH和TL)和1个字节的配置寄存器。

配置寄存器允许用户设置的温度到数字转换的分辨率为9,10,11或12位。

TH,TL和配置寄存器是非易失性的,因此掉电时依然可以保存数据。

该DS18B20使用Dallas的单总线协议,总线之间的通信用一个控制信号就可以实现。

控制线需要一个弱上拉电阻,因为所有的设备都是通过3线或开漏端口连接(在DS18B20中用DQ引脚)到总线的。

在这种总线系统中,微处理器(主设备)和地址标识上使用其独有的64位代码。

因为每个设备都有一个唯一的代码,一个总线上连接设备的数量几乎是无限的。

单总线协议,包括详细的解释命令和“时间槽”,此资料的单总线系统部分包括这些内容。

DS18B20的另一个特点是:没有外部电源供电仍然可以工作。

当DQ引脚为高电平时,电压是单总线上拉电阻通过DQ引脚供应的。

高电平信号也可以充当外部电源,当总线是低电平时供应给设备电压。

这种从但总线提供动力的方法被称为“寄生电源“。

作为替代电源,该DS18B20也可以使用连接到 VDD 引脚的外部电源供电。

4.运用——测量温度该DS18B20的核心功能是它是直接输出数字信号的温度传感器。

该温度传感器的分辨率为用户配置至9,10,11或12位,相当于0.5° C,0.25° C,0.125 ° C和0.0625° C的增量。

其中传感器默认为12位。

该DS18B20在低功耗空闲状态;启动温度测量和模数转换,主机必须发出一个转换命令。

转换后,所产生的数据存储在内存中的2比特温度寄存器中,DS18B20返回其空闲状态。

如果DS18B20是由外部电源供电的,主机可以发出“读时隙”,转换后,通过发送低电平T命令和DS18B20将响应,同时温度转换继续进行,当转换完成时变为高电平。

如果DS18B20的是寄生电源供电的,在整个温度转换过程中此通知技术不能使用,因为总线必须变为高电平。

总线需要寄生电源供电将在此资料的DS18B20驱动部分将详细介绍。

DS18B20的输出温度数据为标准摄氏度;对于华氏温度的应用,必须通过查表或运用转换方法。

温度数据在温度寄存器存储为一个16位符号扩展位和2位的补码。

该标志位(S)表示温度的正负符号位:为正数时S = 0,为负数时S = 1。

如果是DS18B20配置为12位分辨率,在温度寄存器的所有位将包含有效数据。

对于11位分辨率,位0是未定义的。

对于10位分辨率,位1和0是未定义的。

对于9位分辨率,位2,1和0是未定义的。

表2给出了输出数字数据和相应的12位分辨率温度读数转换例子。

5.运用 - 报警信号DS18B20温度转换完成后,温度值与用户定义的2个报警触发值存储在1个字节的TH和TL寄存器。

符号位(S)表示温度值的正负: S = 0时为正值, S = 1为负值。

TH和TL寄存器是非易失(EEPROM),因此他们将保留设备掉电时的数据。

TH和TL可通过暂存器中字节2和3获得,此内容在本数据表内存部分解释。

6.TH和TL寄存器格式只有温度寄存器4中的11位用于和TL的比较中,由于TH和TL都是 8位寄存器。

如果测量温度低于或等于TL或超过TH,报警情况存在而且报警标志将设置在DS18B20的内部。

每个温度测量后,这个标志位将被更新,因此,如果报警条件消失,下一个温度转换后,该标志位将被关闭。

主设备可以通过搜索ECH命令检查总线上所有DS18B20s报警标志位的状态。

任何有设置报警标志位的DS18B20s将响应命令,所以主设备可以决定到底是哪个DS18B20s在经历一个报警条件。

如果报警的情况存在,TH和TL设置已经改变了,另一个温度转换应该去验证报警条件。

7.DS18B20的驱动该传感器DS18B20可以用外部电源接VDD端供电,或者它可以工作在“寄生电源”模式下,这种模式允许DS18B20在没有外部电源下工作。

寄生电源在远程或者空间受限情况下感温是非常有用的。

寄生功率控制电路,其中当总线引脚为高电平时,力部门宿舍从DS18B201通过连接单总线的DQ端“偷”电。

当总线是高电平或者总线是低电平,而一些能量存贮在CPP中来提供电源,“偷”来的电位DS18B20提供驱动。

当DS18B20在寄生电源模式下使用时,VDD引脚必须接地。

在寄生电源模式下,单总线和CPP可以提供足够的电流给DS18B20的大部分操作,只要指定的时间和电压的要求得到满足(参考本数据手册DC电气特性和AC电气特性章节)。

然而,当DS18B20温度转换或复制暂存器的数据到EEPROM时,工作电流可高达1.5毫安。

这个电流会导致无法接受的电压下降,整个单总线电阻压降减小,更多的电流可以由寄生电源供应。

为了确保DS18B20有足够的电流供应,无论正在发生温度转换或复制暂存器的数据到EEPROM,单总线都必须接一个强上拉电阻。

单总线必须在转换T[44h]或暂存器复制[48H]命令发出后, 10秒内(最大)转换到强上拉状态,而且总线必须在转换(tconv)或数据传输(twr = 10ms)期间通过上拉保持高电平。

在单总线上拉使能时,其他活动不能发生。

该DS18B20的也可以采用的连接外部电源到VDD脚上的传统方法。

这种方法的优点是不需要MOSFET的上拉,而且单总线可以在进行温度转换时间自由地进行其他操作。

在+100℃以上的高温时不推荐使用寄生电源,因为在这些温度下存在较高泄漏电流,DS18B20可能无法维持通信。

对于像在这种高温下的使用,强烈建议由一个DS18B20的外部电源供电。

在某些情况下,总线主机可能不知道DS18B20s是外部电源还是寄生电源供电。

主机需要这些信息来确定是否强大的总线上拉应在温度转换时使用。

要获得这些信息,主机可以在“阅读时段” 一个读取电源[B4h]命令后,发出一个跳过ROM[CCh]命令。

在读时隙,寄生电源给DS18B20s供电将把总线电平拉低,外部供电时DS18B20s将会让总线仍然保持高电平。

如果总线拉低,主机知道在温度转换期间它必须提供单总线强上拉。

8.64位激光ROM每一 DS1820 包括一个唯一的 64 位长的 ROM 编码。

开绐的 8 位是单线产品系列编码:28h,接着的 48 位是唯一的系列号。

最重要的8位是开始 56 位 CRC 位,从56位的ROM端计算而来。

CRC比特的详细内容将在CRC概述一章中介绍。

64位ROM代码和相关ROM功能控制逻辑使DS18B20作为使用协议的单线设备的运作,单总线系统的数据表部分详细介绍了这个协议。

9.存贮器DS1820的存贮器那样被组织存贮器由一个高速暂存便笺式 RAM、一个存贮高温度和低温度和触发器 TH 和 TL的非易失性电可擦除 E2RAM和存储配置寄存器组成。

请注意,如果DS18B20的报警功能不使用,TH和TL寄存器可以作为通用存储器。

DS18B20的功能命令部分详细叙述了所有内存的命令。

暂存器的字节0和字节1分别包含LSB和MSB温度寄存器。

这些字节是只读的。

字节2和3提供是提供接入的TH和TL寄存器。

字节4包含配置寄存器数据,数据表配置寄存器部分详细解释了它的内容。

字节5,6和7是保留供内部使用的设备,不能被覆盖,当被读到时,这些字节将返回1秒。

8字节暂存器是只读的,并且包含了循环冗余校验码,通过暂存器的0到7字节。

DS18B20使用在CRC生成一节中描述的方法生成该CRC。

数据写入字节2,3,暂存器4使用写入暂存[4Eh]指令;数据必须传输到DS18B20以最低有效位开始的第2字节。

为了验证数据的完整性,数据被写入后暂存器可以读取(使用数据读取暂存器[与Beh]命令)。

当读取暂存器,数据是从最低有效位的0字节开始的。

要传送的TH,TL和配置数据从暂存器到EEPROM,主机必须发起复制暂存 [48h]命令。

设备关机时,在EEPROM寄存器的数据将被保留,上电时EEPROM中的数据到相应的位置暂存器重新加载。

数据也可以使用召回E2 [B8h]命令在任何时间从EEPROM中重新加载向暂存器。

主机可以在召回E2命令后发出读时隙后,DS18B20的将通过传输0表明处在召回状态,当召回完成时将传输1。

10.配置寄存器暂存存储器的第四字节包含配置寄存器。

用户可以使用该寄存器的R0和R1的位置DS18B20的转换分辨率。

这些位默认是R0和R1都等于1(12位)的分辨率。

请注意,两者之间是有直接的分辨率和转换时间的对比。

第7位,并在配置寄存器0至4位是保留供内部使用的设备,不能被覆盖,这些位被读出时将返回1秒。

相关文档
最新文档