User`s guide
See the supplied Neuron C program
DIALOUT. NC
for an example of an application
that sends a message to an SLTA-10 Adapter to cause it to dial-out using an attached
modem. The example
GIZSETUP
.
NC
sends messages to an SLTA-10 Adapter to
configure its modem strings using a Gizmo I/O module as the user interface. A node
can send these messages using either implicit or explicit addressing. When implicit
addressing is used, a network management tool binds the output message tag in the
node wishing to send the message to the SLTA-10 Adapter as the destination. When
explicit addressing is used, the node wishing to send the message must explicitly
insert the destination address in the outgoing message.
Note that the SLTA-10 Adapter will be unable to receive any messages, including
these network management messages, if network communications is disabled, i.e., it
is in the
FLUSH
state.
This will normally be the case if it is not connected to a host.
Therefore, in order to be able to dial-out and connect to a host, the SLTA-10 Adapter
must be configured to initialize with network communications enabled, i.e., the
NORMAL
state, with the CFGl input. See Chapter 4 for more details.
The messages should be sent with request/response service, and the response code
should be checked to see if the message was executed correctly - it will be Ox3D if
there was no error, and OxlD if there was. Possible failure conditions are noted
under each message.
Some of these network management messages return data to
the sender in the response structure as noted below.
Note that some of these messages cause one or more bytes of EEPROM in the
SLTA-10 Adapter to be written.
Each byte of EEPROM takes 20ms to write, and the
response is not sent by the SLTA-10 Adapter until after the command is executed.
This time should be taken into account when setting the transaction timer
(tx-timer)
in the message tag connection for implicit addressing, or in the
destination address for explicit addressing. If the LonBuilder or LonManager API
binder is used to create the connection, the transaction timer may be explicitly
specified.
Example:
msg.-tag SLTA-tag;
when ( . . . ) {
msg-out.code = Ox7D;
// network mgmt msg code
msg-out.tag = SLTA-tag;
msg-out.service = REQUEST;
msg-out.data[O] = 1;
// sub-code for SLTA-10
msg-out.data[ll = app-command;
// specific command
msg-out.data[2] = . . . . .
// additional parameters
msg-send();
SLTA-10 Adapter User’s Guide
11-7