白盒PON OLT软件
pypon的Python项目详细描述
乒乓球
Pypon—一个简单的PON光线路终端(OLT)控制器,支持Voltha项目的OpenOLTAPI。
在python虚拟环境中安装pypon
$ virtualenv myenv
.. some output ..
$ source myenv/bin/activate
(myenv) $ pip install pypon
检查ponctl是否已安装
$ which ponctl
...myenv/bin/ponctl
PONCTL帮助
$ ponctl --help
Usage: ponctl [OPTIONS] COMMAND [ARGS]...
ponctl - Command-line utility for managing PON whiteboxes
Options:
--help Show this message and exit.
Commands:
devinfo Get device info from OLT_HOST_PORT.
ind Get device info from OLT and, optionally, send them to Kafka...
使用ponctl显示olt设备信息
$ ponctl devinfo 10.90.0.114:9191
vendor: "EdgeCore"
model: "asfvolt16"
firmware_version: "BAL.2.6.0__Openolt.2018.10.04"
...
使用ponctl显示来自olt
的流指示$ ponster ind 10.90.0.114:9191
2019-06-10 15:03.07 Southbound Grpc Rx
2019-06-10 15:03.07 Indications initialized
2019-06-10 15:03.07 openolt grpc starting
2019-06-10 15:03.07 openolt grpc started
waiting for indication...
olt_ind {
oper_state: "up"
}
waiting for indication...
...
如果运行本地卡夫卡代理,请检查卡夫卡总线上的指示:
confluent-kafka/consumer.py localhost:9092 foo openolt.ind-10.90.0.114
开发
git clone git@github.com:shadansari/openolt.git
cd pypon
pipenv shell
pipenv install
如果更改,重建protobufs:
make protos