B&B Electronics VFG3000 - Manual User Manual
Page 173

C
ONFIGURING
D
ATA
L
OGGING
T
HE
L
OGGING
P
ROCESS
R
EVISION
1
P
AGE
157
T
HE
L
OGGING
P
ROCESS
Fieldbus Gateway Manager’s data logger operates using two separate processes. The first
samples each data point at the rate specified in its properties, and places the logged data into a
buffer within the RAM of the Fieldbus Gateway. The second process executes every two
minutes, and writes the data from RAM to the CompactFlash card. This structure has several
advantages…
•
Writes to the CompactFlash card are guaranteed to begin only on a two-minute
boundary—that is, at exactly 2, 4 or 6 minutes past the hour, and so on. This
means that if your Fieldbus Gateway supports hot-swapping of CF cards, you
can wait for the next burst of writes to start, and, when the CompactFlash
activity LED on the front of the Gateway ceases to flicker, you are guaranteed to
have until the start of the next two-minute interval before further writes will be
attempted. This means that you can remove the card without fear of data
corruptions. As long as you insert a new card before four minutes have elapsed,
no data will be lost.
•
Writes to the CompactFlash achieve a much higher level of performance, by
avoiding the need to continually update the card’s file system data structures for
every single sample. For logs configured to sample at very high data rates, the
bandwidth of a typical CompactFlash card would not allow data to be written
reliably in the absence of such a buffering process.
Note that because data is not committed to CompactFlash for up to two minutes, up to this
amount of log data may be lost when the terminal is powered-down. Further, if the terminal is
powered-down while a write is in progress, the CompactFlash card may be corrupted. To
ensure that such corruption is not permanent, the Fieldbus Gateway uses a journaling system
that caches writes to additional non-volatile memory within the terminal. If the Gateway
detects that a write was interrupted during power-down, the write will be repeated when
power is reapplied, thereby reversing any corruption, and repairing the CompactFlash card.
This means that if you want to remove a CompactFlash card from a Gateway performing data
logging, you must observe the procedure described above with respect to the activity LED,
and only remove power when the activity has ceased. If you are not sure if the terminal was
powered-down correctly, reapply power, allow a CompactFlash write sequence to complete,
and power down according to the correct procedure. The card can then be removed safely.
Since the gyrations required to remove a CompactFlash card are somewhat complex, Fieldbus
Gateway Manager provides two other mechanisms for accessing log files, thereby eliminating
the need for such removals. These methods are described below.
A
CCESSING
L
OG
F
ILES
There are three additional methods of accessing log files…
•
The less preferable method is to mount the card as a drive on a PC via the
process described at the start of this manual, so that the logs can be copied using
Windows Explorer. Note that Windows 2000 or above is recommended when