跳转到主要内容

包含大量与蓝牙相关的数字的Python包

项目描述

Continuous Integration Code coverage Python package version Supported Python versions Documentation Status License Companies Services Characteristics Descriptors OUIs

bluetooth-numbers

包含大量与蓝牙相关的数字的Python包

本项目提供了一个Python包,包含大量与蓝牙相关的数字,以便Python项目可以轻松使用这些数字。本项目的目标是提供一个共享资源,以便处理蓝牙的各种Python项目不需要通过创建自己的数据库并保持其更新来重复这项工作。

以下资源被使用

安装

您可以使用 pip 从 PyPI 以包的形式安装 bluetooth-numbers

pip install bluetooth-numbers

用法

获取公司 ID 的描述

>>> from bluetooth_numbers import company
>>> company[0x0499]
'Ruuvi Innovations Ltd.'

获取服务 UUID 的描述

>>> from bluetooth_numbers import service
>>> from uuid import UUID
>>> service[0x180F]
'Battery Service'
>>> service[UUID("6E400001-B5A3-F393-E0A9-E50E24DCCA9E")]
'Nordic UART Service'

获取特征 UUID 的描述

>>> from bluetooth_numbers import characteristic
>>> from uuid import UUID
>>> characteristic[0x2A37]
'Heart Rate Measurement'
>>> characteristic[UUID("6E400002-B5A3-F393-E0A9-E50E24DCCA9E")]
'UART RX Characteristic'

获取描述符 UUID 的描述

>>> from bluetooth_numbers import descriptor
>>> descriptor[0x2901]
'Characteristic User Descriptor'

获取 OUI 的描述

>>> from bluetooth_numbers import oui
>>> oui["58:2D:34"]
'Qingping Electronics (Suzhou) Co., Ltd'

查看 模块参考 以获取完整文档。

许可证

该项目由 Koen Vervloesem 提供开源软件,并采用 MIT 许可证。有关更多信息,请参阅 LICENSE 文件。

有关本包中使用的蓝牙号码数据库的 许可证,也请参阅。

项目详情


下载文件

下载适合您平台的文件。如果您不确定选择哪个,请了解更多关于 安装包 的信息。

源分布

bluetooth_numbers-1.1.2.tar.gz (2.0 MB 查看散列)

上传时间

构建分布

bluetooth_numbers-1.1.2-py3-none-any.whl (500.7 kB 查看散列)

上传时间 Python 3

由以下组织支持

AWS AWS 云计算和安全赞助商 Datadog Datadog 监控 Fastly Fastly CDN Google Google 下载分析 Microsoft Microsoft PSF 赞助商 Pingdom Pingdom 监控 Sentry Sentry 错误记录 StatusPage StatusPage 状态页面