amtec_io.c File Reference

#include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include <termios.h>
#include <unistd.h>
#include <fcntl.h>
#include <errno.h>
#include <string.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <sys/ioctl.h>
#include <sys/time.h>
#include <linux/serial.h>
#include "amtec_io.h"
Include dependency graph for amtec_io.c:

Go to the source code of this file.

Functions

int amtecDeviceConnectPort (amtec_powercube_device_p dev)
void amtecDeviceSetBaudrate (amtec_powercube_device_p dev, int brate)
void amtecDeviceSetParams (amtec_powercube_device_p dev)
int amtecGetAnswer (amtec_powercube_device_p dev, unsigned char *cmd, int *len)
int amtecSendCommand (amtec_powercube_device_p dev, int id, unsigned char *cmd, int len)
long bytesWaiting (int sd)
int cBaudrate (int baudrate)
int cDataSize (int numbits)
int cFlowControl (int flowcontrol)
void convertBuffer (unsigned char *cmd, int *len)
int cParity (enum PARITY_TYPE par)
int cStopSize (int numbits)
int iParity (enum PARITY_TYPE par)
int iSoftControl (int flowcontrol)
int waitForAnswer (int fd, unsigned char *buf, int *len)
int waitForETX (int fd, unsigned char *buf, int *len)
int writeData (int fd, unsigned char *buf, int nChars)

Function Documentation

int amtecDeviceConnectPort ( amtec_powercube_device_p  dev  ) 

Definition at line 211 of file amtec_io.c.

void amtecDeviceSetBaudrate ( amtec_powercube_device_p  dev,
int  brate 
)

Definition at line 198 of file amtec_io.c.

void amtecDeviceSetParams ( amtec_powercube_device_p  dev  ) 

Definition at line 175 of file amtec_io.c.

int amtecGetAnswer ( amtec_powercube_device_p  dev,
unsigned char *  cmd,
int *  len 
)

Definition at line 421 of file amtec_io.c.

int amtecSendCommand ( amtec_powercube_device_p  dev,
int  id,
unsigned char *  cmd,
int  len 
)

Definition at line 304 of file amtec_io.c.

long bytesWaiting ( int  sd  ) 

Definition at line 166 of file amtec_io.c.

int cBaudrate ( int  baudrate  ) 

Definition at line 118 of file amtec_io.c.

int cDataSize ( int  numbits  ) 

Definition at line 70 of file amtec_io.c.

int cFlowControl ( int  flowcontrol  ) 

Definition at line 99 of file amtec_io.c.

void convertBuffer ( unsigned char *  cmd,
int *  len 
)

Definition at line 392 of file amtec_io.c.

int cParity ( enum PARITY_TYPE  par  ) 

Definition at line 107 of file amtec_io.c.

int cStopSize ( int  numbits  ) 

Definition at line 91 of file amtec_io.c.

int iParity ( enum PARITY_TYPE  par  ) 

Definition at line 54 of file amtec_io.c.

int iSoftControl ( int  flowcontrol  ) 

Definition at line 62 of file amtec_io.c.

int waitForAnswer ( int  fd,
unsigned char *  buf,
int *  len 
)

Definition at line 261 of file amtec_io.c.

int waitForETX ( int  fd,
unsigned char *  buf,
int *  len 
)

Definition at line 225 of file amtec_io.c.

int writeData ( int  fd,
unsigned char *  buf,
int  nChars 
)

Definition at line 288 of file amtec_io.c.

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Defines


amtec
Author(s): Charles DuHadway and Benjamin Pitzer
autogenerated on Fri Jan 11 09:37:48 2013