mirror of
https://opendev.org/x/pyghmi
synced 2025-02-20 12:30:48 +00:00
Correct check for _sdr in command
In the attempt to clean up, one change broke how a command object knows whether it has an SDR yet or not. Correct that mistake. Change-Id: I76faaccf15c2dbfa2b7d5a3a4e1665e0cefe4c6d
This commit is contained in:
parent
9fb74f68b6
commit
238d5e22f8
@ -312,7 +312,7 @@ class Command(object):
|
||||
|
||||
:returns: Iterator of sdr.SensorReading objects
|
||||
"""
|
||||
if '_sdr' not in self.__dict__:
|
||||
if self._sdr is None:
|
||||
self._sdr = sdr.SDR(self)
|
||||
for sensor in self._sdr.get_sensor_numbers():
|
||||
rsp = self.raw_command(command=0x2d, netfn=4, data=(sensor,))
|
||||
|
Loading…
x
Reference in New Issue
Block a user