sonic-buildimage/platform/broadcom/sonic-platform-modules-accton/as7816-64x/sonic_platform
jostar-yang ab3053b3df
[Accton/PDDF] Support show cmd for psu-temp and fan (#10215)
Why I did it
Support for show platform temp/fan for psu-temp and fan.
Original code doesn't has fan_drawer to support these information.

How I did it
Support for show platform temp/fan for psu-temp and fan.
Add fan_drawer.py and update thermal.py to add needed code.
It need PDDF common code to support . (Refer to #10213)

How to verify it
Test show platform temp and show platform fan.
root@as7726-32x-2:~# show platform fan
Drawer LED FAN Speed Direction Presence Status Timestamp

Fantray1 green Fantray1_1 38% EXHAUST Present OK 20220311 08:13:04
Fantray1 green Fantray1_2 38% EXHAUST Present OK 20220311 08:13:04
Fantray2 green Fantray2_1 38% EXHAUST Present OK 20220311 08:13:04
Fantray2 green Fantray2_2 38% EXHAUST Present OK 20220311 08:13:04
Fantray3 green Fantray3_1 38% EXHAUST Present OK 20220311 08:13:04
Fantray3 green Fantray3_2 38% EXHAUST Present OK 20220311 08:13:04
Fantray4 green Fantray4_1 38% EXHAUST Present OK 20220311 08:13:04
Fantray4 green Fantray4_2 38% EXHAUST Present OK 20220311 08:13:04
Fantray5 green Fantray5_1 38% EXHAUST Present OK 20220311 08:13:04
Fantray5 green Fantray5_2 38% EXHAUST Present OK 20220311 08:13:04
Fantray6 green Fantray6_1 38% EXHAUST Present OK 20220311 08:13:04
Fantray6 green Fantray6_2 38% EXHAUST Present OK 20220311 08:13:04
N/A green PSU1_FAN1 23% EXHAUST Present OK 20220311 08:13:04
N/A green PSU2_FAN1 22% EXHAUST Present OK 20220311 08:13:04
root@as7726-32x-2:~# show platform temp
Sensor Temperature High TH Low TH Crit High TH Crit Low TH Warning Timestamp

PSU1_TEMP1 28 N/A N/A N/A N/A False 20220311 08:13:04
PSU2_TEMP1 25 N/A N/A N/A N/A False 20220311 08:13:04
TEMP1 23.5 80.0 N/A N/A N/A False 20220311 08:13:04
TEMP2 27 80.0 N/A N/A N/A False 20220311 08:13:04
TEMP3 24 80.0 N/A N/A N/A False 20220311 08:13:04
TEMP4 27 80.0 N/A N/A N/A False 20220311 08:13:04
TEMP5 24 80.0 N/A N/A N/A False 20220311 08:13:04

Co-authored-by: Jostar Yang <jostar_yang@accton.com.tw>
2022-03-29 13:36:58 -07:00
..
__init__.py [as7816-64x] Add to support PDDF (#7077) 2021-04-14 14:40:52 -07:00
chassis.py [Accton/PDDF] Add get_sfp() to chassis to handle port idx (#7980) 2021-07-24 18:31:45 -07:00
eeprom.py [as7816-64x] Add to support PDDF (#7077) 2021-04-14 14:40:52 -07:00
fan_drawer.py [Accton/PDDF] Support show cmd for psu-temp and fan (#10215) 2022-03-29 13:36:58 -07:00
fan.py [as7816-64x] Add to support PDDF (#7077) 2021-04-14 14:40:52 -07:00
platform.py [as7816-64x] Add to support PDDF (#7077) 2021-04-14 14:40:52 -07:00
psu.py [as7816-64x] Add to support PDDF (#7077) 2021-04-14 14:40:52 -07:00
sfp.py [as7816-64x] Add to support PDDF (#7077) 2021-04-14 14:40:52 -07:00
thermal.py [Accton/PDDF] Support show cmd for psu-temp and fan (#10215) 2022-03-29 13:36:58 -07:00