build/GenericProgrammer: Add check parameter to make check optional.
This commit is contained in:
parent
d6f24f2f68
commit
f381cdcd1a
|
@ -91,8 +91,8 @@ class GenericProgrammer:
|
||||||
def flash(self, address, data_file):
|
def flash(self, address, data_file):
|
||||||
raise NotImplementedError
|
raise NotImplementedError
|
||||||
|
|
||||||
def call(self, command):
|
def call(self, command, check=True):
|
||||||
if subprocess.call(command) != 0:
|
if (subprocess.call(command) != 0) and check:
|
||||||
msg = f"Error occured during {self.__class__.__name__}'s call, please check:\n"
|
msg = f"Error occured during {self.__class__.__name__}'s call, please check:\n"
|
||||||
msg += f"- {self.__class__.__name__} installation.\n"
|
msg += f"- {self.__class__.__name__} installation.\n"
|
||||||
msg += f"- access permissions.\n"
|
msg += f"- access permissions.\n"
|
||||||
|
|
Loading…
Reference in New Issue