Please enable JavaScript to view this site.

ESL Documentation

Action Statement

Start communications with an application.

start { local LOCAL_APP_NAME PROGRAM_NAME [-m INPUT_BUFFER_SIZE][PARAMETERS]

| remote REMOTE_APP_NAME {PORT|HOST NAME} [CHARACTERISTICS] }

local LOCAL_APP_NAME

Start a local application and communications with that program. To identify the program (LOCAL_APP_NAME), specify the same name provided in the application declaration that defined the application program.

PROGRAM_NAME

A string value identifying the name of the local application program as it is recognized by the operating system.

INPUT_BUFFER_SIZE

A numeric value for the size of the input buffer, in bytes.

PARAMETERS

A string value containing one or more parameters that you want to pass to the local application program.

remote REMOTE_APP_NAME

Start communications with a remote application. The remote application must already be running before communications can be started. Identify the program (REMOTE_APP_NAME) by specifying the same name provided in the application declaration that defined the application program.

PORT

If the remote library within the configuration is specified as "SERIAL" then one of the following string values representing the communications port you want to use for communication with the remote application program.

"com1" "com5"

"com2" "com6"

"com3" "com7"

"com4" "com8"

Note that you cannot use parallel ports.

HOST NAME

If the remote library within the configuration is specified as "SOCKET" then a string values representing IP address or Host Name for the server your application needs as a communication partner. For example:

"www.myserver.com"

 

CHARACTERISTICS

A string value containing options for the remote terminal characteristics, when using the serial library or the port and protocol for the socket library. If more than one characteristic is required, create a string that has a space between each characteristic. The characteristics can appear in any order within the string.

If you do not include a CHARACTERISTICS entry for a remote application, ESL uses the following defaults (as defined in EslConfig.ini):

"tandem nopar databits 8 stopbits 1 1200"

You can specify any of the following baud rates:

 

110 600 4800

150 1200 (default) 9600

300 2400 19200

Characteristics for use with ESL

Characteristic

Tells ESL to:

tandem

Send and obey flow control. (Default.)

-tandem

Not send or obey flow control.

nopar

Not receive or transmit parity. (Default.)

evenpar

Generate even parity.

oddpar

Generate odd parity.

markpar

Generate mark parity (parity bit = 1).

spacepar

Generate space parity (parity bit = 0).

databits 7

Generate 7 bits per character. (Default if parity is anything except nopar.)

databits 8

Generate 8 bits per character. (Default if parity is nopar.)

stopbits 1

Generate one stop bit per character. (Default.)

stopbits 2

Generate two stop bits per character.

xonchar CTL_CHAR

Set the control character used for XON flow control. (Default is \^Q.)

xoffchar CTL_CHAR

Set the control character used for XOFF flow control. (Default is \^S.)

port nnnn

Where nnnn is the port on the host computer (Default 23 - Telenet)

protocol nnnn

Where nnnn is the protocol to be used (Default 6 - TCP)

Description

Use this statement to execute a local application and start communications with that application, or to start communications with a remote application.

You must specify a start action statement for all application programs before ESL can communicate with these programs.

All applications are global. In one ESL program, you might define an application and start it running. In the other programs to which control is transferred, you simply define the application, not restart it. The application continues to run without interruption as control is transferred between programs; the final ESL program to use the application may stop it.

You can determine the success or failure of a start action statement by testing the value of the errorlevel function. A zero value indicates success; any non-zero value indicates failure.

All local applications (for example any database local) have default input buffer size of 4096 bytes. It effectively means that ESL application can not send more than 4096 bytes to a local in one block (for example an ESL application can not issue an SQL query longer than 4096 bytes). To overcome the situation locals input buffer size can be increased by adding the "-m" flag to the command line, followed by the required buffer size, specified in bytes. If specified, the input buffer size must be preceded by the "-m" flag plus a space, and there must be a space between this option parameter, and the other parameters. The input buffer size parameter is not passed onto the local application.

Example

 

response to start

 start local Prog "DBN52" "1x9"

 

response to StartKey

 start remote R "myserver.com" "port 80"

See Also

application Environment Declaration

stop Action Statement