I am trying to figure out why my services got destroyed when i used the GPS Example.
I get Debug Logs and this is what i noticed
My Communication Service has
Any reason for this??
I get Debug Logs and this is what i noticed
Main Activity Pause Event
ComSerial Service Destory
Attempt 1
Astream.Close 1
Serial1.Disconnect 1
CommunicationRoutine Service Destory
Main Activity Resume Event
mnuConnectPart3 called mnuDisconnect_Click Event
mnuDisconnect_Click Event
My Communication Service has
B4X:
Sub Service_Create
Service.AutomaticForegroundMode = Service.AUTOMATIC_FOREGROUND_NEVER 'we are handling it ourselves
Timer_RequestOBD.Initialize ("Timer_RequestOBD", 20)
Timer_Timeout.Initialize ("Timer_Timeout", 3000)
tmrKeepAliveService.Initialize("tmrKeepAliveService", 5000)
tmrKeepAliveService.Enabled = True
Starter.pws.PartialLock
End Sub
B4X:
Sub Service_Start (StartingIntent As Intent)
' Service.StopAutomaticForeground 'Call this when the background task completes (if there is one)
Service.StartForeground(1, CreateNotification("..."))
tmrKeepAliveService_Tick
End Sub
Any reason for this??