PTT
Submit
Submit
選擇語言
正體中文
简体中文
PTT
Python
[問題] Raspberry pi 3 藍牙Characteristic以及UUID
作者:
James840617
(James Li)
2017-06-07 17:06:04
最想用raspberry pi 3的藍芽功能收集資料
首先步驟是想先能抓取到藍芽的Characteristic以及UUID
於是用現成code達到了這一步
https://github.com/IanHarvey/bluepy/blob/master/bluepy/blescan.py
(已造作者的開發環境並架設完成)
http://i.imgur.com/s7bcu2Q.jpg
這是執行後的結果
確實已達到我要的目的
(我的裝置是那兩個藍色gm22AD、gmFFFF)
但現在我想要”只顯示我兩個裝置的資訊Characteristic以及UUID”
目前構想是在def dump_services(dev):這段加一個判斷式if,else
但不確定是不是加在這就沒問題
http://i.imgur.com/2P5ysId.jpg
Code在這裡:
https://github.com/IanHarvey/bluepy/blob/master/bluepy/blescan.py
https://github.com/IanHarvey/bluepy/blob/master/bluepy/blescan.py
請求開導..
作者:
s860134
(s860134)
2017-06-07 22:38:00
假設你已經知道你裝置的 mac 了, dev 是 ScanEntry
https://goo.gl/UHspzV
裡面有些可以判斷的數值[dev for dev in devices if dev.addr in mac_list]在 blescan.py#L127 原本巡行所有找到的 ScanEntry你在這之前把 devices 篩到只有你要的 device 即可
繼續閱讀
[問題] 排列組合的疑問
ptt0720
Re: [問題] youtube影片爬蟲問題
coeric
[問題] thread與queue的問題
icetofux
[問題] 如何取得滑鼠在視窗中click的座標?
asb0401
Re: [問題] Python2 unicode轉日文
ides13
[問題] youtube影片爬蟲問題
neil987
Re: [問題] Python2 unicode轉日文
TZULIU
[閒聊] 徵python爬蟲/資料分析家教
voho00
[問題] Python2 unicode轉日文
TZULIU
[問題] 在terminal下執行有引數的python檔
warex14
Links
booklink
Contact Us: admin [ a t ] ucptt.com