Berkeley Nuclear Data Software
Macros | Functions | Variables
rs232.c File Reference
#include "rs232.h"
Include dependency graph for rs232.c:

Macros

#define RS232_PORTNR   32
 

Functions

int RS232_OpenComport (int comport_number, int baudrate, const char *mode, int flowctrl)
 
int RS232_PollComport (int comport_number, unsigned char *buf, int size)
 
int RS232_SendByte (int comport_number, unsigned char byte)
 
int RS232_SendBuf (int comport_number, unsigned char *buf, int size)
 
void RS232_CloseComport (int comport_number)
 
int RS232_IsDCDEnabled (int comport_number)
 
int RS232_IsRINGEnabled (int comport_number)
 
int RS232_IsCTSEnabled (int comport_number)
 
int RS232_IsDSREnabled (int comport_number)
 
void RS232_enableDTR (int comport_number)
 
void RS232_disableDTR (int comport_number)
 
void RS232_enableRTS (int comport_number)
 
void RS232_disableRTS (int comport_number)
 
void RS232_flushRX (int comport_number)
 
void RS232_flushTX (int comport_number)
 
void RS232_flushRXTX (int comport_number)
 
void RS232_cputs (int comport_number, const char *text)
 
int RS232_GetPortnr (const char *devname)
 

Variables

HANDLE Cport [RS232_PORTNR]
 
const char * comports [RS232_PORTNR]
 
char mode_str [128]
 

Macro Definition Documentation

◆ RS232_PORTNR

#define RS232_PORTNR   32

Function Documentation

◆ RS232_CloseComport()

void RS232_CloseComport ( int  comport_number)
Here is the caller graph for this function:

◆ RS232_cputs()

void RS232_cputs ( int  comport_number,
const char *  text 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ RS232_disableDTR()

void RS232_disableDTR ( int  comport_number)

◆ RS232_disableRTS()

void RS232_disableRTS ( int  comport_number)

◆ RS232_enableDTR()

void RS232_enableDTR ( int  comport_number)

◆ RS232_enableRTS()

void RS232_enableRTS ( int  comport_number)

◆ RS232_flushRX()

void RS232_flushRX ( int  comport_number)

◆ RS232_flushRXTX()

void RS232_flushRXTX ( int  comport_number)

◆ RS232_flushTX()

void RS232_flushTX ( int  comport_number)

◆ RS232_GetPortnr()

int RS232_GetPortnr ( const char *  devname)

◆ RS232_IsCTSEnabled()

int RS232_IsCTSEnabled ( int  comport_number)

◆ RS232_IsDCDEnabled()

int RS232_IsDCDEnabled ( int  comport_number)

◆ RS232_IsDSREnabled()

int RS232_IsDSREnabled ( int  comport_number)

◆ RS232_IsRINGEnabled()

int RS232_IsRINGEnabled ( int  comport_number)

◆ RS232_OpenComport()

int RS232_OpenComport ( int  comport_number,
int  baudrate,
const char *  mode,
int  flowctrl 
)
Here is the caller graph for this function:

◆ RS232_PollComport()

int RS232_PollComport ( int  comport_number,
unsigned char *  buf,
int  size 
)
Here is the caller graph for this function:

◆ RS232_SendBuf()

int RS232_SendBuf ( int  comport_number,
unsigned char *  buf,
int  size 
)
Here is the caller graph for this function:

◆ RS232_SendByte()

int RS232_SendByte ( int  comport_number,
unsigned char  byte 
)
Here is the caller graph for this function:

Variable Documentation

◆ comports

const char* comports[RS232_PORTNR]
Initial value:
={"\\\\.\\COM1", "\\\\.\\COM2", "\\\\.\\COM3", "\\\\.\\COM4",
"\\\\.\\COM5", "\\\\.\\COM6", "\\\\.\\COM7", "\\\\.\\COM8",
"\\\\.\\COM9", "\\\\.\\COM10", "\\\\.\\COM11", "\\\\.\\COM12",
"\\\\.\\COM13", "\\\\.\\COM14", "\\\\.\\COM15", "\\\\.\\COM16",
"\\\\.\\COM17", "\\\\.\\COM18", "\\\\.\\COM19", "\\\\.\\COM20",
"\\\\.\\COM21", "\\\\.\\COM22", "\\\\.\\COM23", "\\\\.\\COM24",
"\\\\.\\COM25", "\\\\.\\COM26", "\\\\.\\COM27", "\\\\.\\COM28",
"\\\\.\\COM29", "\\\\.\\COM30", "\\\\.\\COM31", "\\\\.\\COM32"}

◆ Cport

HANDLE Cport[RS232_PORTNR]

◆ mode_str

char mode_str[128]