Models 707B and 708B Switching Matrix Reference Manual
tspnet.termination()
This function sets the device line termination sequence.
Type
TSP-Link accessible
Function
Yes
Usage
type = tspnet.termination(connectionID)
type = tspnet.termination(connectionID, termSequence)
type
connectionID
termSequence
Details
This function sets and gets the termination character sequence that is used to indicate the end of a line for a
TSP-Net connection.
Using the termSequence parameter sets the termination sequence. The present termination sequence is
always returned.
There are four possible combinations, all of which are made up of line feeds (LF or 0x10) and carriage returns
(CR or 0x13). For TSP-enabled devices, the default is tspnet.TERM_LF. For devices that are not TSP-enabled,
the default is tspnet.TERM_CRLF.
The termination sequence resets to the default value when the connection is terminated.
Example
myID = tspnet.connect("192.0.2.1")
if myID then
tspnet.termination(myID, tspnet.TERM_LF)
tspnet.disconnect(myID)
end
Also see
tspnet.connect()
tspnet.disconnect()
707B-901-01 Rev. A / August 2010
Affected by
An enumerated value indicating the termination type:
•
tspnet.TERM_LF
•
tspnet.TERM_CR
•
tspnet.TERM_CRLF
•
tspnet.TERM_LFCR
The connection ID returned from tspnet.connect()
The termination sequence
(on page 7-229)
(on page 7-230)
Where saved
Default value
Section 7: Command reference
7-235