You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The base64 is only the way to send bytes from javascript to the native part of the module, the module reconvert the base64 string in bytes and write to the device.
I change the source code to send String value, and transform string to byte array as parameter to peripheral.write(),and transform byte to hexadecimal byte array as parameter to characteristic.setValue(), finally the BLE device successfully read the value.
Activity
marcosinigaglia commentedon Dec 15, 2016
Hi, for now you have to convert in the base64.
zhanguangao commentedon Dec 16, 2016
Can I modify the source code to send hexadecimal ?
marcosinigaglia commentedon Dec 16, 2016
I don't understand the problem, you can convert you hexadecimal value in base64.
zhanguangao commentedon Dec 16, 2016
Because of the BLE device only analysis the hexadecimal value, so I only to send hexadecimal value.
marcosinigaglia commentedon Dec 16, 2016
The base64 is only the way to send bytes from javascript to the native part of the module, the module reconvert the base64 string in bytes and write to the device.
zhanguangao commentedon Dec 17, 2016
I change the source code to send String value, and transform string to byte array as parameter to peripheral.write(),and transform byte to hexadecimal byte array as parameter to characteristic.setValue(), finally the BLE device successfully read the value.