Please help, always that i want to write in "b4a" i get the same error...
at anywheresoftware.b4a.objects.BleManager2.WriteData(BleManager2.java:377)
In b4i everything Works Good.
Any idea? Thanks
at anywheresoftware.b4a.objects.BleManager2.WriteData(BleManager2.java:377)
In b4i everything Works Good.
Any idea? Thanks
B4X:
#IF B4A
Sub Manager_DataAvailable (Service As String, Characteristics As Map)
Try
'ActivityIndicator2.Visible = False
'clv.Add(CreateServiceItem(Service), "")
Dim Chrt As String=""
For Each id As String In Characteristics.Keys
LogColor(id,Colors.Magenta)
'clv.Add(CreateCharacteristicItem(id, Characteristics.Get(id)), "")
Log( bc.HexFromBytes( Characteristics.Get(id) ) )
If Chrt="" Then Chrt=id
Next
Dim fm As String = ""
'fm = StringToHex("Hola")
fm = fm & "0D0A"
Dim Data() As Byte = bc.HexToBytes(fm)
manager.WriteData(Service,Chrt,Data)
'Sleep(1000)
manager.Disconnect
manager.StopScan
bluetoothBtn.Enabled=True
Catch
Log(LastException)
manager.Disconnect
End Try
End Sub
#End If