2
0
mirror of https://opendev.org/x/pyghmi synced 2026-11-30 14:22:15 +00:00

Add SMM3 identify light manipulation

The SMM3 owing to not having a 'System' places
identify in an Oem location.

Change-Id: I741991a92c701ff951eaff91f2e7d26a6211875d
This commit is contained in:
Jarrod Johnson
2025-04-29 16:33:50 -04:00
parent 4b5fbf55c2
commit 4826c58fb1
2 changed files with 15 additions and 0 deletions
+2
View File
@@ -846,6 +846,8 @@ class Command(object):
self._do_web_request(url, {'ResetType': action})
def set_identify(self, on=True, blink=None):
if hasattr(self.oem, 'set_identify'):
return self.oem.set_identify(on, blink)
targurl = self.sysurl
if not targurl:
root = self._do_web_request('/redfish/v1')
+13
View File
@@ -62,6 +62,19 @@ class OEMHandler(generic.OEMHandler):
health = healthlookup.get(health, pygconst.Health.Critical)
return {'health': health}
def set_identify(self, on=True, blink=False):
if on:
state = 'On'
elif blink:
state = 'Blinking'
else:
state = 'Off'
self._do_web_request('/redfish/v1/Chassis/chassis1', {
'Oem': {'Lenovo': {'LED': {'IdentifyLED': {
'State': state
}}}
}}, method='PATCH')
def get_system_configuration(self, hideadvanced=True, fishclient=None):
return {}