|
|
Component
FreescaleUHFTransmitter
UHF Transmitter
Component Level: Low
Category:
CPU Internal Peripherals-Communication
Typical Usage:
(Examples of a typical usage of the component in user code.
For more information please
see the page Component Code
Typical Usage.)
Assume the component name "UHFT1". There is the following typical usage:
MAIN.C
/* Maximal bytes count */
#DEFINE N (65536 / 8 - 1)
/* UHF transmitter requires first data bit "1" to */
/* start transfer. Leading "0" bits are ignored. */
byte buffer[N] = {1, };
void main(void)
{
word received;
for (;;) {
.
.
.
ReceiveDataFromAnyPeripheral(buffer + 1, /* store to */
N - 1, /* max count */
&received); /* received bytes */
.
.
.
/* number of bits to transfer including */
/* first 0x01 byte to wakeup transmitter */
UHFT1_SendBitBlock(buffer, received*8 + 8);
.
.
.
}
}
|