I have used omnipeek air sniffer, if shut down AP directly, AP won't send Deauthentication packet to client. So that client can't receive WLC_E_DISASSOC_IND.
Is there any way to track if connection activity is still good or lost in whd driver?
Thanks for your reply. I understand what you mean. In our application we can't do ping specific AP periodically.
Actually we need to know the link status to notify our network state machine. If AP is being shut down or RF environment is not good(if our module is far away from AP), we should get the event that connection is down.
We have enable all debug configuration in whd_debug.h, but we can't see any log when shut down AP directly.
We also add "WLC_E_BEACON_RX/WLC_E_BEACON_FRAME_RX/WLC_E_BCNLOST_MSG" to join_events table. But there is no event come in "whd_wifi_join_events_handler" when AP is shut down.
const whd_event_num_t join_events =
WLC_E_SET_SSID, WLC_E_LINK, WLC_E_AUTH, WLC_E_DEAUTH, WLC_E_DEAUTH_IND, WLC_E_DISASSOC_IND, WLC_E_PSK_SUP, WLC_E_CSA_COMPLETE_IND, WLC_E_DISASSOC, WLC_E_BEACON_RX,
WLC_E_BEACON_FRAME_RX, WLC_E_BCNLOST_MSG, WLC_E_NONE
Is there any beacon value or any other events we can implement so that we can know the connection status?
Thanks for your help.
After that found "WLC_E_LINK" will be triggered when AP is being shutdown. But we need to check "whd_join_status".
If AP is down, "reverse of JOIN_LINK_READY" is also be triggered. So we can use this status to notify network state machine has been changed.
if ( (event_header->flags & WLC_EVENT_MSG_LINK) != 0 )
WPRINT_WHD_DEBUG( ("JOIN_LINK_READY!!!!\n") );
whd_driver->internal_info.whd_join_status[event_header->bsscfgidx] |= JOIN_LINK_READY;
WPRINT_WHD_DEBUG( ("~JOIN_LINK_READY!!!!\n") );
_onNetworkStateChangeCallback( AWSIOT_NETWORK_TYPE_WIFI, eNetworkStateDisabled );
whd_driver->internal_info.whd_join_status[event_header->bsscfgidx] &= ~JOIN_LINK_READY;