Magcard bitstream input, Hardware considerations, Example – Echelon I/O Model Reference for Smart Transceivers and Neuron Chips User Manual
Page 94
84
Serial I/O Models
// i2c I/O object with the stop condition specified
return
-
value
= io_in(
io
-
object
-
name
,
data
-
buffer
,
dev
-
address
,
count
,
stop
);
return
-
value
= io_out(
io
-
object
-
name
,
data
-
buffer
,
dev
-
address
,
count
,
stop
);
Example
#define AD_ADDR 0x48 // address of the A/D converter
IO_8 i2c ioI2C;
unsigned int buffer[5];
unsigned int control;
boolean result;
. . .
when (...) {
// Read the A/D converter.
// First, write a control word byte.
control = 0x04;
result = io_out(ioI2C, &control, AD_ADDR, 1);
// Next, perform a 5-byte read of the A/D converter.
result = io_in(ioI2C, buffer, AD_ADDR, 5);
}
Magcard Bitstream Input
The magcard_bitstream I/O model provides the ability to read un-processed serial
data streams from most magnetic stripe card readers in real time. This model
can be used to read magnetic card data in either direction, forward or reverse,
because the data does not need to follow any specific format.
This I/O model can read up to 65 535 bits of data, stored in 8192 bytes of data,
from a magnetic stripe card reader.
This model applies to 3120 Power Line Smart Transceivers, 3150 Power Line
Smart Transceivers, 3170 Power Line Smart Transceivers, and Series 5000
Neuron Processors and Smart Transceivers.
Hardware Considerations
Figure 30 shows the magcard bitstream input.
Serial Data
Clock
IO10
IO9
IO8
IO0
IO1
IO2
IO3
IO4
IO5
IO6
IO7
Timeout
IO11
Figure 30. Magcard Bitstream Input