19-5629; Rev 0; 11/10 Digital Thermometers and Thermostats with SPI/3-Wire Interface The MAX31722/MAX31723 digital thermometers and thermostats with an SPI™/3-wire interface provide temperature readings that indicate the device temperature. No additional components are required; the devices are truly temperature-to-digital converters. Temperature readings are communicated from the device over an SPI interface or a 3-wire serial interface. The choice of interface is selectable by the user. For applications that require greater temperature resolution, the user can adjust the readout resolution from 9 to 12 bits. This is particularly useful in applications where thermal runaway conditions must be detected quickly. The thermostat has a dedicated open-drain output (TOUT). Two thermostat operating modes, comparator and interrupt, control thermostat operation based on user-defined nonvolatile trip points (THIGH and TLOW). Both devices feature a 1.7V to 3.7V supply rail. Features S Temperature Measurements Require No External Components S Measures Temperatures from -55NC to +125NC S MAX31722 Thermometer Accuracy is ±2.0NC S MAX31723 Thermometer Accuracy is ±0.5NC S Thermometer Resolution is Configurable from 9 to 12 Bits (0.5NC to 0.0625NC Resolution) S Thermostat Output with User-Defined Nonvolatile Thresholds S Data is Read from/Written to by SPI (Mode 0 and 2) or 3-Wire Serial Interface S 1.7V to 3.7V Power-Supply Range S Available in 8-Pin µMAX® Package Ordering Information Applications PART TEMP RANGE Networking Equipment MAX31722MUA+ -55NC to +125NC 8 FMAX Cellular Base Stations MAX31722MUA+T -55NC to +125NC 8 FMAX MAX31723MUA+ -55NC to +125NC 8 FMAX MAX31723MUA+T -55NC to +125NC 8 FMAX Industrial Equipment Any Thermally Sensitive Systems PIN-PACKAGE +Denotes a lead(Pb)-free/RoHS-compliant package. T = Tape and reel. Functional Diagram VDD VDD SDI SDO SCLK CE SERMODE GND PRECISION REFERENCE OVERSAMPLING MODULATOR DIGITAL DECIMATOR CONFIGURATION/ STATUS REGISTER I/O CONTROL AND INPUT SENSE MAX31722 MAX31723 TEMPERATURE REGISTER THIGH AND TLOW REGISTERS TOUT THERMOSTAT COMPARATOR SPI is a trademark of Motorola, Inc. µMAX is a registered trademark of Maxim Integrated Products, Inc. ________________________________________________________________ Maxim Integrated Products 1 For pricing, delivery, and ordering information, please contact Maxim Direct at 1-888-629-4642, or visit Maxim’s website at www.maxim-ic.com. MAX31722/MAX31723 General Description MAX31722/MAX31723 Digital Thermometers and Thermostats with SPI/3-Wire Interface ABSOLUTE MAXIMUM RATINGS Voltage Range on VDD Relative to GND...............-0.3V to +6.0V Voltage Range on Any Other Pin Relative to GND....-0.3V to +6.0V Continuous Power Dissipation (TA = +70NC) FMAX (derate 4.5mW/NC above +70NC).......................362mW EEPROM Programming Temperature Range.. ...-40NC to +85NC Operating Junction Temperature Range.......... -55NC to +125NC Storage Temperature Range............................. -55NC to +125NC Lead Temperature (soldering, 10s).................................+300NC Soldering Temperature (reflow).......................................+260NC Stresses beyond those listed under “Absolute Maximum Ratings” may cause permanent damage to the device. These are stress ratings only, and functional operation of the device at these or any other conditions beyond those indicated in the operational sections of the specifications is not implied. Exposure to absolute maximum rating conditions for extended periods may affect device reliability. RECOMMENDED OPERATING CHARACTERISTICS (TJ = -55NC to +125NC, unless otherwise noted.) PARAMETER SYMBOL CONDITIONS Supply Voltage VDD (Note 1) Input Logic-High VIH (Note 1) Input Logic-Low VIL (Note 1) MIN TYP 1.7 0.7 x VDD -0.3 MAX UNITS 3.7 V VDD + 0.3 V 0.3 x VDD V DC ELECTRICAL CHARACTERISTICS (VDD = 1.7V to 3.7V, TJ = -55NC to +125NC, unless otherwise noted.) PARAMETER SYMBOL MAX31722 Thermometer Error TERR MAX31723 Thermometer Error TERR CONDITIONS MIN -55NC to +125NC Q3.0 0NC to +70NC Q0.5 -55NC to +125NC Q2.0 9 9-bit conversions tCONVT MAX Q2.0 Resolution Conversion Time TYP -40NC to +85NC 12 10-bit conversions 50 11-bit conversions 100 12-bit conversions 200 Logic 0 Output (SDO, TOUT) (Note 2) 0.4 Logic 1 Output (SDO) VOH (Note 3) IL Active Current Shutdown Current 2 ICC ICC1 VDD 0.4 -1 Active temperature conversions (Note 4) NC NC Bits 25 VOL Leakage Current UNITS ms V V +1 FA 1150 Communication only 100 EEPROM writes (-40NC to +85NC) 1150 EEPROM writes during active temperature conversions (-40NC to +85NC) 1200 2 FA FA Digital Thermometers and Thermostats with SPI/3-Wire Interface MAX31722/MAX31723 AC ELECTRICAL CHARACTERISTICS: 3-WIRE INTERFACE (VDD = 1.7V to 3.7V, TJ = -55NC to +125NC, unless otherwise noted.) (Figures 1, 2) PARAMETER SYMBOL CONDITIONS MIN Data to SCLK Setup tDC (Notes 5, 6) 35 SCLK to Data Hold tCDH (Notes 5, 6) 35 SCLK to Data Valid tCDD (Notes 5, 6, 7) SCLK Low Time TYP MAX UNITS ns ns 80 ns tCL (Note 6) 100 ns SCLK High Time tCH (Note 6) 100 SCLK Frequency tCLK (Note 6) DC SCLK Rise and Fall tR, tF CE to SCLK Setup tCC (Note 6) 400 ns SCLK to CE Hold tCCH (Note 6) 100 ns CE Inactive Time tCWH (Note 6) 400 CE to Output High-Z tCDZ (Notes 5, 6) 40 ns SCLK to Output High-Z tCCZ (Notes 5, 6) 40 ns MAX UNITS ns 5.0 MHz 200 ns ns AC ELECTRICAL CHARACTERISTICS: SPI INTERFACE (VDD = 1.7V to 3.7V, TJ = -55NC to +125NC, unless otherwise noted.) (Figures 3, 4) PARAMETER SYMBOL CONDITIONS MIN Data to SCLK Setup tDC (Notes 5, 6) 35 SCLK to Data Hold tCDH (Notes 5, 6) 35 SCLK to Data Valid tCDD (Notes 5, 6, 7) SCLK Low Time TYP ns ns 80 ns tCL (Note 6) 100 ns SCLK High Time tCH (Note 6) 100 SCLK Frequency tCLK (Note 6) DC SCLK Rise and Fall tR, tF CE to SCLK Setup tCC (Note 6) 400 ns SCLK to CE Hold tCCH (Note 6) 100 ns CE Inactive Time tCWH (Note 6) 400 CE to Output High-Z tCDZ (Notes 5, 6) ns 5.0 MHz 200 ns ns 40 ns MAX UNITS 15 ms AC ELECTRICAL CHARACTERISTICS: EEPROM (VDD = 1.7V to 3.7V, TJ = -55NC to +125NC, unless otherwise noted.) PARAMETER EEPROM Write Cycle Time EEPROM Write Endurance SYMBOL tWR NEEWR CONDITIONS MIN -40NC to +85NC (Note 8) -40NC P TA P +85NC (Note 8) 20,000 TA = +25NC (Note 8) 80,000 TYP Cycles Note 1: All voltages are referenced to ground. Currents entering the IC are specified positive, and currents exiting the IC are negative. Note 2: Logic 0 voltages are specified at a sink current of 3mA. Note 3: Logic 1 voltages are specified at a source current of 1mA. Note 4: ICC specified with SCLK = VDD and CE = GND. Note 5: Measured at VIH = 0.7V x VDD or VIL = 0.3 x VDD and 10ms maximum rise and fall times. Note 6: Measured with 50pF load. Note 7: Measured at VOH = 0.7 x VDD or VOL = 0.3 x VDD. Measured from the 50% point of SCLK to the VOH minimum of SDO. Note 8: VDD must be > 2.0V during EEPROM write cycles. 3 MAX31722/MAX31723 Digital Thermometers and Thermostats with SPI/3-Wire Interface CE tCC SCLK tCCZ tCDH tCDZ tCDD tCDD tDC A0 I/O* A1 A7 D0 WRITE ADDRESS BYTE D1 READ DATA BIT *I/O IS SDI AND SDO CONNECTED TOGETHER. Figure 1. Timing Diagram: 3-Wire Read Data Transfer tCWH CE tCC tCCH tR tCL tF SCLK tCDH tCH tDC I/O* A0 A1 WRITE ADDRESS BYTE *I/O IS SDI AND SDO CONNECTED TOGETHER. Figure 2. Timing Diagram: 3-Wire Write Data Transfer 4 A7 D0 WRITE DATA Digital Thermometers and Thermostats with SPI/3-Wire Interface MAX31722/MAX31723 CE tCC SCLK tCDD tCDD tCDH tDC SDI A7 A6 A0 tCDZ SDO D7 D6 WRITE ADDRESS BYTE D1 D0 READ DATA BYTE NOTE: SCLK CAN BE EITHER POLARITY, TIMING SHOWN FOR CPOL = 1. Figure 3. Timing Diagram: SPI Read Data Transfer tCWH CE tCC tR tCL tCCH tF SCLK tCDH tCH tCDH tDC SDI A7 A6 WRITE ADDRESS BYTE A0 D7 D0 WRITE DATA BYTE NOTE: SCLK CAN BE EITHER POLARITY, TIMING SHOWN FOR CPOL = 1. Figure 4. Timing Diagram: SPI Write Data Transfer 5 Typical Operating Characteristics (TA = +25°C, unless otherwise noted.) TEMPERATURE CONVERSION ACTIVE SUPPLY CURRENT vs. TEMPERATURE 1.4 VDD = 3.7V 1.2 1.0 ICC (µA) 800 VDD = 3.0V 600 400 VDD = 3.7V VDD = 1.7V 0.8 VDD = 3.0V 0.6 0.4 200 VDD = 1.7V 0.2 0 0 -55 -35 -15 5 25 45 65 -55 -35 -15 85 105 125 0.5 12-BIT TEMPERATURE CONVERSIONS VDD = 3.0V 0.4 0.3 3σ 0.2 0.1 0 -0.1 -0.2 -3σ -0.3 -0.4 -0.5 -40 -20 0 20 40 TEMPERATURE (°C) 60 80 MAX31722/3 toc03 TEMPERATURE CONVERSION ERROR vs. REFERENCE TEMPERATURE ERROR (°C) 5 25 45 65 TEMPERATURE (°C) TEMPERATURE (°C) 6 MAX31722/3 toc02 1000 STANDBY SUPPLY CURRENT vs. TEMPERATURE MAX31722/3 toc01 1200 ICC (µA) MAX31722/MAX31723 Digital Thermometers and Thermostats with SPI/3-Wire Interface 85 105 125 Digital Thermometers and Thermostats with SPI/3-Wire Interface MAX31722/MAX31723 Pin Configuration TOP VIEW TOUT 1 CE 2 SCLK 3 GND 4 + MAX31722 MAX31723 8 VDD 7 SERMODE 6 SDI 5 SDO µMAX Pin Description PIN NAME 1 TOUT FUNCTION 2 CE 3 SCLK Serial-Clock Input. Used to synchronize data movement on the serial interface for either SPI or 3-wire interfaces. 4 GND Ground. Ground connection. 5 SDO Serial-Data Output. When SPI communication is selected, the SDO pin is the serial-data output for the SPI bus. When 3-wire communication is selected, this pin must be connected to the SDI pin. The SDI and SDO pins function as a single I/O pin when connected together. 6 SDI Serial-Data Input. When SPI communication is selected, the SDI pin is the serial-data input for the SPI bus. When 3-wire communication is selected, this pin must be connected to the SDO pin. The SDI and SDO pins function as a single I/O pin when connected together. 7 SERMODE Serial-Interface Mode Input. This pin selects which interface is used. When connected to VDD, SPI communication is selected. When connected to GND, 3-wire communication is selected. 8 VDD Thermostat Output. Open-drain output indicator for internal thermal alarm limits. Chip Enable. Must be asserted high for communication to take place for either the SPI or 3-wire interfaces. Supply Voltage. Power-supply input. Detailed Description The MAX31722/MAX31723 are factory-calibrated temperature sensors that require no external components. The user can alter the configuration/status register to place the device in a continuous temperature conversion mode or into a one-shot conversion mode. In the continuous conversion mode, the devices continuously convert the temperature and store 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 devices perform one temperature conversion, store the result in the temperature register, and then return to the shutdown state. This conversion mode is ideal for power-sensitive applications. The temperature conversion results 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 10, 11, or 12. This is accomplished by programming the configuration/status register. The devices can be configured as a thermostat, allowing for the TOUT pin to behave as an interrupt, triggering when the programmed limits, THIGH and TLOW, are surpassed. The devices can communicate using either a serial peripheral interface (SPI) or standard 3-wire interface. The user can select either communication standard through the SERMODE pin, connecting it to VDD for SPI and to GND for 3-wire. 7 MAX31722/MAX31723 Digital Thermometers and Thermostats with SPI/3-Wire Interface Measuring Temperature mode is ideal for power-sensitive applications. Details on how to change the setting after power-up are contained in the Programming section. The core of the devices’ functionality is its direct-to-digital temperature sensor. The devices measure temperature through the use of an on-chip temperature measurement technique with a -55NC to +125NC operating range. The devices power up in a power-conserving shutdown mode. After power-up, the devices can be placed in a continuous conversion mode or in a one-shot conversion mode. In the continuous conversion mode, the devices continuously compute the temperature and store the most recent result in the temperature register at addresses 01h (LSB) and 02h (MSB). As conversions are performed in the background, reading the temperature register does not affect the conversion in progress. The temperature value is not updated until the SPI or 3-wire interface is inactive. In other words, CE must be inactive for the temperature register to be updated with the most recent temperature conversion value. In the one-shot conversion mode, the devices perform one temperature conversion and then return to the shutdown mode, storing temperature in the temperature register. This conversion 26 S 25 24 The resolution of the temperature conversion is configurable (9, 10, 11, or 12 bits) with 9 bits reading the default state. This equates to a temperature resolution of 0.5NC, 0.25NC, 0.125NC, or 0.0625NC. Following each conversion, thermal data is stored in the temperature 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 1 describes the exact relationship of output data to measured temperature. Table 1 assumes the devices are configured for 12-bit resolution. If the devices are configured in a lower resolution mode, those bits contain zeros. 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. 23 MSB 22 21 2-2 2-3 2-4 0 02h LSB (UNITS = NC) 2-1 20 0 0 0 01h Figure 5. Temperature, THIGH, and TLOW Register Format Table 1. 12-Bit Resolution Temperature/Data Relationship 8 TEMPERATURE (NC) DIGITAL OUTPUT (BINARY) DIGITAL OUTPUT (HEX) 7D00 +125 0111 1101 0000 0000 +25.0625 0001 1001 0001 0000 1910 +10.125 0000 1010 0010 0000 0A20 +0.5 0000 0000 1000 0000 0080 0000 0 0000 0000 0000 0000 -0.5 1111 1111 1000 0000 FF80 -10.125 1111 0101 1110 0000 F5E0 -25.0625 1110 0110 1111 0000 E6F0 -55 1100 1001 0000 0000 C900 Digital Thermometers and Thermostats with SPI/3-Wire Interface The devices’ thermostat can be programmed to power up in either comparator mode or interrupt mode, which activate and deactivate the open-drain thermostat output (TOUT) based on user-programmable trip points (THIGH and TLOW). The THIGH and TLOW registers contain Celsius temperature values in two’s complement format and are stored in EEPROM memory. As such, the values are nonvolatile and can be programmed prior to installing the devices for stand-alone operation. The data format of the THIGH and TLOW registers is identical to that of the temperature register (Figure 5). After every temperature conversion, the measurement is compared to the values stored in the THIGH and TLOW registers. The THIGH register is assigned to address locations 03h (LSB) and 04h (MSB), and the TLOW register is assigned to address locations 05h (LSB) and 06h (MSB). The TOUT output is updated based on the result of the comparison and the operating mode of the devices. The number of THIGH and TLOW bits used during the thermostat comparison is equal to the conversion resolution set by the R1 and R0 bits in the configuration/ status register. For example, if the resolution is 9 bits, only the nine MSBs of THIGH and TLOW are used by the thermostat comparator. If the user does not wish to use the thermostat capabilities of the devices, the TOUT output should be left unconnected. Note that if the thermostat is not used, the THIGH and TLOW registers can be used for general storage of system data. Comparator Mode When the thermostat is in comparator mode, TOUT can be programmed to operate with any amount of hysteresis. The TOUT output becomes active when the measured temperature exceeds the THIGH value. TOUT then stays active until the first time the temperature falls below the value stored in TLOW. Putting the devices into shutdown mode does not clear TOUT in comparator mode. Figure 6 illustrates thermostat comparator mode operation. Interrupt Mode In interrupt mode, the TOUT output first becomes active when the measured temperature exceeds the THIGH value. Once activated, in continuous conversion mode TOUT can only be cleared by either putting the devices into shutdown mode or by reading from any register (configuration/status, temperature, THIGH, or TLOW) on the devices. In one-shot mode, TOUT can only be cleared by reading from any register (configuration/ status, temperature, THIGH, or TLOW) on the devices. THIGH TEMPERATURE TLOW INACTIVE TOUT OUTPUT—COMPARATOR MODE ACTIVE INACTIVE TOUT OUTPUT—INTERRUPT MODE ACTIVE ASSUMES A READ HAS OCCURED CONVERSIONS Figure 6. TOUT Operation Example 9 MAX31722/MAX31723 Thermostat MAX31722/MAX31723 Digital Thermometers and Thermostats with SPI/3-Wire Interface In either mode, once TOUT has been deactivated, it is only reactivated when the measured temperature falls below the TLOW value. Thus, this interrupt/clear process is cyclical between THIGH and TLOW events (i.e, THIGH, clear, TLOW, clear, THIGH, clear, TLOW, clear, etc.). Figure 6 illustrates the thermostat interrupt mode operation. Table 2. Register Address Structure READ ADDRESS (HEX) Programming The area of interest in programming the devices is the configuration/status register. All programming is done through the SPI or 3-wire communication interface by selecting the appropriate address of the desired register location. Table 2 illustrates the addresses for the device registers. Configuration/Status Register Programming WRITE ADDRESS (HEX) ACTIVE REGISTER 00 80 Configuration/Status 01 No access Temperature LSB 02 No access Temperature MSB 03 83 THIGH LSB 04 84 THIGH MSB 05 85 TLOW LSB 06 86 TLOW MSB The configuration/status register is accessed in the devices with the 00h address for reads and the 80h address for writes. Data is read from or written to the configuration/status register MSB first for SPI communication and LSB first for 3-wire communication. Table 3 illustrates the format of the register, describes the effect each bit has on device functionality, and provides the bit’s factory state. Table 4 defines the resolution of the digital thermometer, based on the settings of the R1 and R0 bits. There is a direct trade-off between resolution and conversion time, Table 3. Configuration/Status Register Bit Descriptions 10 BIT 7 BIT 6 BIT 5 BIT 4 BIT 3 BIT 2 BIT 1 BIT 0 0 MEMW NVB 1SHOT TM R1 R0 SD BIT 7 This bit is always a value of 0. BIT 6 MEMW: Memory write bit. Power-up state = 0. The user has read/write access to the MEMW bit, which is stored in the voltage memory. 0 = A write of the configuration/status register is stored in RAM memory. 1 = A write of the configuration/status register is stored in EEPROM. Note: The status of this bit is ignored if a EEPROM write occurs to the other nonvolatile registers, THIGH and TLOW. The nonvolatile bits of the configuration/status register are written if a EEPROM write cycle occurs to the THIGH and TLOW registers. BIT 5 NVB: Nonvolatile memory busy flag. Power-up state = 0 and is stored in volatile memory. 0 = Indicates that the nonvolatile memory is not busy. 1 = Indicates there is a write to a EEPROM memory cell in progress. BIT 4 1SHOT: One-shot temperature conversion bit. Power-up state = 0 and is stored in volatile memory. 0 = Disables 1SHOT mode. 1 = If the SD bit is 1 (continuous temperature conversions are not taking place), a 1 written to the 1SHOT bit causes the devices to perform one temperature conversion and store the results in the temperature register at addresses 01h (LSB) and 02h (MSB). The bit clears itself to 0 upon completion of the temperature conversion. The user has read/write access to the 1SHOT bit, although writes to this bit are ignored if the SD bit is a 0 (continuous conversion mode). BIT 3 TM: Thermostat operating mode. Factory power-up state = 0. The user has read/write access to the TM bit, which is stored in nonvolatile memory. 0 = The thermostat output is in comparator mode. 1 = The thermostat output is in interrupt mode. Digital Thermometers and Thermostats with SPI/3-Wire Interface BIT 2 R1: Thermostat resolution bit 1. Factory power-up state = 0 and is stored in nonvolatile memory. Sets the conversion resolution (see Table 4). BIT 1 R0: Thermostat resolution bit 0. Factory power-up state = 0 and is stored in nonvolatile memory. Sets the conversion resolution (see Table 4). BIT 0 SD: Factory power-up state = 1. The user has read/write access to the SD bit, which is stored in nonvolatile memory. 0 = The devices continuously perform temperature conversions and store the last completed result in the temperature register. 1 = The conversion in progress is completed and stored, and then the devices revert to a low-power shutdown mode. The communication port remains active. Serial Peripheral Interface (SPI) Table 4. Thermometer Resolution Configuration THERMOMETER RESOLUTION (BITS) MAX CONVERSION TIME (ms) 0 9 25 1 10 50 1 0 11 100 1 1 12 200 R1 R0 0 0 as depicted in the AC Electrical Characteristics. The user has read/write access to the R1 and R0 bits, which are nonvolatile. See Table 4. Serial Interface The devices offer the flexibility to choose between two serial interface modes. They can communicate with the SPI interface or with a 3-wire interface. The interface method used is determined by the SERMODE pin. When SERMODE is connected to VDD, SPI communication is selected. When SERMODE is connected to ground, 3-wire communication is selected. Table 5. Function Table MODE CE Disable reset Low Write High Read High The SPI is a synchronous bus for address and data transfer. The SPI mode of serial communication is selected by connecting SERMODE to VDD. Four pins are used for the SPI: SDO (serial-data out), SDI (serial-data in), CE (chip enable), and SCLK (serial clock). The devices are the slave device in an SPI application, with the microcontroller being the master. SDI and SDO are the serial-data input and output pins for the devices, respectively. The CE input is used to initiate and terminate a data transfer. SCLK is used to synchronize data movement between the master (microcontroller) and the slave (IC) devices. The serial 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 some microcontrollers. The devices offer 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. Input data (SDI) is latched on the internal strobe edge and output data (SDO) is shifted out on the shift edge (see Table 5 and Figure 7). There is one clock for each bit transferred. Address and data bits are transferred in groups of eight, MSB first. SCLK SDI SDO Input disabled Input disabled High impedance Data bit latch High impedance X Next data bit shift** CPOL = 1*, SCLK rising CPOL = 0, SCLK falling CPOL = 1, SCLK falling CPOL = 0, SCLK rising Note: CPHA bit polarity must be set to 1. *CPOL is the clock polarity bit that is set in the control register of the microcontroller. **SDO remains at high impedance until 8 bits of data are ready to be shifted out during a read. 11 MAX31722/MAX31723 Table 3. Configuration/Status Register Bit Descriptions (continued) MAX31722/MAX31723 Digital Thermometers and Thermostats with SPI/3-Wire Interface CPOL = 1 CE SHIFT INTERNAL STROBE SHIFT INTERNAL STROBE SCLK CPOL = 0 CE SCLK NOTE: CPOL IS A BIT THAT IS SET IN THE MICROCONTROLLER’S CONTROL REGISTER. Figure 7. Serial Clock as a Function of Microcontroller Clock Polarity (CPOL) Address and Data Bytes Address and data bytes are shifted MSB first into the serial-data input (SDI) and out of the serial-data output (SDO). Any transfer requires the address of the byte to specify a write or a read, followed by one or more bytes of data. Data is transferred out of the SDO for a read operation and into the SDI for a write operation. The address byte is always the first byte entered after CE is driven high. The MSB (A7) of this byte determines if a read or write takes place. If A7 is 0, one or more read cycles occur. If A7 is 1, one or more write cycles occur. Data transfers can occur 1 byte at a time in multiple-byte burst mode. After CE is driven high, an address is written to the devices. After the address, one or more data bytes can be written or read. For a single-byte transfer, 1 byte is read or written and then CE is driven low (see Figures 8 and 9). For a multiple-byte transfer, however, multiple bytes can be read or written to the devices after the address has been written (see Figure 10). A 12 single-byte burst read/write sequentially points through all memory locations and loops from 7Fh/FFh to 00h/80h. Invalid memory addresses report an FFh value. 3-Wire Serial-Data Bus The 3-wire communication mode operates similarly to the SPI mode. However, in 3-wire mode, there is one bidirectional I/O instead of separate data-in and dataout signals. The 3-wire consists of the I/O (SDI and SDO pins connected 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 devices followed by a single data byte or multiple data bytes. Figure 11 illustrates a read and write cycle. Figure 12 illustrates a multiple-byte burst transfer. In 3-wire mode, data is input on the rising edge of SCLK and output on the falling edge of SCLK. Digital Thermometers and Thermostats with SPI/3-Wire Interface MAX31722/MAX31723 CE SCLK SDI A7 SDO A6 A5 A4 A3 A2 A1 A0 HIGH-Z D7 D6 D5 D4 D3 D2 D1 D0 D7 D6 D5 D4 D3 D2 D1 D0 Figure 8. SPI Single-Byte Read CE SCLK SDI A7 SDO A6 A5 A4 A3 A2 A1 A0 HIGH-Z Figure 9. SPI Single-Byte Write CE SCLK WRITE SDI ADDRESS BYTE SDI ADDRESS BYTE DATA BYTE 0 DATA BYTE 1 DATA BYTE N DATA BYTE 0 DATA BYTE 1 DATA BYTE N READ SDO Figure 10. SPI Multiple-Byte Burst Transfer 13 MAX31722/MAX31723 Digital Thermometers and Thermostats with SPI/3-Wire Interface CE SCLK I/O* A0 A1 A2 A3 A4 A5 A6 A7 D0 D1 D2 D3 D4 D5 D6 D7 *I/O IS SDI AND SDO CONNECTED TOGETHER. Figure 11. 3-Wire Single-Byte Transfer CE SCLK I/O* ADDRESS BYTE DATA BYTE 0 DATA BYTE 1 DATA BYTE N *I/O IS SDI AND SDO CONNECTED TOGETHER. Figure 12. 3-Wire Multiple-Byte Burst Transfer Package Information For the latest package outline information and land patterns, go to www.maxim-ic.com/packages. Note that a “+”, “#”, or “-” in the package code indicates RoHS status only. Package drawings may show a different suffix character, but the drawing pertains to the package regardless of RoHS status. 14 PACKAGE TYPE PACKAGE CODE OUTLINE NO. LAND PATTERN NO. 8 FMAX U8+1 21-0036 90-0092 Digital Thermometers and Thermostats with SPI/3-Wire Interface REVISION NUMBER REVISION DATE 0 11/10 DESCRIPTION Initial release PAGES CHANGED — Maxim cannot assume responsibility for use of any circuitry other than circuitry entirely embodied in a Maxim product. No circuit patent licenses are implied. Maxim reserves the right to change the circuitry and specifications without notice at any time. Maxim Integrated Products, 120 San Gabriel Drive, Sunnyvale, CA 94086 408-737-7600 © 2010 Maxim Integrated Products 15 Maxim is a registered trademark of Maxim Integrated Products, Inc. MAX31722/MAX31723 Revision History