background image

Operation Manual

Summary of Contents for Pilot ONE

Page 1: ...Operation Manual ...

Page 2: ......

Page 3: ...3 OPERATION MANUAL pySoftcheck pySoftcheck 01 20171002 2 Liability for errors and misprints excluded pySoftcheck ...

Page 4: ...4 OPERATION MANUAL pySoftcheck Liability for errors and misprints excluded pySoftcheck 01 20171002 2 ...

Page 5: ...n 9 3 1 11 set_timeout 9 3 1 12 close 10 4 Examples 11 4 1 Example 1 11 4 1 1 Program 11 4 1 2 Program description 11 5 API 13 5 1 Com Object working with generic Command strings 13 5 2 PB Object PB Commands 14 5 3 PpCom Object PP Commands 15 5 4 LaiCom Object LAI Commands 16 5 5 MbCom object Modbus commands 18 5 5 1 MbTCPCommand object 18 5 5 2 MbFunc object 19 5 6 ComStore Object storing informa...

Page 6: ...nstallation of Huber Runtime is complete To do so please run the appropriate installer 1 2 Linux Please contact us 2 Application pySoftcheck is an application that permits remote control of the Huber thermostats via an interface The presented module pySoftcheck is written in Python The end user therefore can use the entire Python environment for developing custom scripts Another advantage of Pytho...

Page 7: ... re commended PB instruction set However if the Com object is used with modbustcp as interface bytearrays have to be used Examples com Com ethernet 2 5 generates a Com object for Ethernet with a timeout of 2 5 s send The send message command sends the string contained in message to the selected interface Example com send M00 r n queries the current setpoint send_bytes The send_bytes message comman...

Page 8: ...s The square bracket must be preceded by a backslash as it otherwise is considered part of the regu lar expression and is not sent via the interface The itself is not sent needs to be escaped with Examples com check_regex r TI 0 9 checks if the first two characters received are TI compliant fol lowed by a space and then a number from 0 9 As the two are part of the regular expression they must not ...

Page 9: ...ameter IP address to be used to address the device The second parameter is the Ethernet port ModbusTCP First parameter IP address to be used to address the device The second parameter is the Ethernet port Serial interface First parameter Port used for communication The serial interface permits the fol lowing options Under Windows the current Com Port 1 That is 0 for COM1 1 for COM2 Under Linux the...

Page 10: ...eout 1 Sets a timeout of 1 second close close closes the interface used for communication and releases it to the system Examples com close The interface is closed and made available to the system again pySoftcheck Liability for errors and misprints excluded pySoftcheck 01 20171002 2 ...

Page 11: ...2 print Ask for the internal temperature and check the first four chars 23 print Output is only generated in case of an error 24 com send M01 r n 25 com check S01 26 27 print 28 print Ask for the internal temperature and check the answer with a regex 29 print Output is only generated in case of an error 30 com send M01 r n 31 com check_regex r S01 0 9a fA F 32 33 print 34 print Ask for the interna...

Page 12: ...s example after 2 3 seconds 17 24 30 35 Sends a string via the interface This example queries the internal temperature 18 Displays the response received from the interface at the console 25 Reads a message from the interface and checks whether it matches S01 31 Reads a message from the interface and checks whether it matches the transferred regular ex pression 36 38 Receives a string from the inte...

Page 13: ... ttyACM0 9600 open ACM driver send Sends a command to the interface CR and LF have to be noted also Example send TI r n send_bytes for ModbusTCP usage Sends a bytearray to the interface Example send_bytes bytearray 0x00 0x00 0x00 0x00 0x00 0x02 0xFF 0x41 check checks the start of the message received from the interface Example check TI Example2 check S01G check_bytes for ModbusTCP usage checks if ...

Page 14: ...rred since the initialization of the Com object Example nr_timeouts com get_nr_timeouts get_std_deviation Returns the standard deviation from the runtime Example std_dev com get_std_deviation 5 2 PB Object PB Commands Namespace from softcheck pb_commands import PbCom To construct a new PbCom class which is used for communication with PB commands with the device the following arguments are needed E...

Page 15: ...rn value is the value of the bit position that has been set set_bit 10 12 clear_bit clears a bit to 0 on a given bit position and sends the command First argument is the command number the second one is the bit position Return value is the value of the bit position clear_bit 10 12 more complete Example from softcheck logic import Com from softcheck logic import CommunicationTimeout from softcheck ...

Page 16: ... 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 ...

Page 17: ...ecks if the value of a LAI command is like expected The first argument is the command to check the second the regular expression of the LAI command expected Return value True if check is o k lai send G C0 O off 0 no Alarm tttt setpoint iiii internal temp dddd external temp lai check_regex r O0 0 9A F 4 0 9A F 4 0 9A F 4 check_hex checks if the hex value string of a lai command is like expected The...

Page 18: ...ai check_regex r OC 0 0 9A F 4 0 9A F 4 0 9A F 4 com close 5 5 MbCom object Modbus commands Namespace from softcheck mb_commands import MbCom To construct a new MbCom class which is used for communication with Modbus commands with the device the following arguments are needed The 1st parameter must be a configured Com object As 2nd parameter the protocol mode can be given Only tcp is supported As ...

Page 19: ...bytes can be specified As 4th parameter the protocol identifier 2 bytes can be specified ModbusTCP needs 0x0000 for protocol identifier Example mb_command MbTCPCommand bytearray 0x41 0xFF MbFunc object Namespace from softcheck mb_commands import MbFunc Class contains static methods specially for the huber defined modbus functions 5 6 ComStore Object storing information from a device in a file Name...

Page 20: ...20 OPERATION MANUAL pySoftcheck Liability for errors and misprints excluded pySoftcheck 01 20151106 0 ...

Reviews: