User guide

Neuron C Programmer’s Guide 49
network input SNVT_temp nviTemp;
network output SNVT_switch nvoHeater;
network output int nvoCurrentTemp;
Examples of priority network variable declarations are shown below:
network output SNVT_alarm bind_info(priority)
nvoFireAlarm;
network input boolean bind_info (priority(nonconfig))
nviFireAlarm;
An example of declaring a network variable using the unacknowledged service is
the following:
network output SNVT_lev_cont bind_info(unackd)
nvoFillLevel;
The unacknowledged service can be used for this network variable because we
can assume that the control dial generates numerous messages as it is being
turned, and you probably don’t need or want to receive an acknowledgment for
each one. In addition, it is probably not critical to this application if a single
message out of several is not received.
Connecting Network Variables
Network variable
connections
are independent of the Neuron C application on a
device. Network variable connections are created by a portion of a network tool
called the
binder
. The binder can be part of the LonMaker Integration Tool or
another network tool.
The binder assigns addresses and transport properties, such as timer values, to
all appropriate devices to ensure that information flows to and from the right
places.
Example: Binding output network variables to input network variables creates a
“closed-loop system”, also sometimes called a “servo system”. By connecting the
network variables of two or more devices, you allow the system to use feedback or
error-correction signals from one device to set or maintain the control mechanical
position or other parameters of the other device.
Figure 7 on page 50 shows a
simple closed-loop system for a stairwell lighting system.
In the figure, the dashed line represents the “forward” connection that drives the
lamp from both switches. The lamp reports its current on/off state and dimming
level through the solid line that represents the feedback connection to the
switches, which allows all components of the stairwell lighting system to be
aware of current lighting conditions.