Echelon FTXL User Manual
Page 96
![background image](/manuals/735717/96/background.png)
84
Developing an FTXL Application
application-specific processing of update completion. Figure 10 shows the control
flow for processing a network variable update.
LonPropagateNv()
FTXL Application
FTXL LonTalk Protocol
Stack and API
Send Network Variable
Update to Network
Add “Update Complete”
Event to Queue
LonEventPump()
LonNvUpdateCompleted()
LonEventReady()
Figure 10. Control Flow for Sending a Network Variable Update to the Network
In the case of an unacknowledged or repeated service type, the FTXL LonTalk
protocol stack considers the update complete when it has finished sending the
update to the network. In the case of an acknowledged service type, the FTXL
LonTalk protocol stack considers the update complete when it receives
acknowledgements from all receiving devices, or when the retry timer expires
n
times (where
n
is the retry count for the network variable + 1).
To process an update failure, edit the LonNvUpdateCompleted() callback handler
function in the FtxlHandlers.c file. This function is passed the network variable
index (the same one that you passed to the LonPropagateNv() function), and is
also passed a success flag. The function is initially empty, but you can edit it to
add your application-specific processing. The function initially appears as:
void LonNvUpdateCompleted(const unsigned index, const
LonBool
success)
{
/* TBD */
}