Rainbow Electronics DS1616 User Manual

A
A
A
A
r
www.maxim-ic.com
www.maxim-ic.com
DS1616
Temperature and Three-Input
Muxed 8-Bit Data Recorde
FEATURES
§ Measures four channels of data:
- Integrated 8-bit temperature sensor
- Integrated 8-bit analog-to-digital
converter (ADC) with a three-input mux
-40°C to +85°C in +0.5°C increments with ±2°C accuracy
§ Real-time clock/calendar (RTC) in BCD
format counts seconds, minutes, hours, date, month, day of the week, and year with leap­year compensation; fully Y2K-compliant
§ Automatically wakes up and measures
temperature and/or ADC data at user­programmable intervals from 1 to 255 minutes
§ 2048-byte datalog memory
§ Records long-term temperature histogram in
63 bins with +2.0°C resolution
§ Records long-term ADC data histogram in 64
bins with 4-bit resolution/bin (32 mV/bin) for ADC Channel 1
§ Programmable temperature-high and -low
alarm trip points
§ Programmable ADC data-high and -low alarm
trip points
§ Records time stamp and duration when
temperature or ADC Channel 1 Data leaves the interval specified by the trip points
§ Two serial interface options:
- 3-wire synchronous serial interface
- Asynchronous serial interface compatible with standard UARTs
§ Memory partitioned into 32-byte pages for
packetizing data
§ On-chip 16-bit CRC generator to safeguard
data read operations in asynchronous communications mode
§ Unique, factory lasered 64-bit serial number
PIN ASSIGNMENT (Top View)
V
BAT
X1
X2
GND
N.C.
COMSEL
INSPEC
OUTSPEC
N.C.
ST
INT
GND
1
2
3
4
5
6
7
8
9
10
11
12
DS1616 24 DIP (600mil)
DS1616S 24 SO (300mil)
Package Dimension Information
http://www.maxim-ic.com/TechSupport/DallasPackInfo.htm
24
23
22
21
20
19
18
17
16
15
14
13
V
CC
Rx
Tx
SCLK
I/O
RST
GND
GND
IN3
IN2
IN1
N.C.
PIN DESCRIPTION
V
BAT
X1 - Crystal Input X2 - Crystal Output AINx - Analog in
INSPEC - In-Specification Output
OUTSPEC - Out-of-Specification Output
INT - Interrupt Output
GND - Digital Ground AGND - Analog Ground
ST - Start/Status Input
RST - 3-Wire Reset Input
I/O - 3-Wire Input/Output SCLK - 3-Wire Clock Input Tx - Transmit Output Rx - Receive Input COMSEL - Communication Select V
CC
- Battery Supply
- +5V Supply
Note: Some revisions of this device may incorporate deviations from published specifications known as errata. Multiple revisions of any device may be simultaneously available through various sales channels. For information about device errata, click here: http://www.maxim-ic.com/errata.
1 of 28 081902
DS1616
ORDERING INFORMATION
PART PIN-PACKAGE TEMP RANGE
DS1616 24 DIP -40°C to +85°C DS1616S 24 SO 0°C to +70°C
DESCRIPTION
The DS1616 is an integrated temperature/data recorder. It combines a real-time clock (RTC), temperature sensor, and a three input muxed 8-bit Analog-to-Digital Converter (ADC). Data logging is supported for all four data channels and the and histogram functionality is supported for the temperature sensor and ADC Channel 1 only. A programmable sample rate feature makes the device ideal for applications requiring datalogging over short or long time frames.
The RTC provides seconds, minutes, hours, day, date, month, and year information with leap year compensation, Year 2000 compliance, and also provides an alarm interrupt. Temperature measurement is provided via integrated thermal technology which can measure temperatures from -40°C to +85°C in
0.5°C increments. An integrated three input muxed 8-bit ADC allows the device to record data from other types of sensors.
The datalog function samples data at a user-defined sample rate and writes the data to the Datalog memory. A total of 2048 bytes of data may be recorded. If only one data channel is selected, a total of 2048 samples can be recorded for that channel. If two channels are enabled, each channel can record 1024 samples. If three or four channels are enabled, each channel can record 512 samples. In the case of only three channels enabled, the location corresponding to the disabled channel will be 0 to allow the roll­over function to work smoothly.
Histogram functionality is provided for the Thermal Sensor and ADC Channel 1, and is implemented by sampling the data and then incrementing the count value in a data bin associated with that value. The DS1616 provides 63 2-byte data bins in 2°C increments for the temperature channel and 64 2-byte data bins in 4-bit resolution steps (32mV/bin) for the ADC Data Channel 1. The sampling rate can be programmed at intervals ranging from once per minute to once every 255 minutes.
The DS1616 provides programmable high- and low-temperature alarm trip points that allow the device to monitor whether the temperature stays within desired limits. Likewise, high- and low- trip points can be programmed for the ADC data. The device can drive an interrupt or status pin if the ADC data falls outside of the programmable limits. The Temperature Sensor and Channel 1 of the ADC can also have any event that falls outside of the programmed limits recorded with a time and date stamp and the duration of the out-of-limits condition for additional analysis in the Alarm Memory. The DS1616 can be programmed to begin sampling data via a pushbutton input or via a command sent over the serial interface by a host machine.
A 64-bit serial number is available for unique product identification and tracking.
OVERVIEW
The block diagram in Figure 1 shows the relationship between the major control and memory sections of the DS1616. The device has six major data components: 1) RTC and control blocks, 2) 32-byte User NV RAM with 64-bit lasered serial number, 3) 96 bytes of alarm event/duration memory, 4) 128 bytes of temperature histogram RAM, 5) 128 bytes of ADC Channel 1 data histogram RAM, and 6) 2048 bytes of datalog memory. All memory is arranged in a single linear address space.
2 of 28
DS1616 Block Diagram Figure 1
SCLK
RST
I/O
COMSEL
Tx
Rx
X1
OSCILLATOR
AND
X2
DIVIDER
ST
INSPEC
OUTSPEC
INT
INTERNAL RTC AND CONTROL
REGISTERS
CONTROL
LOGIC
SERIAL
INTER FACE
DS1616
MEMORY
FUNCTION
CONTROL
RTC AND CONTROL
REGISTERS
USER NVRAM
OPTIONAL
SERIAL NUMBER
ALARM TIME STAMP
AND DURATION
LOGGING MEMORY
HISTOGRAM MEMORY
DATALOG MEMORY
AIN
3 TO 1 MUX
A/D
CONVERTER
TEMPERATURE
SENSOR
SIGNAL DESCRIPTIONS
The following paragraphs describe the function of each pin.
VCC - VCC is a +5-volt input supply. Communication with the DS1616 can take place only when VCC is connected to a +5-volt supply.
- Battery input for standard lithium cell or other energy source. All functions of the DS1616 with the
V
bat
exception of the serial interface circuitry are powered by V powered by V
when VCC > V
CC
. If a battery or other energy source is not used, V
bat
connected directly to GND.
GND - GND connections are not internally connected, so all GND connections must be connected directly to ground.
AGND - Analog ground should be connected directly to digital ground externally to eliminate ground noise and potential differences.
when VCC < V
bat
. All functions are
bat
should be
bat
COMSEL (Communication Select Input) - This pin determines whether serial communication is asynchronous or synchronous. When pulled high to V
place via the SCLK, I/O, and
RST pins. When COMSEL is tied to ground, asynchronous communication
, communication is synchronous and will take
CC
utilizing the TX and RX pins is selected. If this pin is floated, the DS1616 will operate in the asynchronous communications mode since the COMSEL pin has a weak internal pulldown resistor.
3 of 28
DS1616
Tx (Transmit Output) - Transmit output of the asynchronous serial interface. Tx is tri-stated whenever VCC < V
bat
.
Rx (Receive Input) - Receive input of the asynchronous serial interface.
SCLK (3-Wire Serial Clock Input) - The SCLK pin is the serial clock input for the 3-wire synchronous
communications channel.
I/O (3-Wire Input/Output) - The I/O pin is the data Input/Output signal for the 3-wire synchronous communications channel.
RST (3-Wire Reset Input) - The RST pin is the communications reset pin for the 3-wire synchronous
communications channel.
NTI (Interrupt Output) - The INT pin is an open drain active low output that can be connected to an
interrupt input of a microprocessor. The
INT output remains low as long as the status bit causing the
interrupt is present and the corresponding interrupt-enable bit is set.
INSPEC (Open Drain In-Specification Output) - This pin, in conjunction with the OUTSPEC pin, is
used to signal the status of the operation and data of the DS1616.
OUTSPEC (Open Drain Out-of-Specification Output) - This pin, in conjunction with the INSPEC pin,
is used to signal the status of the operation and data of the DS1616.
ST (Start/Status Button Input) - The ST pin provides two functions. First, when enabled as the datalog
start source (SE bit in Control 1 register is a logic 1), the ST pin is used to instruct the DS1616 to begin
recording data based on the programmed start delay and data sample rate. The ST pin must be held low for at least 0.5 seconds for a datalog mission to begin.
Secondly, the ST pin can be used to poll the status of the recorded data. After datalogging has begun, the
ST pin instructs the DS1616 to report the status of the recorded data via the INSPEC and OUTSPEC pins.
AIN1, AIN2, AIN3 (Analog Inputs) - The AINx pins are the muxed inputs to the ADC.
X1, X2 - Connections for a standard 32.768 kHz quartz crystal, Daiwa part number DT-26S or
equivalent. For greatest accuracy, the DS1616 must be used with a crystal that has a specified load capacitance of 6 pF. There is no need for external capacitors or resistors. Note: X1 and X2 are very high impedance nodes. It is recommended that they and the crystal be guard-ringed with ground and that high frequency signals be kept away from the crystal area. For more information on crystal selection and crystal layout considerations, refer to Application Note 58: Crystal Considerations with Dallas Real-Time Clocks.
N.C. (No Connect) - These pins should be left unconnected or tied to ground.
4 of 28
DS1616
MEMORY
The memory map in Figure 2a shows the general organization of the DS1616. As can be seen in the figure, the device is segmented into 32-byte pages. Pages 0 and 1 contain the RTC and Control registers (see Figure 2b for more detail). The User NV RAM resides in page 2. Pages 17 to 19 are assigned to storing the alarm time stamps and durations and pages 64 to 71 are reserved for histogram memory. The data logging memory covers pages 128 to 191. Memory pages 3 to 16, 20 to 63, 68 to 127, and 192 and up are reserved for future extensions.
The end user can write only to the RTC and Control registers and the User NV RAM. The rest of the memory map is read-only from the end user’s perspective.
DS1616 MEMORY MAP Figure 2a
Address Register definition Page(s)
0000H 003FH 0040H 005FH 0060H 0217H
0218H 021FH 0220H 027FH 0280H
07FFH
0800H
087FH
0880H
08FFH
0900H
0FFFH
1000H
17FFH
1800H
and higher
RTC and Control Registers 0 - 1
User NV RAM 2
(Reserved for Future Extensions) 3 – 16*
Serial Number 16**
Alarm Time Stamps and Durations 17 – 19
(Reserved for Future Extensions) 20 – 63
Temperature Histogram (63 Bins of 2 Bytes Each) 64 – 67
ADC Channel 1 Data Histogram (64 Bins of 2 Bytes Each) 68 – 71
(Reserved for Future Extensions) 72 – 127
Datalog Memory (64 pages) 128 – 191
(Reserved for Future Extensions) 192 +
* First 8 bytes ** Last 8 bytes
5 of 28
DS1616 RTC AND CONTROL PAGE Figure 2b
Addr. Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0 Function
00 0 10 Seconds Single Seconds 01 0 10 Minutes Single Minutes
10 h02 0 12/24
A/P 030 0 000 Day Of Week 04 0 0 10 Date Single Date 05 Y2K 0 0 10 m. Single Months 06 10 Years Single Years 07 MS 10 Seconds Alarm Single Seconds Alarm 08 MM 10 Minutes Alarm Single Minutes Alarm
10 ha.09 MH 12/24
A/P
0A MD 0 0 0 0 Day Of Week Alarm 0B Low Temperature Threshold 0C High Temperature Threshold 0D Number Of Minutes Between Temperature Conversions Sample Rate 0E
0F (reads 00h) Reserved
10 (reads 00h) Reserved 11 Current Temperature Temperature 12 Start Delay Register (LSB) Start Delay 13 Start Delay Register (MSB) Start Delay 14 DR MEM CLR MIP SIP LOBAT TLF THF ALMF Status 1 15 Minutes 16 Hours 17 Date 18 Y2K Month 19 Year
1A Low Byte 1B Medium Byte 1C High Byte 1D Low Byte 1E Medium Byte 1F High Byte
20 Current ADC Channel 1 Data Sensor Input
21 Current ADC Channel 2 Data Sensor Input
22 Current ADC Channel 3 Data Sensor Input
23 Low ADC Channel 1 Data Threshold ADC Data 24 High ADC Channel 1 Data Threshold Ch1 Alarm 25 Low ADC Channel 2 Data Threshold ADC Data 26 High ADC Channel 2 Data Threshold Ch2 Alarm 27 Low ADC Channel 3 Data Threshold ADC Data 28 High ADC Channel 3 Data Threshold Ch3 Alarm 29 0 CS0
2A 0 ALF1 AHF1 ALF2 AHF2 ALF3 AHF3 0 Status 2
2B-3F (reads 00h) Reserved
EOSC
CLR 0 SE RO TLIE THIE AIE Control 1
CS1
(Temp)
(ADC 1)
10 h Single Hours
10 h.
alm.
CS2
(ADC 2)
CS3
(ADC 3)
Single Hours Alarm
ALIE AHIE 0 Control 2
Real­Time
Clock
Registers
Real­Time
Clock
Alarm
Temperature
Alarm
Start
Time
Stamp
Current
Samples
Counter
Total
Samples
Counter
DS1616
1
2
3
6 of 28
DS1616 ALARM TIME STAMPS AND DURATIONS FOR THE THERMAL SENSOR AND ADC CHANNEL 1 Figure 2c
Sample Counter Address
(Low, Medium, High Bytes)
220, 221, 222 223 T1 Low 224, 225, 226 227 T2 Low 228, 229, 22A 22B T3 Low 22C, 22D, 22E 22F T4 Low 230, 231, 232 233 T5 Low 234, 235, 236 237 T6 Low 238, 239, 23A 23B T1 High 23C, 23D, 23E 23F T2 High 240, 241, 242 243 T3 High 244, 245, 246 247 T4 High 248, 249, 24A 24B T5 High 24C, 24D, 24E 24F T6 High 250, 251, 252 253 D1 Low 254, 255, 256 257 D2 Low 258, 259, 25A 25B D3 Low 25C, 25D, 25E 25F D4 Low 260, 261, 262 263 D5 Low
264, 265, 266 267 D6 Low 268, 269, 26A 26B D1 High 26C, 26D, 26E 26F D2 High 270, 271, 272 273 D3 High 274, 275, 276 277 D4 High 278, 279, 27A 27B D6 High 27C, 27D, 27E 27F D6 High
Duration
Address
Register
DS1616
DS1616 TEMPERATURE HISTOGRAM DATA BINS Figure 2d
Address (Low – High Byte) Register
800 – 801 -40, -39.5, -39, -38.5°C Data Bin 802 – 803 -38, -37.5, -37, -36.5°C Data Bin
804
87B
87C – 87D 84, 84.5, 85°C Data Bin
DS1616 ADC DATA HISTOGRAM DATA BINS Figure 2e
Address (Low – High Byte) Register
880 – 881 Channel 1 Code 00, 01, 02, 03h Data Bin 882 – 883 Channel 1 Code 04, 05, 06, 07h Data Bin
884
8FD
8FE – 8FF Channel 1 Code FC, FD, FE, FFh Data Bin
THERMAL SENSOR
The key to temperature monitoring in the DS1616 is an integrated thermal sensor. The thermal sensor can measure temperature from -40°C to +85°C in 0.5°C increments (Fahrenheit equivalent is -40°F to +183.2°F in 1.8°F increments). The thermal sensor provides an accuracy of ±2°C.
7 of 28
DS1616
The thermal sensor is enabled by setting the CS0 bit of the Control 2 register to a logic 1. If the CS0 bit is a logic 0, the thermal sensor will not be activated during a datalogging mission or for an individual Read Data command. If CS0 = 0, the value in the Current Temperature register will be 11111111b.
The format of temperature data is defined such that the temperature value is maintained in a single byte of data. Table 1 illustrates the format of the temperature data byte format. The values of T[7..0] range from 00000000b (for -40°C) to 11111010b (for +85°C). Each increment in the value of T[7..0] represents an increase in temperature of 0.5°C. The following formula can be used to translate the temperature data byte value into degrees Celsius: °C = 0.5(T[7..0]) - 40
TEMPERATURE DATA BYTE FORMAT Table 1
MSb LSb
T7 T6 T5 T4 T3 T2 T1 T0
When a datalog mission has been initiated and the thermal sensor is enabled (CS0=1), the DS1616 provides temperature recording at regular intervals. However, the device also allows for immediate temperature sensing upon a user’s command when the device is not currently on a datalog mission and the thermal sensor is enabled (CS0=1). This is accomplished by issuing the Read Data command to the DS1616 over the serial interface.
The most recently recorded temperature value is written to the Current Temperature register, regardless of whether that value was recorded from a datalog mission or from the issuance of the Read Data command. The status of the contents of this register is provided by the Data Ready (DR) bit in the Status 1 register. If DR is a logic 1, the data is valid. If DR is a logic 0, the data may not be reliable. If CS0 in the Control 2 register is a 0 such that the thermal sensor is disabled, the value in the Current Temperature register will be 11111111b. The Read Data command will not output this byte of data.
During a datalog mission, the DR bit is cleared to a logic 0 when a temperature conversion has been initiated and is set to a logic 1 upon the completion of the conversion. Likewise, the DR bit is cleared immediately after the Read Data command is issued and is set to a logic 1 upon the completion of the conversion. The Read Data command will only read the values in the current temperature/ADC data that have been enabled by the CSx[03] bits in the control 2 register.
ANALOG-TO-DIGITAL CONVERTER (ADC)
The DS1616 contains an integrated 8-bit ADC with a 3 to 1 input mux to allow multiple sensors to be monitored. An on-chip voltage reference is also provided by an integrated band gap circuit (2.04V ±3%). The ADC input voltage must not be greater than the battery voltage.
An analog-to-digital conversion is the process of assigning a digital value to an analog input voltage. This code represents the input value as a fraction of the full scale voltage (FSV) range. Thus the FSV range is then divided by the ADC into 256 codes (8 bits). The FSV range is bounded by an upper limit equal to the reference voltage and the lower limit, which is ground. The 2.04V (typical) bandgap reference provides a resolution of 8mV between codes.
An input voltage equal to the reference voltage converts to FFh while an input voltage equal to ground converts to 00h. The relative linearity of the ADC is ±0.5 LSB.
When a datalog mission has been initiated and one or more of the Analog Inputs are enabled (CS[1-3] =
1), the DS1616 provides data conversion and recording at regular intervals. However, the device also
8 of 28
DS1616
allows for immediate data conversion upon a user’s command when the device is not currently performing a conversion and one or more of the Analog Inputs are enabled (CS[1-3] = 1). This is accomplished by issuing the Read Data command to the DS1616 over the serial interface.
The most recently recorded data value is written to the Current Data register that corresponds to the analog channel(s) that is(are) enabled, regardless of whether that value was recorded from a datalog mission or from the issuance of the Read Data command. The status of the contents of this register is provided by the Data Ready (DR) bit in the Status 1 register. If DR is a logic 1, the data is valid. If DR is a logic 0, the data may not be reliable. If a channel is not enabled, CS[1-3] is a logic 0, the contents of the corresponding Current Data register will be 00000000b and not outputted when a Read Data command is issued. During a datalog mission, the DR bit is cleared to a logic 0 when a data conversion has been initiated and is set to a logic 1 upon the completion of the conversion. Likewise, the DR bit is cleared immediately after the Read Data command is issued and is set to a logic 1 upon the completion of the conversion.
DATA LOGGING
When the DS1616 datalogging function is enabled, the device is said to be on a “datalog mission” until the datalogging is stopped.
During a datalog mission, temperature and/or ADC samples are successively written to the Datalog memory pages. These memory pages are located at addresses 1000h to 17FFh.
The end user can program the DS1616 to record data from all four data channels or just one channel. Channel selection is determined by the setting the Channel Select bits (CS0, CS1, CS2 and CS3) in the Control 2 register to the appropriate states. A 1 in the CSx bit will enable the channel and allow the results to be reported, while a 0 will disable the channel, prevent its data from being recorded, prevent the data from being reported by the Read Data command, and set the contents of the memory location for the Current Data register corresponding to that channel to a constant value, all 1s for the thermal sensor or all 0s for the ADC channels.
When 3 or 4 data channels are selected, the first data sample is written to address location 1000h, the second is written to address location 1001h. The address is incremented with each additional data sample, with samples alternating between the enabled channels. The second sample is always measured immediately after the completion of the first measurement with the third and forth samples following the second. The order of the sampling is the same as the order of the Channel Select registers. CS0 will be sampled first, if it is enabled, followed by CS1, CS2 and CS3 if they are enabled. Any disabled channels will be skipped. A total of 2048 registers have been reserved for datalog data, providing a total of 512 samples for each channel.
When three out of the four channels are enabled, a fourth byte of all 0s will be recorded in the Datalog Memory after the three bytes of data from the enabled channels in order to allow the data to rollover and remain in the correct positions.
When two data channels are selected, the first data sample is written to address location 1000h and the second is then written to address location 1001h. The address is incremented with each additional data sample, with samples alternating between the enabled channels.
The second sample is always measured immediately after the completion of the first measurement. A total of 2048 registers have been reserved for datalog data, providing a total of 1024 samples each channel.
9 of 28
Loading...
+ 19 hidden pages