#include <stdio.h>
#include <stdarg.h>
#include <string.h>
#include "rlcutil.h"
#include "rl3964r.h"
Go to the source code of this file.
|
static const char * | statestr [] = {"idle","sending","receiving","want_to_send","want_to_receive"} |
|
- Enumerator:
IDLE |
|
SENDING |
|
RECEIVING |
|
WANT_TO_SEND |
|
WANT_TO_RECEIVE |
|
Definition at line 30 of file rl3964r.cpp.
static void* receiverThread |
( |
void * |
arg | ) |
|
|
static |
Definition at line 41 of file rl3964r.cpp.
{
unsigned char c;
int ret,send_retry;
send_retry = 0;
{
c = 0x0ff;
{
}
{
d->
dprintf(
"receiverThread: STX WANT_TO_SEND lowPriority\n");
}
{
d->
dprintf(
"receiverThread: STX WANT_TO_SEND highPriority\n");
}
{
d->
dprintf(
"receiverThread: DLE WANT_TO_SEND\n");
}
{
d->
dprintf(
"receiverThread: NAK\n");
}
{
if(send_retry < 1)
{
}
else if(send_retry < 3)
{
send_retry++;
d->
dprintf(
"receiverThread: WANT_TO_SEND send=STX retry=%d\n",send_retry+1);
}
else
{
send_retry = 0;
d->
dprintf(
"receiverThread: WANT_TO_SEND failed after 3 retries\n");
}
}
else
{
d->
dprintf(
"receiverThread: IDLE\n");
}
}
return NULL;
}
const char* statestr[] = {"idle","sending","receiving","want_to_send","want_to_receive"} |
|
static |