Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
BLESession: Add _getDevName() helper function
GitHub issue #31 reported that Intelino Smart Train is not connected with pyscrlink. It also reported that getValueText(0x9) call for the device instead of getValueText(0x8) avoids the failure. This implies that the Intelino Smart Train does not report AdType 0x8 "Shortened local name" but it reports AdType 0x9 "Complete local name". To get local name of the BLE devices regardless AdType support status of those devices, introduce a helper function _getDevName(). It gets the AdType 0x9 "Complete local name" first. If it is not available, get AdType 0x8 "Shortened local name". Use this helper function at all places to get the device name. Signed-off-by: Shin'ichiro Kawasaki <[email protected]>
- Loading branch information