File: command

package info (click to toggle)
comgt 0.32-6
  • links: PTS, VCS
  • area: main
  • in suites: sid, trixie
  • size: 384 kB
  • sloc: ansic: 2,117; makefile: 44; sh: 26
file content (32 lines) | stat: -rw-r--r-- 662 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
####################################################
#
# command - comgt script for command interaction
#
# Copyright (C) 2006  Paul Hardwick <paul@peck.org>
#
###################################################
print "\nType command at prompt.\n"
print "Empty input terminates.\n"
print "#################\n"
opengt
set com 115200n81
set senddelay 0.05
waitquiet 1 0.2

:loop1
    print "Command: "
    input $x
    let c=len($x)
    if c=1 goto end
    let c=c-1
    let $c=$left($x,c)
    send $c
    send "^m"
    :loop2
        print $a
        get 1 "^m" $a
        let a=len($a)
        if a > 0 goto loop2
    goto loop1
:end
print "#################\n"