There is testing packet which allows to test connection state. Packet is send by one side and ignored by receiver. Both sides can send this packets.
0123 4 bytes MGID
MGID is packet Identifier: 0xD0 0x87 0x05 0xA3.
Common practise is to send such packet in regular intervals (tenth of seconds, e.g. 20 sec.) and test if connection is still active.