don't get any logs when rebooting but I think I found the culprit in my manifest:
AddReceiverText(usbconnectedservice,
<intent-filter>
<action android:name="android.hardware.usb.action.USB_DEVICE_ATTACHED" />
</intent-filter>
<meta-data android:name="android.hardware.usb.action.USB_DEVICE_ATTACHED"
android:resource="@xml/device_filter" />)
this is my service code
#Region Service Attributes
#StartAtBoot: False
#End Region
Sub Process_Globals
'These global variables will be declared once when the application starts.
'These variables can be accessed from all modules.
End Sub
Sub Service_Create
Log("USBConnectedService Created")
End Sub
Sub Service_Start (StartingIntent As Intent)
'notify our print service that our usb must have been re-connected
Log(StartingIntent.Action)
If StartingIntent.Action="android.hardware.usb.action.USB_DEVICE_ATTACHED" Then
'how to check if service is started?
Try
'launch our print service app
If PrintService.JobList.IsInitialized Then
If PrintService.JobList.Size>0 Then
'try to reconnect and print
'CallSub(PrintService,"doPrintJob")
Select Case Globals.PrintMode
Case Globals.PrintModeUSB
CallSub(PrintService,"ConnectUSBPrinter")
End Select
End If
End If
Catch
End Try
End If
End Sub
Sub Service_Destroy
Log("USBConnectedService Destroyed")
End Sub
any idea why?