Android-ble icon indicating copy to clipboard operation
Android-ble copied to clipboard

蓝牙搜索到,但不显示-三星S7

Open Luhangh opened this issue 7 years ago • 0 comments

String struuid = bytes2HexString(reverseBytes(scanRecord)).replace("-", "").toLowerCase();; Log.d(TAG, "run: "+struuid); String name = device.getName(); Log.d(TAG, "run:sring **"+name); if(!TextUtils.isEmpty(name) && "CardioChek Meter:".contains(name)) { mLeDeviceListAdapter.addDevice(device); mLeDeviceListAdapter.notifyDataSetChanged(); }

请问下上述device.getName()为空,是什么情况 ,device本身是有数据,加这一层校验就过不去 if(!TextUtils.isEmpty(name) && "CardioChek Meter:".contains(name)) {

Luhangh avatar Mar 23 '17 01:03 Luhangh