Main Page | Class Hierarchy | Alphabetical List | Data Structures | Directories | File List | Data Fields | Globals

rcx_comm.h File Reference

Go to the source code of this file.

Defines

#define RCX_OK   0
#define RCX_NO_TOWER   -1
#define RCX_BAD_LINK   -2
#define RCX_BAD_ECHO   -3
#define RCX_NO_RESPONSE   -4
#define RCX_BAD_RESPONSE   -5
#define FILEDESCR   int
#define BADFILE   -1

Functions

FILEDESCR rcx_init (char *tty, int is_fast)
void rcx_close (FILEDESCR fd)
int rcx_wakeup_tower (FILEDESCR fd, int timeout)
int rcx_send (FILEDESCR fd, void *buf, int len, int use_comp)
int rcx_recv (FILEDESCR fd, void *buf, int maxlen, int timeout, int use_comp)
int rcx_sendrecv (FILEDESCR fd, void *send, int slen, void *recv, int rlen, int timeout, int retries, int use_comp)
int rcx_is_alive (FILEDESCR fd, int use_comp)
char * rcx_strerror (int error)
void hexdump (char *prefix, void *buf, int len)


Define Documentation

#define BADFILE   -1
 

Definition at line 40 of file rcx_comm.h.

#define FILEDESCR   int
 

Definition at line 39 of file rcx_comm.h.

#define RCX_BAD_ECHO   -3
 

Definition at line 31 of file rcx_comm.h.

Referenced by rcx_strerror().

#define RCX_BAD_LINK   -2
 

Definition at line 30 of file rcx_comm.h.

Referenced by rcx_strerror().

#define RCX_BAD_RESPONSE   -5
 

Definition at line 33 of file rcx_comm.h.

Referenced by rcx_strerror().

#define RCX_NO_RESPONSE   -4
 

Definition at line 32 of file rcx_comm.h.

Referenced by rcx_strerror().

#define RCX_NO_TOWER   -1
 

Definition at line 29 of file rcx_comm.h.

Referenced by rcx_strerror().

#define RCX_OK   0
 

Definition at line 28 of file rcx_comm.h.

Referenced by rcx_strerror().


Function Documentation

void hexdump char *  prefix,
void *  buf,
int  len
 

Definition at line 402 of file rcx_comm.c.

References GROUP_SIZE.

Referenced by rcx_recv(), rcx_send(), and rcx_wakeup_tower().

void rcx_close FILEDESCR  fd  ) 
 

Definition at line 346 of file rcx_comm.c.

Referenced by main().

FILEDESCR rcx_init char *  tty,
int  is_fast
 

Definition at line 266 of file rcx_comm.c.

References B2400, B4800, exit(), FILEDESCR, memset(), myperror(), NULL, and tty_usb.

Referenced by main().

int rcx_is_alive FILEDESCR  fd,
int  use_comp
 

Definition at line 621 of file rcx_comm.c.

References rcx_sendrecv().

Referenced by main().

int rcx_recv FILEDESCR  fd,
void *  buf,
int  maxlen,
int  timeout,
int  use_comp
 

Definition at line 492 of file rcx_comm.c.

References BUFFERSIZE, hexdump(), and nbread().

Referenced by rcx_sendrecv().

int rcx_send FILEDESCR  fd,
void *  buf,
int  len,
int  use_comp
 

Definition at line 424 of file rcx_comm.c.

References exit(), hexdump(), myperror(), mywrite(), nbread(), rx_flush(), and tty_usb.

Referenced by rcx_sendrecv().

int rcx_sendrecv FILEDESCR  fd,
void *  send,
int  slen,
void *  recv,
int  rlen,
int  timeout,
int  retries,
int  use_comp
 

Definition at line 592 of file rcx_comm.c.

References rcx_recv(), rcx_send(), and rcx_strerror().

Referenced by image_dl(), and rcx_is_alive().

char* rcx_strerror int  error  ) 
 

Definition at line 629 of file rcx_comm.c.

References RCX_BAD_ECHO, RCX_BAD_LINK, RCX_BAD_RESPONSE, RCX_NO_RESPONSE, RCX_NO_TOWER, and RCX_OK.

Referenced by main(), and rcx_sendrecv().

int rcx_wakeup_tower FILEDESCR  fd,
int  timeout
 

Definition at line 355 of file rcx_comm.c.

References BUFFERSIZE, exit(), hexdump(), myperror(), mywrite(), nbread(), rx_flush(), timer_read(), timer_reset(), and timeval_t.

Referenced by main().


Generated on Fri Feb 25 08:02:48 2005 for brickos by  doxygen 1.3.9.1