hi
thanks
@1: First step is to test it with airplane mode on and Wifi enabled
at this test , my CheckWiFi subroutin show: "WiFi is OFF"
Private Sub CheckWiFi()
'State - One of the following values: CONNECTING, CONNECTED, SUSPENDED, DISCONNECTING, DISCONNECTED, UNKNOWN.
Dim p As Phone 'Phone Library
MsgboxAsync ("sdkVer="&p.SdkVersion,"") 'for test
If p.GetSettings ("wifi_on") <> 1 Then
MsgboxAsync ("WiFi is OFF","") '!!!!!
Else 'WiFi is on
If p.GetDataState = "DISCONNECTED" Then ' Phone carrier's data network is disconnected
MsgboxAsync ("WiFi is ON and CONNECTED","")
Else
MsgboxAsync ("WiFi is ON but NOT connected to a WiFi network","")
End If
End If
End Sub
and not response from esp_http server
'-----------------
at starter service my program report wifi changed to connected when airplane=on wifi=on
Sub Process_Globals
Public PhoneEvent1 As PhoneEvents
Public wifi_status , mobile_data_status As String
End Sub
...
Sub Service_Create
PhoneEvent1.Initialize("PhoneEvent")
End Sub
....
Sub PhoneEvent_ConnectivityChanged(NetworkType As String, State As String, Intent As Intent)
If(NetworkType="WIFI")Then
wifi_status=State
End If
If(NetworkType="mobile")Then
mobile_data_status =State
End If
ToastMessageShow(NetworkType & " Status Change to "&State,True)
End Sub
my starter service code show:ToastMessageShow -> "wifi Status Change to CONNECTED")
but response (=time out) from http:192.168.4.1 by httpjob
and
WebView1.LoadUrl("
http://192.168.4.1")
show:
net:ERR_CLEARTEXT_NOT_PPERMITTED