Skip to content

Index of Module serial

Matthias Görges edited this page May 20, 2015 · 12 revisions

Module: serial

Module serial provides cross platform rs232 (serial) bindings. This implementation assumes that the communication flow control is completely controlled by the external device, which is the case with most instruments.

Note: Android USB requires the usb-serial-for-android library to be included in the applications LIBRARIES file. It uses https://code.google.com/p/usb-serial-for-android/.

Functions in this module:

Function Short Description
(detect-usb-serial) Return usb-serial converter name on unix-like OS
(serial-close dev) Close the RS232 serial port
(serial-readchar dev) Reads character from RS232 device
(serial-writechar dev char) Write a character to RS232 device
(serial-flush dev) Flush RS232 device communication port
(serial-error) (For Android) Returns if a serial error has occurred
(serial-timeout) (For Android) Returns if a serial timeout has occurred
(serial-try devname baudrate databits parity stopbits testproc) Attempt to open the serial port with given settings
(serial-tryfile filepath) Attempt to open the serial port with a file
(serial-autodetect devname testproc) Attempt at auto detecting RS232 device
(serial-cache-setup dev char1 char2) RS232 serial cache, which buffers data patterns starting with char1 and ending with char2
(serial-cache-clear dev) Clear RS232 device serial port cache
(serial-cache-read dev . hook) Read data from RS232 serial cache
Clone this wiki locally