DS1923 Maxim, DS1923 Datasheet - Page 29

no-image

DS1923

Manufacturer Part Number
DS1923
Description
The DS1923 temperature/humidity logger iButton® is a rugged, self-sufficient system that measures temperature and/or humidity and records the result in a protected memory section
Manufacturer
Maxim
Datasheet

Available stocks

Company
Part Number
Manufacturer
Quantity
Price
Part Number:
DS1923-F5#
Manufacturer:
Maxim
Quantity:
2
Part Number:
DS1923-F5#
Manufacturer:
MAXIM/美信
Quantity:
20 000
efficiency, the target address for writing should point to
the beginning of a page, i.e., the byte offset is 0. Thus,
the full 32-byte capacity of the scratchpad is available,
resulting also in the ending offset of 1Fh. The ending
offset together with the PF flag are a means to support
the master checking the data integrity after a Write
Scratchpad command. The highest valued bit of the
E/S register, called authorization accepted (AA), indi-
cates that a valid Copy Scratchpad command for the
scratchpad has been received and executed. Writing
data to the scratchpad clears this flag.
To write data to the DS1923, the scratchpad must be
used as intermediate storage. First, the master issues
the Write Scratchpad command to specify the desired
target address, followed by the data to be written to the
scratchpad. In the next step, the master sends the
Read Scratchpad command to read the scratchpad
and to verify data integrity. As preamble to the scratch-
pad data, the DS1923 sends the requested target
address TA1 and TA2 and the contents of the E/S
Register. If the PF flag is set, data did not arrive cor-
rectly in the scratchpad. The master does not need to
continue reading; it can start a new trial to write data to
the scratchpad. Similarly, a set AA flag indicates that
the Write Scratchpad command was not recognized by
the device. If everything went correctly, both flags are
cleared and the ending offset indicates the address of
the last byte written to the scratchpad. Now the master
can continue verifying every data bit. After the master
has verified the data, it must send the Copy Scratchpad
command. This command must be followed exactly by
the data of the three address registers TA1, TA2, and
E/S, as the master has read them verifying the scratch-
pad. As soon as the DS1923 has received these bytes,
it copies the data to the requested location beginning
at the target address.
Hygrochron Temperature/Humidity Logger
______________________________________________________________________________________
Writing with Verification
iButton with 8KB Data-Log Memory
Figure 9 shows the protocols necessary for accessing
the memory and the special function registers of the
DS1923. An example on how to use these and other
functions to set up the DS1923 for a mission is included
in the Mission Example: Prepare and Start a New
Mission section. The communication between the mas-
ter and the DS1923 takes place either at standard
speed (default, OD = 0) or at overdrive speed (OD =
1). If not explicitly set into the overdrive mode, the
DS1923 assumes standard speed. Internal memory
access during a mission has priority over external
access through the 1-Wire interface. This affects sever-
al commands in this section. See the Memory Access
Conflicts section for details and solutions.
After issuing the Write Scratchpad command, the mas-
ter must first provide the 2-byte target address, fol-
lowed by the data to be written to the scratchpad. The
data is written to the scratchpad starting at the byte off-
set T[4:0]. The master must send as many bytes as are
needed to reach the ending offset of 1Fh. If a data byte
is incomplete, its content is ignored and the partial byte
flag PF is set.
When executing the Write Scratchpad command, the
CRC generator inside the DS1923 calculates a CRC of
the entire data stream, starting at the command code
and ending at the last data byte sent by the master
(Figure 15). This CRC is generated using the CRC-16
polynomial by first clearing the CRC generator and then
shifting in the command code (0Fh) of the Write
Scratchpad command, the target addresses TA1 and
TA2 as supplied by the master, and all the data bytes.
If the ending offset is 11111b, the master can send 16
read time slots and receive the inverted CRC-16 gener-
ated by the DS1923.
Note that both register pages are write protected dur-
ing a mission. Although the Write Scratchpad command
works normally at any time, the subsequent copy
scratchpad to a register page fails during a mission.
Function Commands
Memory and Control
Write Scratchpad [0Fh]
29

Related parts for DS1923