File: initmodem.tcl

package info (click to toggle)
vbox3 0.1.9.3
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k, sarge
  • size: 660 kB
  • ctags: 274
  • sloc: ansic: 3,454; sh: 1,831; makefile: 120; tcl: 22
file content (25 lines) | stat: -rw-r--r-- 1,237 bytes parent folder | download | duplicates (3)
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
# $Id: initmodem.tcl,v 1.7 2001/01/14 13:50:21 pape Exp $
#----------------------------------------------------------------------#
# This script is called every time the modem should be initialized. If #
# the script produce errors (syntax error or the command "error"), the #
# main program interprets the current operation as failed.             #
#                                                                      #
# The following global variables can be used in this script:           #
#                                                                      #
# vbxv_init       - Modem init command (configuration)                 #
# vbxv_initnumber - Modem number init command (configuration)          #
#----------------------------------------------------------------------#
# This script runs under root permissions, so doublecheck what you do! #
#----------------------------------------------------------------------#

if { [vbox_modem_command "$vbxv_init" "OK"] > 0 } {
	if { [vbox_modem_command "$vbxv_initnumber" "OK"] > 0 } {
		if { [vbox_modem_command "AT+FCLASS=8" "OK"] > 0 } {
			if { [vbox_modem_command "ATS13.2=1S13.4=1S13.6=0S13.7=1S23.0=1" "OK"] > 0 } {
				return
			}
		}
	}
}

error "modem returns error"