-
Notifications
You must be signed in to change notification settings - Fork 177
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
SFF-8472 Rx power conversion function incorrect #449
Comments
closes sonic-net#449 Signed-off-by: Wataru Ishida <[email protected]>
@JaapKeuter Could you test #479? |
closes sonic-net#449 Signed-off-by: Wataru Ishida <[email protected]>
Test? I wish I could, but have no SONiC setup either. |
I see. I can also do that test if you can share the EEPROM dumps and the expected rx power of the SFPs. |
I have been able to get two A2 page dumps from a SFP with different received power levels. Now I've to find some time to 'run the numbers'. |
Analysis of SFP received optical power calculation codeIntroductionThe question was put forward to come up with data read from a SFP with This analysis is based on two data points taken from the same SFP with different References
SpecificationsSection 9 of Ref 1. contains the relevant specifications for the interpretation Method of analysis
Collected data and analysisIn this section the retrieved A2 page data sets are presented, and using the First sampleDataReceived avg. optical power: -6.1 dBm
AnalysisCalibration constants
Raw received power value
Measured received optical power
Conversion to dBm
Putting data into Python code
This give the output
ResultThe reported value, the converted retrieved data and the Python code all come Second sampleDataReceived avg. optical power: -16.8 dBm
AnalysisCalibration constants
Raw received power value
Measured received optical power
Conversion to dBm
Putting data into Python code
This give the output
ResultThe reported value, the converted retrieved data and the Python code all come ConclusionThe Python code correctly converts the data extracted from the SFP into the |
@ishidawataru : are you planning to continue and merge this change? |
…MIS init (sonic-net#449) * Disable periodic polling of port in DomInfoUpdateTask thread during CMIS init Signed-off-by: Mihir Patel <[email protected]> * Replaced sharing of cmis_state from instance to a field in TRANSCEIVER_STATUS table * Improved code coverage * Moved update_port_transceiver_status_table_sw_cmis_state to CmisManagerTask class * Initializing cmis_state to CMIS_STATE_UNKNOWN while spawning CmisManagerTask --------- Signed-off-by: Mihir Patel <[email protected]>
sonic-platform-common/sonic_platform_base/sonic_sfp/sff8472.py
Lines 831 to 871 in 2606cd5
SFF-8472 section 9.3
The specification states, under 5)
Received power, RX_PWR, is given in uW by the following equation:
which means Rx_PWR_AD is raised to the power of 4, 3 and 2 respectively in the expression. The comment and code does not reflect that.
Furthermore, the calibration constants are stored in IEEE Std 754 single precision float format in the device. These cannot be treated as integers, as is done in the code.
The text was updated successfully, but these errors were encountered: