简体   繁体   English

bluez5中哪个工具取代了gatttool?

[英]Which tool has replaced gatttool in bluez5?

It seems like since commit b1eb2c4cd057624312e0412f6c4be000f7fc3617 gatttool has been deprecated but I'm unable to find any information on what has replaced gattool. 似乎自commit b1eb2c4cd057624312e0412f6c4be000f7fc3617 gatttool已被弃用但我无法找到有关替换gattool的内容的任何信息。

Every Python Bluetooth LE packages I looked into relays on gatttool and is now broken on my ArchLinux system since the bluez package isn't build with --enabled-deprecated flag (which would build gatttool binary). 每个Python蓝牙LE软件包我都在gatttool上进行了中继,现在我的ArchLinux系统坏了,因为bluez软件包不是用--enabled-deprecated标志构建的(它可以构建gatttool二进制文件)。

pygatt is just broken on my system and bluepy doesn't build as they ship there own (on my system broken) bluez code to build gatttool. pygatt刚刚在我的系统上被破坏了, bluepy没有构建,因为他们自己(在我的系统上打破)bluez代码来构建gatttool。

Whatsoever I looking to write a new wrapper around whatever replaced gatttool but I'm unable to find any information on this topic. 无论如何我想在任何替换的gatttool周围写一个新包装但我无法找到关于这个主题的任何信息。

So which tool from the bluez stack can I use to write a new Python Bluetooth LE wrapper? 那么我可以使用bluez堆栈中的哪个工具编写新的Python蓝牙LE包装器?

update 更新

ArchWiki listed gatttool as deprecated and lists btgatt-client the D-Bus Gatt API as replacement. ArchWikigatttool列为已弃用,并将D-Bus Gatt API列为btgatt-client作为替代品。

gattlib from labapart supports bluez 5 and provides gatttool . 来自labapart的gattlib支持bluez 5 并提供gatttool

I guess gatttool got deprecated due to a missing maintainer rather than being replaced by some new tool. 我认为gatttool由于缺少维护者而被弃用而不是被一些新工具取代。

edit unfortunately the code for gatttool in the linked repository supports only bluez 4. 编辑遗憾的是,链接存储库中的gatttool代码仅支持bluez 4。

This may not be the answer you're looking for, but this package: 这可能不是您正在寻找的答案,但这个包:

https://bitbucket.org/OscarAcena/pygattlib https://bitbucket.org/OscarAcena/pygattlib

describes itself thusly: 这样描述自己:

This is a Python library to use the GATT Protocol for Bluetooth LE devices. 这是一个Python库,可以将GATT协议用于蓝牙LE设备。 It is a wrapper around the implementation used by gatttool in bluez package. 它是gaztool在bluez包中使用的实现的包装器。 It does not call other binaries to do its job :) 它不会调用其他二进制文件来完成它的工作:)

Since I want to access GATT functions from Python, I'm about to give it a whirl. 由于我想从Python访问GATT函数,我即将给它一个旋转。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM