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
I understand that the characterDelimiter is used to separate messages received via Bluetooth in discrete chunks / packets. However, it would be useful to have a configuration option (a field in config) so that we can also enable receiving the characterDelimiter too.
Let's say the characterDelimiter is 0x0A, and I receive the following sequence over the Bluetooth link:
0xAA 0xBB 0xCC 0x0A0x0A 0xDD 0xEE 0xFF 0x0A
In the current version of the library I would get two onDataRead callbacks, with the following content:
0xAA 0xBB 0xCC
0xDD 0xEE 0xFF
It would be great to have a config option (for example something like config.receiveDelimiter), that when active would generate three callbacks:
0xAA 0xBB 0xCC 0x0A 0x0A
0xDD 0xEE 0xFF 0x0A
In this way, we would be able to recreate the complete incoming sequence, if we wanted. Of course, if the config option above would be disabled, the code would work just like it works now.
Unfortunately I could not find a workaround to this issue. A partial workaround would be to append a delimiter to every callback, but if the original sequence would have several delimiter characters in a row, there would be no way of detecting that.
So, I suggest you make a very easy modification in BluetoothClassicService.java (lines 334 to 350), together with adding another config option, so that this issue could be solved.
Thank you
The text was updated successfully, but these errors were encountered:
Hello,
I understand that the characterDelimiter is used to separate messages received via Bluetooth in discrete chunks / packets. However, it would be useful to have a configuration option (a field in config) so that we can also enable receiving the characterDelimiter too.
Let's say the characterDelimiter is 0x0A, and I receive the following sequence over the Bluetooth link:
0xAA 0xBB 0xCC 0x0A 0x0A 0xDD 0xEE 0xFF 0x0A
In the current version of the library I would get two onDataRead callbacks, with the following content:
0xAA 0xBB 0xCC
0xDD 0xEE 0xFF
It would be great to have a config option (for example something like config.receiveDelimiter), that when active would generate three callbacks:
0xAA 0xBB 0xCC 0x0A
0x0A
0xDD 0xEE 0xFF 0x0A
In this way, we would be able to recreate the complete incoming sequence, if we wanted. Of course, if the config option above would be disabled, the code would work just like it works now.
Unfortunately I could not find a workaround to this issue. A partial workaround would be to append a delimiter to every callback, but if the original sequence would have several delimiter characters in a row, there would be no way of detecting that.
So, I suggest you make a very easy modification in BluetoothClassicService.java (lines 334 to 350), together with adding another config option, so that this issue could be solved.
Thank you
The text was updated successfully, but these errors were encountered: