Skip to content
 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 

Repository files navigation

readtty

A small utility for reading from a tty (or any device file, or any file for that matter), until a specified pattern is matched. The stream is echoed on STDOUT. I use it to read plots from a Tektronix 2211 oscilloscope, which emits plot commands in HP-GL format on a RS232 port:

function osc {
    rm -f $1.hpgl
    readtty /dev/tty.usbserial ";DF;" | pv > $1.hpgl
    rm -f $1.eps
    cat $1.hpgl | hp2xx -q -f- -m eps -a 2 > $1.eps
}

# Usage
osc plot
# Gives plot.eps file in current directory

./wave.png

The conversion from HP-GL to EPS is done using hp2xx, a Homebrew formula for which exists at jagot/hp2xx.

About

No description, website, or topics provided.

Resources

Code of conduct

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages