Operation—thermostat function – Rainbow Electronics DS1726 User Manual
Page 7

DS1626/DS1726
7 of 13
Table 4. 12-BIT RESOLUTION TEMPERATURE/DATA RELATIONSHIP
TEMPERATURE
(
°C)
DIGITAL OUTPUT
(BINARY)
DIGITAL OUTPUT
(HEX)
+125
0111 1101 0000
7D0h
+25.0625
0001 1001 0001
191h
+10.125
0000 1010 0010
0A2h
+0.5
0000 0000 1000
008h
0
0000 0000 0000
000h
-0.5
1111 1111 1000
FF8h
-10.125
1111 0101 1110
F5Eh
-25.0625
1110 0110 1111
E6Fh
-55
1100 1001 0000
C90h
OPERATION—THERMOSTAT FUNCTION
The DS1626/DS1726 thermostat outputs (T
HIGH
, T
LOW
, and T
COM
) are updated after every temperature
conversion and remain at the updated values until the next conversion completes. T
HIGH
is
asserted
when the measured temperature is higher than or equal to the value stored in the T
H
register, and T
LOW
is asserted when the temperature is equal to or falls below the value in the T
L
register (see Figure 5).
T
COM
uses both T
H
and T
L
to provide programmable hysteresis: when the measured temperature equals
or exceeds T
H
, T
COM
is asserted and it remains asserted until the temperature falls to a value equal to or
below T
L
. All three thermostat outputs are active-high outputs.
The Write TH and Write TL commands are used to program the 12-bit T
H
and T
L
registers with user-
defined two’s complement values. The MSb (bit 11) of each register contains the two’s complement
sign bit (S). For the T
COM
thermostat output to function correctly, the T
L
value must be less than the T
H
value. Any unused LSbs in the T
H
and T
L
registers are forced to 0 regardless of the data written to
those bits. The unused LSbs are determined by the conversion resolution set by R1 and R0 in the
configuration register. Therefore, for 9-bit conversions bits 2 through 0 will be 0, for 10-bit
conversions bit 1 and bit 0 will be 0, and for 11-bit conversions bit 0 will be 0. All bits are used for 12-
bit conversions, so no bits are forced to 0. However, regardless of the conversion resolution, when
writing to T
H
or T
L
at least 12 bits must be sent following the Write TH or Write TL commands. The
reason is that data written to T
H
and T
L
is not saved to EEPROM until the DS1626/DS1726 have
received 12 bits, so if the operation is terminated before 12 bits have been received, the data will be
lost. Any additional bits sent after the first twelve are ignored (e.g., if two 8-bit words are written).
Another DS1626/DS1726 thermostat feature is the temperature-high flag (THF) and temperature-low
flag (TLF) in the configuration register. These bits provide a record of whether the temperature has
been greater than or equal to T
H
or less than or equal to T
L
at any time since the DS1626/DS1726 were
powered up. If the temperature is greater than or equal to the T
H
register value, the THF bit in the
configuration register will be set to 1. If the temperature is less than or equal to the T
L
register value,
the TLF bit in the configuration register will be set to 1. Once THF and/or TLF has been set, it will
remain set until the user overwrites it with a 0 or until the power is cycled.