User Manual

LonTalk Stack Developer’s Guide 79
nciMaxSendTime[0]
};
network output polled eeprom SNVT_elapsed_tm nvoUsage;
fblock UFPTenergyMeter {
nvoWattage[0] implements nvoWattage;
nviAmpere[0] implements nviAmpere;
nviVoltage[0] implements nviVoltage;
nviCosPhi[0] implements nviCosPhi;
nvoUsage[0] implements nvoUsage;
} Meter external_name("Meter") fb_properties {
static nciCoupling
};
This example implements two arrays of configuration network variables,
nciMinSendTime and nciMaxSendTime. Each element of these two arrays
applies to one element of the nvoWattage array, starting with nciMinSendTime[0]
and nciMaxSentTime[0]. Each element of the nvoWattage array of network
variables in turn implements the nvoWattage member of one element of the Meter
array of functional blocks, again starting with nvoWattage[0].
The user-defined UCPTcoupling configuration property nciCoupling is shared
among all three meters, configuring the meters as three single-phase meters or
as one three-phase meter in this example. There is only a single nciCoupling
configuration property, and it applies to every element of the array of three
UFPTenergyMeter functional blocks.
The LonTalk Interface Developer utility creates a network variable table for the
configuration network variables and the persistent nvoUsage network variable.
Functional Blocks with Configuration Properties
Implemented in a Configuration File
This example implements a device similar to the one in the previous example,
with these differences:
1. All configuration properties are implemented within a configuration file
instead of as a configuration network variable
2. A SNVT_address type network variable is declared to enable access to
these files through the direct memory files feature
3. An SFPTnodeObject node object has been added to support the SNVT
address network variable
// Config properties for the node object
SCPTlocation cp_family cpLocation;
// Network variables for the node object
network input SNVT_obj_request nviNodeRequest;
network output polled SNVT_obj_status nvoNodeStatus;
const network output polled SNVT_address nvoFileDirectory;
// Node object
fblock SFPTnodeObject {
nviNodeRequest implements nviRequest;