powersupply_sispm: import sispm and usb modules on first use
Change-Id: I6045bb739e5c69972014a9d27be3a24b7ad61c9a
This commit is contained in:
parent
a1daa51665
commit
326091555b
|
@ -17,9 +17,6 @@
|
|||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
import sispm
|
||||
from usb.core import USBError
|
||||
|
||||
from ..core import log
|
||||
from ..core.event_loop import MainLoop
|
||||
from .powersupply import PowerSupply
|
||||
|
@ -77,6 +74,10 @@ class PowerSupplySispm(PowerSupply):
|
|||
########################
|
||||
def __init__(self, conf):
|
||||
super().__init__(conf, 'sispm')
|
||||
|
||||
import sispm
|
||||
from usb.core import USBError
|
||||
|
||||
mydevid = conf.get('device')
|
||||
if mydevid is None:
|
||||
raise log.Error('No "device" attribute provided in supply conf!')
|
||||
|
|
Loading…
Reference in New Issue