GithubHelp home page GithubHelp logo

alexyazdani / prbs-automation-api Goto Github PK

View Code? Open in Web Editor NEW
0.0 1.0 0.0 23 KB

Example API to be used with Cisco IOS Shell to work with Automation

Shell 100.00%
cisco cisco-ios prbs shell shell-script

prbs-automation-api's Introduction

Created by Alex Yazdani 2023

PRBS-Automation-API

Example API to be used with Cisco IOS Shell to work with Automation.

First few setup lines: enable shell commands, enable PRBS, disable logging to not interfere with expected responses, disable exec timeout, instantiate error count and initial timestamp variables.

The first example file applies to a rather simple DUT. The second example file, PRBS_API_2, shows an example where the DUT being tested has 2 different PHYs, therefore 2 different sets of commands for different ports. Start, stop, and error check commands were implemented to detect port and decide which command set to use. There is also example code to pull out error count from registers returning MSB and LSB values.

Functions:

  1. SetPortEnabledState() - Enable or disable desired port, optional arguement to set port speed for dual rate optics.

  2. SetVoltageMargin() - Margin the voltage.

  3. SetPRBSPattern() - Start generating PRBS and continue to generate until lock status is validated.

  4. StartPRBSStatistics() - Start measuring statistics: set error count to 0 and initialize timestamp.

  5. GetPRBSStatistics() - Fetch BER statistics, ie, error counts, timestamps, and lock status. output in a stout format.

  6. GetDomPower() - Fetch the power from the Digital Optical Monitor.

Official Documentation of Cisco IOS Shell: https://www.cisco.com/c/en/us/td/docs/ios/netmgmt/configuration/guide/Convert/IOS_Shell/nm_ios_shell.html

prbs-automation-api's People

Contributors

alexyazdani avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.