DEVICE DRIVERS
msrRead
36 M
X
800 SERIES PROGRAMMERS GUIDE
msrRead
Read the decoded and formatted MSR data. If the device is not opened with the
O_NONBLOCK flag set, this call will be blocked until data is available.
Prototype
int bytes_read = msrRead(char *buffer, int size);
Parameters
The format of the buffer returned will be:
where:
The data includes the Start Sentinel, End Sentinel, and the LRC
characters. They were not included in the Omni 7xxx.
buffer Pointer to data area
size Maximum number of bytes to read. Each invocation of read will
transfer data from a card reader scan into the buffer.
c1 s1 d1 c2 s2 d2 c3 s3 d3
c1 a one byte size of c1+s1+d1
s1 a one byte status of reading track 1
d1 any data read in (might not exist)
c2 a one byte size of c2+s2+d2
s2 a one byte status of reading track 2
d2 any data read in (might not exist)
c3 a one byte size of c3+s3+d3
s3 a one byte status of reading track 3
d3 any data read in (might not exist)