Dear all,
I have written an app to transfer images over bluetooth using Bluetooth AsyncStream WriteStream. Before this, the receiver was using Android 10 and it works but changing the receiver to Android 12 immediately crashed the receiver with no error message (even #BridgeLogger: true does not display anything). Code or no code between NewStream will crash the receiver.
Text transfer using AsyncStream Write works as normal.
I am using B4X 9.5
Sender
I have written an app to transfer images over bluetooth using Bluetooth AsyncStream WriteStream. Before this, the receiver was using Android 10 and it works but changing the receiver to Android 12 immediately crashed the receiver with no error message (even #BridgeLogger: true does not display anything). Code or no code between NewStream will crash the receiver.
Text transfer using AsyncStream Write works as normal.
I am using B4X 9.5
Sender
Sender:
Dim MsgtoSend2 As String
MsgtoSend2 = "M&&"
If Map1FTP = True Then
Dim totalSizeForSending1 As Long = File.Size(File.DirRootExternal & "/SSS/", "image.jpg")
Dim In1 As InputStream = File.OpenInput(File.DirRootExternal & "/SSS/", "image.jpg")
countingStream1.Initialize(In1)
If AStream1.IsInitialized = True Then
AStream1.Write(MsgtoSend2.GetBytes("UTF8"))
AStream1.WriteStream(countingStream1, totalSizeForSending1)
Map1FTP = False
End If
Return
End If
Receiver
[CODE lang="b4x" title="Receiver"]
Sub AStream_NewStream (Dir As String, FileName As String)
End Sub