Agg_get_connection_state()
Description: |
API procedure, returns the current state of the device's connection to the AggreGate server as well as the synchronization status. |
Syntax: |
sub agg_get_connection_state(byref link_state as en_agg_link_states, byref sock_state as pl_sock_state_simple) |
Returns: |
TCP connection state and synchronization status |
See Also: |
Parameter |
Description |
link_state |
Indirectly returns the synchronization status: 0- EN_AGG_LINK_STATE_IDLE: no connection to the AggreGate server. 1- EN_AGG_LINK_STATE_CONNECTING: connecting now. 2- EN_AGG_LINK_STATE_SYNCRONIZING: synchronizing now. 3- EN_AGG_LINK_STATE_DISCONNECTED: disconnected (by the server). 4- EN_AGG_LINK_STATE_ESTABLISHED: connected and fully synchronized. |
sock_state |
Indirectly returns the state of the TCP link to the server. This is directly from the sock.statesimple property of the socket used for connecting to the AggreGate server. |