
13-1
Section 13. PakBus Communication
Instructions
This set of instructions is used to communicate with other PakBus devices. In
general they specify a COM port and a PakBus address. If the route to the
device is not yet known, it will try a direct route through the COM port. If the
route is through a neighbor that must first be dialed, then it will first try to dial
using the user specified DialSequence.
The PakBus Address parameter is a variable, so it can be used in a For loop, for
example.
The ComPort parameter is restricted to the following predefined constants:
1 ComRS232
2 ComME
3 Com310
4 ComSDC7
5 ComSDC8
6 Com1 (C1,C2)
7 Com2 (C3,C4)
8 Com3 (C5,C6)
9 Com4 (C7,C8)
This parameter sets a default com port in the case that the route to the remote
node is not yet known.
The Baud Rate on asynchronous ports will default to 9600 baud unless set
otherwise by a SerialOpen() function defined in 5.1 or if the port is opened by
an incoming packet at some other baudrate.
The Baud Rate parameter on the asynchronous ports (ComRS232, ComME,
Com1, Com2, Com3,and Com4) is restricted to
300,1200,4800,9600,19200,38400,57600,115200, with a default of 9600. (The
bit rate on the synchronous ports is to be determined.)
The instructions in general include a ResultCode variable indicating if it was
successful or not. The ResultCode will be set to 0 if successful. If
communication fails, it will increment. If the communication succeeds but
there is some error indicated the response code, then the ResultCode is set to
the negative of the response code. The possible non-zero response codes
(negated) are:
1 Read Only or Permission denied
2 Out of Space in the remote
3 Syntax Error
16 Invalid Table Name or Field Name
17 Data type conversion not supported
18 Memory bounds violation
19
20 Out of memory in the host
21 Cannot route to remote (communication no attempted)
Comentarios a estos manuales