版權(quán)說明:本文檔由用戶提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請進行舉報或認領(lǐng)
文檔簡介
1、外文資料 專業(yè): 電子信息工程 學(xué)號: 姓名:張超 指導(dǎo)老師:胡保安 (南昌大學(xué)科學(xué)技術(shù)學(xué)院) DS18B20 Programmable Resolution 1-Wire Digital ThermometerThe 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 inter
2、face, 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 sil
3、icon 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 moni
4、toring 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 t
5、he 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, th
6、e 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 functio
7、n 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 de
8、vices 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 measur
9、ement. The result of this measurement will be placed in the DS18B20s 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
10、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 acces
11、s 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 ti
12、ming 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
13、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. Thi
14、s 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
15、 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
16、 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
17、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 a
18、ll 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
19、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
20、 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
21、 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 VDD pin. If the master receives a “0,” it knows that it must supply the stro
22、ng 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 RO
23、M 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:The DS18B20 also generates an 8-bit CRC value using the same polynomial function shown above and provides this value
24、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
25、 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 t
26、hat 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 informatio
27、n 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 c
28、ode, 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.
29、 中文翻譯 專業(yè): 電子信息工程 學(xué)號: 姓名:張超 指導(dǎo)老師:胡保安 DS1820 單總線數(shù)字溫度計 DSl820數(shù)字溫度計提供9位(二進制)溫度讀數(shù)指示器件的溫度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.。信息經(jīng)過單線接口送入DSl820或從DSl820送出因此從主機CPU到DSl820僅需一條線(和地線)
30、。 Power for reading, writing, and performing temperature conversions can be derived from the data line itself with no need for an external power source.寫數(shù)據(jù),讀溫度轉(zhuǎn)換可以由數(shù)據(jù)線本身來提供電源而不需要一個外部電源。由于每個DS18B20的包含一個唯一的序列號,因此任意多個DSl820可以存放在同一條單線總線上。這允許在不同的地方放置溫度傳感器。此功能可應(yīng)用的地方包括空調(diào)環(huán)境控制,建筑物內(nèi)的溫度感應(yīng),設(shè)備或機器的過程監(jiān)控和控制。 The bl
31、ock diagram of Figure 1 shows the major components of the DS18B20.DS18B20的有四個主要的數(shù)據(jù)部分組成:1)64位激光ROM,2)溫度靈敏元件,3)非易失性溫度報警觸發(fā)器TH和TL,4)配置寄存器。器件從單線的通信線上取得其電源,在信號線為高電平的時間周期內(nèi),把能量貯存在內(nèi)部的電容器中,在單信號線為低電平的時間期內(nèi)斷開此電源,直到信號線變?yōu)楦唠娖街匦陆由霞纳娙蓦娫礊橹埂W鳛榱硪环N可供選擇的方法,DS1820 也可用外部5V 電源供電。與DS1820 的通信經(jīng)過一個單線接口。在單線接口情況下,在ROM 操作未定建立之前不能使
32、用存貯器和控制操作。主機必須首先提供五種ROM 操作命令之一:1)Read ROM(讀ROM), 2)Match ROM(符合ROM),3)Search ROM(搜索ROM),4)Skip ROM(跳過ROM),或5) Alarm Search(告警搜索)。 這些命令對每一器件的64 位激光ROM 部分進行操作。如果在單線上有許多器件,那么可以挑選出一個特定的器件,并給總線上的主機指示存在多少器件及其類型。在成功地執(zhí)行了ROM 操作序列之后,可使用存貯器和控制操作,然后主機可以提供六種存貯器和控制操作命令之一。一個控制操作命令指示DS1820 完成溫度測量。該測量的結(jié)果將放入DS1820 的高
33、速暫存存貯器(Scratchpad memory)。通過發(fā)出讀暫存存儲器內(nèi)容的存儲器操作命令可以讀出此結(jié)果。每一溫度告警觸發(fā)器TH 和TL 構(gòu)成一個字節(jié)的EEPROM, 如果不對DS1820 施加告警搜索命令,這些寄存器可用作通用用戶存儲器,使用存儲器操作命令可以寫TH 和TL。對這些寄存器的訪問是通過高速暫存存儲器,所有數(shù)據(jù)均以最低有效位在前的方式被讀寫PARASITE POWER。寄生電源電路當I/O或VDD引腳為高電平時,這個電路便“取”得電源。只要符合指定的定時和電壓要求,I/O將提供足夠的功率,寄生電源的優(yōu)點是雙重的:1)利用此引腳,遠程溫度檢測無需本地電源,2)缺少正常電源條件下也
34、可以讀ROM。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.。為了使DS1820 能完成準確的溫度變換,當溫度變換發(fā)生時,I/O線上必須提供足夠的功率。因為DS1820的工作電流高達1mA,5K 的上拉電阻將使I/O線沒有足夠的驅(qū)動能力。如果幾個SD1820 在同一條I/O 線上而且企圖同
35、時變換,那么這一問題將變得特別尖銳。There are two ways to assure that the DS18B20 has sufficient supply current during its active conversion cycle.有兩種方法確保DS1820在其有效變換期內(nèi)得到足夠的電源電流。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.第一種方法是發(fā)
36、生溫度變換時在I/O線上提供一強的上拉電阻,This may be accomplished by using a MOSFET to pull the DQ line directly to the power supply as shown in Figur通過使用一個MOSFET把I/O線直接拉到電源可達到這一點,當使用寄生電源方式時VDD引腳必須連接到地。Another method of supplying current to the DS18B20 is through the use of an external power supply tied to the V DD pi
37、n, as shown in Figure 3.向DS1820 供電的另外一種方法是通過使用連接到VDD 引腳的外部電源,這種方法的優(yōu)點是在I/O 線上不要求強的上拉電阻,總線上主機不需向上連接便在溫度變換期間使線保持高電平,這就允許在變換時間內(nèi)其它數(shù)據(jù)在單線上傳送。此外,在單線總線上可以放置任何數(shù)目的DS1820 ,而且如果它們都使用外部電源,那么通過發(fā)出跳過(Skip)ROM 命令和接著發(fā)出變換(Convert)T 命令,可以同時完成溫度變換。注意只要外部電源處于工作狀態(tài),GND(地)引腳不可懸空。 For situations where the bus master does not
38、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.在總線上主機不知道總線上DS1820 是寄生電源供電還是外部VDD 供電的情況下,在DS1820 內(nèi)采取了措施來通知采用的供電方案。總線上主機通過發(fā)出跳過(Skip)ROM 的操作約定,然后發(fā)出讀電源命令,可以決定是否有需要在DS1820 的總線上放置上拉電阻。在此命令發(fā)出后,主機接著發(fā)出讀時間片。如果是寄生供電,DS1820 將在單線總線上送回(0);如果由VDD 引腳供電,它將送回(1)。如果主機接收到一個(0),它知道它必須在溫度變換期間在I/O 線上供一個強的上拉。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 i
溫馨提示
- 1. 本站所有資源如無特殊說明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請下載最新的WinRAR軟件解壓。
- 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶所有。
- 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁內(nèi)容里面會有圖紙預(yù)覽,若沒有圖紙預(yù)覽就沒有圖紙。
- 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
- 5. 人人文庫網(wǎng)僅提供信息存儲空間,僅對用戶上傳內(nèi)容的表現(xiàn)方式做保護處理,對用戶上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對任何下載內(nèi)容負責。
- 6. 下載文件中如有侵權(quán)或不適當內(nèi)容,請與我們聯(lián)系,我們立即糾正。
- 7. 本站不保證下載資源的準確性、安全性和完整性, 同時也不承擔用戶因使用這些下載資源對自己和他人造成任何形式的傷害或損失。
最新文檔
- 2026年電氣安全管理體系的建立與實施
- 2026年橋梁健康監(jiān)測中的社會參與模式
- 課件設(shè)計的理論知識
- 課件知識競賽方案模板
- 高校教師教學(xué)績效評價體系解析
- 2026屆高考生物一輪精準突破復(fù)習(xí)第26講+神經(jīng)調(diào)節(jié)
- 互聯(lián)網(wǎng)企業(yè)客戶服務(wù)質(zhì)量提升計劃
- 小學(xué)音樂課教學(xué)反思范文
- 數(shù)學(xué)教學(xué)反思與課堂改進策略
- EPC工程總承包項目管理操作手冊
- 工程維保三方合同
- 地鐵車輛檢修安全培訓(xùn)
- 造血干細胞移植臨床應(yīng)用和新進展課件
- GB/T 10802-2023通用軟質(zhì)聚氨酯泡沫塑料
- 黑布林英語閱讀初一年級16《柳林風聲》譯文和答案
- 杰青優(yōu)青學(xué)術(shù)項目申報答辯PPT模板
- 宿舍入住申請書
- 深圳中核海得威生物科技有限公司桐城分公司碳13-尿素原料藥項目環(huán)境影響報告書
- 2023年全國高考體育單招文化考試數(shù)學(xué)試卷真題及答案
- GB/T 28733-2012固體生物質(zhì)燃料全水分測定方法
- GB/T 14404-2011剪板機精度
評論
0/150
提交評論