keepAlive command

Command

keepAlive

Shortcut

ka

Arguments

seconds

Availability

when logged in

Purpose

Starts a watchdog timer, requiring the client to communicate within that period or be disconnected. It is recommended that keepAlive be used to ensure that TCP/IP client connections get closed in the face of network failures (or even just unplugging and plugging in network connections). If the network goes down and the client attempts to communicate, the client will get a timeout and disconnect, reconnecting once the network is restored. The server, however, would normally have no way of knowing that the client gave up on its first connection and reconnected, so server network stack resources consumed over time. keepAlive solves this problem.

Notes

You can disable the watchdog timer with an argument of zero. This command applies to TCP/IP only, not to the serial port.

Response

Something like this: keepAlive 10

In this section

Usage Example

Response

Possible Error Messages

See also

help Command

login command

statusGet command

quietModeEnable command

quietModeDisable command

controlGet command

controlSet command

controlPositionSet command

controlList Command

changeGroupControlAdd command

changeGroupControlRemove Command

changeGroupGet Command

changeGroupClear Command

changeGroupSchedule Command

Usage Example

The client issues:

keepAlive 120\r

or

ka 120\r

Response

keepAlive 120\r\n

Possible Error Messages

\aOverflow\r\n
\aBadArgumentCount\r\n
\anotLoggedIn\r\n