Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[sonic_y_cable] add abstract class YCableBase required for Y-cable API support for multiple vendors #186

Merged
merged 28 commits into from
Jul 29, 2021
Merged
Changes from 1 commit
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
1522102
[sonic_y_cable] add abstract class YCableBase required for Y-cable AP…
vdahiya12 May 5, 2021
5bab021
fix comments
vdahiya12 May 6, 2021
9fe685a
fix missing comments
vdahiya12 May 6, 2021
d1dc947
fix corrections
vdahiya12 May 6, 2021
998f323
fix suggestion
vdahiya12 May 6, 2021
8a9d6f7
fix comments
vdahiya12 May 7, 2021
acdb72e
fix the physical_port string;fwfile addition as arg
vdahiya12 May 7, 2021
b8ff39c
fix more suggestions
vdahiya12 May 10, 2021
1d3e0a4
fix debug modes def
vdahiya12 May 10, 2021
66e9647
fix suggestions for case;add new API
vdahiya12 May 10, 2021
458b62f
fix the api names
vdahiya12 May 11, 2021
b6bbf82
fix the suggestions
vdahiya12 May 11, 2021
a4de1c3
fix naming
vdahiya12 May 11, 2021
2a549ca
add more definitions
vdahiya12 May 26, 2021
e828a03
fix comments
vdahiya12 May 27, 2021
8f1018e
fix more suggestions
vdahiya12 Jun 10, 2021
9dabc5c
fix comments
vdahiya12 Jun 15, 2021
5fcd0b2
push suggestion
vdahiya12 Jun 17, 2021
ab18d5f
add more suggest/comments
vdahiya12 Jun 18, 2021
5afe8dc
fix constructor
vdahiya12 Jun 28, 2021
1e5e2a5
fix comment
vdahiya12 Jun 28, 2021
3b7ef85
fix logging
vdahiya12 Jun 30, 2021
cc576c9
fix comments for logger
vdahiya12 Jun 30, 2021
08cd622
fix delimiter
vdahiya12 Jul 1, 2021
df7ee65
fix missing parameter[target] of restart_anlt()
xinyulin Jul 3, 2021
27dc3cf
fix comments; add download status
vdahiya12 Jul 19, 2021
5fd135e
fix missing self keyword
xinyulin Jul 20, 2021
5ca5a03
add definition of LOOPBACK_MODE_NONE
vdahiya12 Jul 26, 2021
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 7 additions & 8 deletions sonic_y_cable/y_cable_base.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,6 @@

class YCableBase(Logger):

def __init__(self, log_identifier):
super(YCableBase, self).__init__(
log_identifier=log_identifier,
log_facility=Logger.LOG_FACILITY_DAEMON,
log_option=(Logger.LOG_OPTION_NDELAY | Logger.LOG_OPTION_PID)
)

# definitions of targets for getting the various fields/cursor
# equalization parameters from the register spec.
# the name of the target denotes which side MCU
Expand Down Expand Up @@ -79,14 +72,20 @@ def __init__(self, log_identifier):
PRBS_DIRECTION_GENERATOR = 1
PRBS_DIRECTION_CHECKER = 2

def __init__(self, port):
def __init__(self, port, log_identifier):
"""
Args:
port:
an Integer, the actual physical port connected to a Y cable
"""
self.port = port

super(YCableBase, self).__init__(
log_identifier=log_identifier,
log_facility=Logger.LOG_FACILITY_DAEMON,
log_option=(Logger.LOG_OPTION_NDELAY | Logger.LOG_OPTION_PID)
jleveque marked this conversation as resolved.
Show resolved Hide resolved
)

def toggle_mux_to_tor_a(self):
"""
This API does a hard switch toggle of the Y cable's MUX regardless of link state to
Expand Down