16
OPERATION MANUAL
As 2nd parameter the verbosity level can be given. "1" means that the program ex-
plains what goes wrong in case of an error.
3rd parameter: When set to True (default), the program throws an exception in case of
an error, otherwise the program goes on.
check:
checks if the value of a pp command is like expected
The first argument is the command to check, the second the value of the PP command
expected.
Return value True if check is o.k.
pp.check("SP", 2000)
check_range:
checks if the value of the pb command is within the range expected
The first argument the command to check, the second the minimum and the third the
maximum value.
Return value True if check is o.k.
pp.check_range("TI", 1000, 1500)
send:
sends a pp command with a certain value
The first argument is the PP command to send, the second one the value.
pp.send("SP", 1500)
change_to:
changes the command given to the value given (sends the value to the Circulator and
checks the answer for correctness)
The first argument is the command string and the second the value to be set.
pp.change_to("SP", 2000):
request:
Requests the value of a command. The function only sends a request to the remote.
As argument the command string must be given.
pp.request("TI")
request_echo:
sends a request command and waits for the answer from the remote.
As argument the command string must be given.
pp.request_echo("TI")
more complete Example:
----------------------
from softcheck.logic import Com
from softcheck.logic import CommunicationTimeout
from softcheck.pp_commands import PpCom
com = Com("serial", 2.1, 3)
com.open(0, 9600) #open COM1 with 9600 (address not defined)
pp = PpCom(com)
internal_temp = pp.request_echo("TI")
pp.request("TI")
pp.check_range("TI", 500, 6000)
pp.request("TE")
pp.check_range("TE", 0, 7000)
pp.change_to("CA", 1)
time.sleep(30)
com.close()
5.4 LaiCom Object (LAI Commands)
Namespace: from softcheck.lai_commands import LaiCom
To construct a new LaiCom class - which is used for communication with Lai commands
with the device - the following arguments are needed:
Example: lai = LaiCom(com, 1)
Example2: lai = LaiCom(com, 1, 1)
The 1st parameter must be a configured Com object.
The 2nd parameter is the slave address that the Circulator uses.
pySoftcheck
Liability for errors and misprints excluded.
pySoftcheck.01.20171002.2
Summary of Contents for Pilot ONE
Page 1: ...Operation Manual ...
Page 2: ......