framework/src/st_things/things_stack/utils/things_network.c
//--------------------------------------------------------------------------------
/**
 * Function definition for turn on soft ap.
 */
Function definition for turn on soft ap.
Function definition for turn on soft ap .
bool things_network_turn_on_soft_ap()
{
	wifi_manager_info_s info;	
	wifi_manager_get_info(&info);
	wifi_manager_remove_config();
	if (info.mode != SOFTAP_MODE) {
		wifi_manager_softap_config_s *ap_config = dm_get_softap_wifi_config();
		if (wifi_manager_set_mode(SOFTAP_MODE, ap_config) != WIFI_MANAGER_SUCCESS) {
			THINGS_LOG_E(TAG, "Failed to change to SOFTAP mode");
			return false;
		}
	}
	pthread_mutex_init(&g_ap_list_mutex, NULL);
	THINGS_LOG_V(TAG, "In SOFTAP mode");
	return true;
}
bool things_network_turn_on_soft_ap ( ) { wifi_manager_info_s info ; wifi_manager_get_info ( & info ) ; wifi_manager_remove_config ( ) ; if ( info . mode != SOFTAP_MODE ) { wifi_manager_softap_config_s * ap_config = dm_get_softap_wifi_config ( ) ; if ( wifi_manager_set_mode ( SOFTAP_MODE , ap_config ) != WIFI_MANAGER_SUCCESS ) { THINGS_LOG_E ( TAG , " " ) ; return false ; } } pthread_mutex_init ( & g_ap_list_mutex , NULL ) ; THINGS_LOG_V ( TAG , " " ) ; return true ; }
Function definition for turn on soft ap.
Function definition for turn on soft ap .
// Keep Wi-Fi Manager information. // Get the Wi-Fi Manager information(ip4 address,mac address,rssi,mode). /**
	 * If info mode is not in soft ap mode than data manager get the soft ap configuration details.
	 * and after that wifi manager set the state mode in soft ap mode.
	 */