Get/use bluetooth device from OS
KannarFr opened this issue · comments
Hi,
There is a way to get the deviceInfo from already connected bluetooth device when launching EscPos and then EscPos.connect easily without listeners on device connection?
Alex.
Using another lib?
Or simply using the bluetoothDeviceFound
listener, but it doesn't work, only the bluetoothStateChanged
works on connection from Android bluetooth settings.
Another question: (I'm trying to debug) how to print react-native-esc-pos logs to JS server which is running an application using this library? Probably just a loglevel or a mode to set?
There is a way to get the deviceInfo from already connected bluetooth device when launching EscPos and then EscPos.connect easily without listeners on device connection?
Probably we could expose a new API connectedDevices
. I will need to refer to one of the famous lib (https://polidea.github.io/react-native-ble-plx/#blemanagerdevices).
Another question: (I'm trying to debug) how to print react-native-esc-pos logs to JS server which is running an application using this library? Probably just a loglevel or a mode to set?
Agree with your suggestion, a debug: boolean
option could probably be beneficial to the developer.
I am in the midst of rewriting the codebase, but I have very little time on this project as of now, if that is something bothering you probably will need your help on contributing to the project