Common ancestor of drivers based on circular I/O buffers.
hal_base_driver.xml
hal_channels.xml
Ancestor class of serial buffered drivers.
oqueue, bp, n, TIME_INFINITE);]]>
iqueue, bp, n, TIME_INFINITE);]]>
oqueue, b, TIME_INFINITE);]]>
iqueue, TIME_INFINITE);]]>
oqueue, bp, n, timeout);]]>
iqueue, bp, n, timeout);]]>
oqueue, b, timeout);]]>
iqueue, timeout);]]>
Input queue.
Output queue.
I/O condition event source.
pointer to the input
buffer
size of the input
buffer
parameter for the input
notification callback
pointer to the output
buffer
size of the output
buffer
parameter for the output
notification callback
event);
iqObjectInit(&self->iqueue, ib, ibsize, inotify, iarg);
oqObjectInit(&self->oqueue, ob, obsize, onotify, oarg);]]>
Handles incoming data.
the byte to be written
to the driver's Input Queue
iqueue)) {
bsAddFlagsI(self, CHN_FL_RX_NOTEMPTY);
}
if (iqPutI(&self->iqueue, b) < MSG_OK) {
bsAddFlagsI(self, CHN_FL_BUFFER_FULL_ERR);
}]]>
Handles outgoing data.
The byte value read from the driver's output queue.
If the queue is empty.
oqueue);
if (b < MSG_OK) {
/* Note, this event is only added when the buffer becomes fully empty in
order to avoid continuous reporting.*/
bsAddFlagsI(self, CHN_FL_TX_NOTFULL);
}
return b;]]>
Adds status flags to the flags mask.
Event flags to
be added.
event, flags);]]>
hal.h