Files
pqAutomationApp/UniTAP/dev/dev_base_roles.py

29 lines
702 B
Python
Raw Permalink Normal View History

2026-07-02 17:16:18 +08:00
from UniTAP.libs.lib_tsi.tsi_io import DeviceIO
class DevBase:
"""
Class `DevBase`.
"""
def __init__(self, dev_io: DeviceIO):
self.__dev_io = dev_io
def is_fw_update_available(self) -> bool:
"""
Checks if there is a firmware update available for the current device.
Returns:
object of bool type.
"""
return self.__dev_io.is_fw_update_available()
def get_fw_update_info(self) -> str:
"""
Returns a list of modules to update on the current device and also displays the current version.
Returns:
object of str type.
"""
return self.__dev_io.get_fw_update_info()