COSMOS core
1.0.2 (beta)
Comprehensive Open-architecture Solution for Mission Operations Systems
|
Functions | |
const char * | cssl_geterrormsg () |
int32_t | cssl_geterror () |
int32_t | cssl_start () |
int32_t | cssl_stop () |
cssl_t * | cssl_open (const char *fname, int baud, int bits, int parity, int stop) |
int32_t | cssl_close (cssl_t *serial) |
int32_t | cssl_setup (cssl_t *serial, int baud, int bits, int parity, int stop) |
int32_t | cssl_setflowcontrol (cssl_t *serial, int rtscts, int xonxoff) |
int32_t | cssl_settimeout (cssl_t *serial, int, double timeout) |
Set read timeout. More... | |
int32_t | cssl_putchar (cssl_t *serial, uint8_t c) |
int32_t | cssl_putstring (cssl_t *serial, char *str) |
int32_t | cssl_putdata (cssl_t *serial, uint8_t *data, uint32_t datalen) |
int32_t | cssl_putslip (cssl_t *serial, uint8_t *buf, size_t size) |
int32_t | cssl_putnmea (cssl_t *serial, uint8_t *buf, size_t size) |
int32_t | cssl_drain (cssl_t *serial) |
int32_t | cssl_getchar (cssl_t *serial) |
int32_t | cssl_getdata (cssl_t *serial, uint8_t *buffer, int size) |
int32_t | cssl_getxmodem (cssl_t *serial, uint8_t *buf) |
Read Xmodem frame. More... | |
int32_t | cssl_getslip (cssl_t *serial, uint8_t *buf, uint16_t size) |
Read SLIP frame. More... | |
int32_t | cssl_getnmea (cssl_t *serial, uint8_t *buf, uint16_t size) |
Read NMEA response. More... | |
const char * cssl_geterrormsg | ( | ) |
int32_t cssl_geterror | ( | ) |
int32_t cssl_start | ( | ) |
int32_t cssl_stop | ( | ) |
int32_t cssl_close | ( | cssl_t * | serial | ) |
int32_t cssl_setup | ( | cssl_t * | serial, |
int | baud, | ||
int | bits, | ||
int | parity, | ||
int | stop | ||
) |
int32_t cssl_setflowcontrol | ( | cssl_t * | serial, |
int | rtscts, | ||
int | xonxoff | ||
) |
int32_t cssl_settimeout | ( | cssl_t * | serial, |
int | , | ||
double | timeout | ||
) |
Set read timeout.
int32_t cssl_putchar | ( | cssl_t * | serial, |
uint8_t | c | ||
) |
int32_t cssl_putstring | ( | cssl_t * | serial, |
char * | str | ||
) |
int32_t cssl_putdata | ( | cssl_t * | serial, |
uint8_t * | data, | ||
uint32_t | datalen | ||
) |
int32_t cssl_putslip | ( | cssl_t * | serial, |
uint8_t * | buf, | ||
size_t | size | ||
) |
int32_t cssl_putnmea | ( | cssl_t * | serial, |
uint8_t * | buf, | ||
size_t | size | ||
) |
int32_t cssl_drain | ( | cssl_t * | serial | ) |
int32_t cssl_getchar | ( | cssl_t * | serial | ) |
int32_t cssl_getdata | ( | cssl_t * | serial, |
uint8_t * | buffer, | ||
int | size | ||
) |
int32_t cssl_getxmodem | ( | cssl_t * | serial, |
uint8_t * | buf | ||
) |
Read Xmodem frame.
Read one Xmodem block (frame) of data, removing control characters and calculating checksum. Supplied buffer is assumed to be at least 128 bytes.
serial | Handle returned from :cssl_open. |
buf | Byte array to store incoming data. |
int32_t cssl_getslip | ( | cssl_t * | serial, |
uint8_t * | buf, | ||
uint16_t | size | ||
) |
Read SLIP frame.
Read an entire frame of SLIP encoded data from the serial port. Special SLIP characters are removed on the fly. Will stop early if supplied buffer size is exceeded.
serial | Handle returned from :cssl_open. |
buf | Byte array to store incoming data. |
size | Size of byte array. |
int32_t cssl_getnmea | ( | cssl_t * | serial, |
uint8_t * | buf, | ||
uint16_t | size | ||
) |
Read NMEA response.
Read an entire NMEA response from the serial port. The leading $ and trailing * and checksum are removed, and only the payload of the response is returned. Will stop early if supplied buffer size is exceeded.
serial | Handle returned from :cssl_open. |
buf | Byte array to store incoming data. |
size | Size of byte array. |