sct
所属分类:串口编程
开发工具:Unix_Linux
文件大小:21KB
下载次数:8
上传日期:2007-11-13 09:02:02
上 传 者:
billwfox
说明: 做嵌入式的串口设置时,可以直接把sct解压了,然后直接make。
测试串口是否可以工作正常,很好的代码。
(So embedded serial port settings, you can extract directly to the sct and then directly make. Test serial port can work in normal, good code.)
文件列表:
sct\cmd.c (6605, 2006-10-24)
sct\cmd.h (1986, 2006-10-24)
sct\main.c (6454, 2006-10-24)
sct\Makefile (1241, 2006-10-24)
sct\mk_linux (1099, 2006-10-24)
sct\mk_sco (1068, 2006-10-24)
sct\sct.c (21217, 2006-10-24)
sct\sct.h (2762, 2006-10-24)
sct\stdhdr.h (1625, 2006-10-24)
sct\tio.c (4950, 2006-10-24)
sct\tio.h (2156, 2006-10-24)
sct\util.c (3391, 2006-10-24)
sct\util.h (2289, 2006-10-24)
sct\ver.h (1511, 2006-10-24)
sct (0, 2007-06-14)
README
SCT is a usefull gnu tools to debug and trace serial port communication
Here are the documents help you to install and use uct
I How to make and install sct
1 For linux platform
cp mk_linux Makefile
make
make install
2 For Sco-Unix platform
cp mk_sco Makefile
make
make install
II Quick guide to commands' of sct
At the time you run the sct,you may input the command
by the right at the prompt "=>". you may input "help"+command_name
for more detail.
1 "?"
to get command list
2 "help"
for detailed help for the command
usage: help command_name
eg: help sel
get help of sel command
3 "stat"
dsplay current port status
usage: stat
4 "sel" or "port"
select a serial device as current port
usage: sel device
eg: sel /dev/ttyS0
5 "frame"
set frameset
usage: frame rate,parity,databits,stopbits
eg: frame 9600,n,8,1
6 "handshake" or "hs"
set handshake for port communication
usage: handshake [+/-] prototol
eg: handshake +rts
enable rts control
eg: handshake -xonxoff
disable xonxoff control
eg: handshake none
disable all hardware and fllow control
7 "open"
open current port and active it
usage: open
8 "close"
close current port and stop action
usage: close
9 "term"
enter terminal mode
usage: term
10 "echo"
enter echo mode, reply all byte when received
usage: echo
11 "setbuf"
set buffer data,10 buffers can use inall
usage: setbuf buffer_no input_form
eg: setbuf 1 asc
set data of buf1 as ascii char
eg: setbuf 2 hex
set data of buf2 hex code
12 "dispbuf"
display buffers' info or buffer's data
usage: dispbuf [buffer_no]
eg: dispbuf
get infomation ablout all buffers
eg: dispbuf 3
display data of buffer 3 by both ascii and hex form
13 "clrbuf",
clear the buffer
usage: clrbuf buffer_no|all
eg: clrbuf 3
clear buffer 3
eg: clrbuf all
clear all buffers
14 "loadbuf"
load data to buffer from file
usage: loadbuf buffer_no filepath
eg: loadbuf 3 commu.dat
load data to buffer 3 from file commu.dat
15 "savebuf"
save data to file from buffer
usage: savebuf filepath buffer_no
eg: savebuf commu.dat 3
save data to file commu.dat from buffer 3
16 "copybuf"
copy buffer from one to another
usage: copybuf dest_buffer_no src_buffer_no
eg: copybuf 3 4
copy buffer 3 to buffer 4
17 "recv"
recv data to buffer,10 buffers can use inall
usage: recv bufffer_no
eg: recv 4
recv data to buffer 4
18 "send"
send buffer data,10 buffers can use inall
usage: send buffer_no
eg: send 1
send data from buffer 1
19 "sendrecv"
send the data from one buf and after that recv the data to another or same buf
usage: sendrecv send_buffer_no recv_buffer_no
eg: sendrecv 1 2
send data from buffer 1 and after that recv data to buffer 2
eg: sendrecv 1 1
send data from buffer 1 and after that recover it with recved data
近期下载者:
相关文件:
收藏者: