与Vesna频谱传感器应用对话的工具
vesna-spectrumsensor的Python项目详细描述
简介
这个python模块抽象了vesna使用的串行线协议 频谱传感器的应用,提供了一个高级的面向对象的 python接口。
安装
要从软件包索引安装全系统,请运行:
$ pip install vesna-spectrumsensor
要从源代码安装全系统,请运行:
$ pip install .
要运行提供的单元测试,请运行:
$ tox
用法
使用此模块的最小应用程序如下所示:
# instantiate the SpectrumSensor class using the path # to the serial device. spectrumsensor = SpectrumSensor("/dev/ttyUSB0") # query the attached hardware for supported configurations. config_list = spectrumsensor.get_config_list() # get required frequency sweep configuration. sweep_config = config_list.get_sweep_config(...) # define callback function that does something with # measurements. def callback(sweep_config, sweep): ... # start spectrum sensing spectrumsensor.run(sweep_config, callback)
有关详细信息,请参阅docstring文档。
该包还安装vesna_rftest脚本,该脚本执行一系列 使用USBTMC连接的射频信号发生器进行自动化硬件测试。跑步 “vesna_rftest–help”以获取可用选项的列表。
许可证
版权所有(c)2017传感器实验室,Jozef Stefan Institute http://sensorlab.ijs.si
此程序是免费软件:您可以重新分发和/或修改 根据由 自由软件基金会,或者许可证的第3版,或者 (由您选择)任何更高版本。
这个程序的发布是希望它能有用, 但没有任何保证;甚至没有 适销性或适合某一特定目的的适销性。见 GNU通用公共许可证了解更多详细信息。
你应该收到GNU通用公共许可证的副本 还有这个节目。如果没有,请参见<;http://www.gnu.org/licenses/>;。
作者:tomaz solc,<;tomaz.solc@ijs.si>;