10 cf cards & records number – Campbell Scientific CR3000 Micrologger User Manual
Page 419

Section 8. Operation
419
8.10 CF Cards & Records Number
The number of records in a data table when CardOut() or TableFile() with
Option 64
is used in a data-table declaration is governed by these rules:
1. Both CF card memory (CRD: drive) and internal memory (CPU) keep copies
of data tables in binary TOB3 format. Collectible numbers of records for both
CRD: and CPU are reported in DataRecordSize entries in the Status table.
2. In the table definitions advertised to datalogger support software
(p. 76),
the
CR3000 advertises the greater of the number of records recorded in the Status
table, if the tables are not fill-and-stop.
3. If either data area is flagged for fill-and-stop, then whichever area stops first
causes all final-data storage to stop, even if there is more space allocated in the
non-stopped area, and so limiting the number of records to the minimum of the
two areas if both are set for fill-and-stop.
4. When CardOut() or TableFile() with
Option 64
is present, whether or not a
card is installed, the CPU data-table space is allocated a minimum of roughly
5 kB so that there is at least a minimum buffer space for storing the data to
CRD: (which occurs in the background when the CR3000 has a chance to
copy data onto the card). So, for example, a data table consisting of one four-
byte sample, not interval driven, 20 bytes per record, including the 16-byte
TOB3 header/footer, 258 records are allocated for the internal memory for any
program that specifies less than 258 records (again only in the case that
CardOut() or TableFile() with
Option 64
is present). Programs that specify
more than 258 records report back what the user specified, and the number of
records on the card specified by the user is always reported back as specified
in the Status table, with no minimum since it is not used for buffering as is the
internal data-table space.
5. When CardOut() or TableFile() with
Option 64
is used but the card is not
present, zero bytes are reported in the Status table.
6. In both the internal memory and CF card data-table spaces, about 2 kB of
extra space is allocated (about 100 extra records in the above example) so that
for the ring memory, the possibility is minimized that new data will overwrite
the oldest data when datalogger support software
(p. 76)
tries to collect the
oldest data at the same time. These extra records are not reported in the
Status table and are not reported to the datalogger support software and
therefore cannot be collected. The only interest the user might have would be
the extra space allocated for the data table that comes out of the 4 MB of
memory in the typical dataloggers.
7. If the CardOut() or TableFile() with
Option 64
instruction is set for fill-and-
stop, all the space reserved for records on the card is recorded before final-data
storage is stopped, including the extra 2 kB allocated to alleviate the conflict
of storing the newest data while reading the oldest when the area is not fill-
and-stop, i.e., is ringing around. Therefore, if the CPU does not stop earlier,
or is ring and not fill-and-stop, then more records will be stored on the card
than originally allocated, i.e., about 2 kB worth of records, assuming no
lapses. At the point final data storage is stopped, the CR3000 recalculates the
number of records, displays them in the Status table, and advertises a new
table definition to the datalogger support software. Further, if the table is
storing relatively fast, there might be some additional records already stored in