The annot argument of getann
and putann
is an
object of type DB_Annotation
containing these fields:
long time
char anntyp
ACMAX
(defined in
`<ecg/ecgcodes.h>'). See section Annotation Codes, for a list of
legal annotation codes.
signed char subtyp
signed char chan
signed char num
subtyp
field is used with noise and artifact annotations to
indicate which signals are affected (see section Annotation Codes).
The chan
field is intended to indicate the signal to which the
annotation is attached. More than one annotation may be written with
the same time
if the chan
fields are distinct and in
ascending order. The semantics of the chan
field are
unspecified, however; users may assign any desired meaning, which need
not have anything to do with signal numbers. In user-created annotation
files, these fields can be used to store arbitrary small integers. The
subtyp
field requires no space in a standard annotation file
unless it is non-zero; the chan
and num
fields require no
space unless they have changed since the previous annotation.
char *aux
unsigned
char
that specifies the number of bytes that follow (up to 255). In
MIT DB `atruth' files, the aux
field is used with rhythm
change annotations to specify the new rhythm, and with comment
annotations to store the text of the comment
(see section Annotation Codes).
The string can contain arbitrary binary
data, including embedded nulls. It is unwise to store anything but ASCII
strings, however, if the annotation file may be transported to a system with
a different architecture (e.g., on which multiple-byte quantities may have
different sizes or byte layouts). The aux
field requires no
space in a standard annotation file if it is NULL
. Note that
conversion of annotation files to other formats may entail truncation or
loss of the aux
string. Note also that the aux
pointer
returned by getann
points to a small static buffer (separately
allocated for each input annotator beginning with DB library version
9.4) that may be overwritten by subsequent calls.
See section Example 3: An Annotation Printer, for a short program that examines the contents of a
DB_Annotation
.
Go to the first, previous, next, last section, table of contents.