simpletext library
v0.98
Compact variations of put/get write/read and print/scan for smaller program sizes
|
#include "simpletext.h"
Go to the source code of this file.
Data Structures | |
struct | serial_info |
Macros | |
#define | SERIAL_MIN_PIN 0 |
Min serial pin value. | |
#define | SERIAL_MAX_PIN 31 |
Max serial pin value. |
Typedefs | |
typedef struct serial_info | Serial_t |
typedef text_t | serial |
Makes declarations like serial lcd to stand in for text_t lcd. Spelling is choice of Parallax education, not the author. |
Functions | |
serial * | serial_open (int rxpin, int txpin, int mode, int baudrate) |
Open a simple serial connection. | |
void | serial_close (serial *device) |
Close serial connection. | |
int | serial_rxChar (serial *device) |
Receive a byte. Waits until next byte is received. | |
int | serial_txChar (serial *device, int txbyte) |
Send a byte. |
Defines serial module - provides low level half duplex serial functions. See simpletext.h for higher level functions.
Copyright (c) 2013, Parallax Inc., MIT Licence. Written by Steve Denson Symbol naming decided by Parallax
void serial_close | ( | serial * | device | ) |
Close serial connection.
device | A previously opened serial connection. |
serial* serial_open | ( | int | rxpin, |
int | txpin, | ||
int | mode, | ||
int | baudrate | ||
) |
Open a simple serial connection.
rxpin | Serial input pin, receives serial data. |
txpin | Serial output pin, transmits serial data. |
mode | Unused mode field (for FdSerial compatibility) |
baudrate | Bit value transmit rate, 9600, 115200, etc... |
int serial_rxChar | ( | serial * | device | ) |
Receive a byte. Waits until next byte is received.
device | ID returned by serial_open. |
int serial_txChar | ( | serial * | device, |
int | txbyte | ||
) |
Send a byte.
device | is a previously open/started terminal device. |
device | ID returned by serial_open. |