问题
I have viewed many unofficial MiBand SDKs in Github. (e.g. https://github.com/Freeyourgadget/Gadgetbridge) None includes detect when button touching, but I have viewed apps to detect this feature. For example Mi Band 2 Func Button.
Also I have tried sniffing bluetooth data traces, but just show data because mobile device is not rooted and I haven't rooted. Is there any way I can detect the touch of a miband button? Thanks a lot!
回答1:
You can listen if there is any touches event on the Mi Band device.
Assuming that the app authenticated...
Start notification to UUID_CHARACTERISTIC_DEVICEEVENT characteristic (In my case it's "00000010-0000-3512-2118-0009af100700")
and you shall receive '\x04' if the device touched.
来源:https://stackoverflow.com/questions/42255344/is-possible-to-detect-touches-in-miband-2