Skip to content

Commit 3b730b3

Browse files
committed
iot2050-eio-manager: Detect controller flash chip automatically
The EIO firmware updater was hardcoded to a specific flash chip model. This prevents it from working with hardware revisions that use a different chip, such as those found in some SIMATIC IOT2050 models. By removing the hardcoded chip name, we allow flashrom to use its auto-detection capabilities. This makes the firmware update process more robust and compatible with different hardware. Signed-off-by: Li Hua Qian <huaqian.li@siemens.com>
1 parent b29b663 commit 3b730b3

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

meta-sm/recipes-app/iot2050-eio-manager/files/iot2050_eio_fwu.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ def __init__(self, prog_name, prog_param, chip_names):
3737
self.flashctx = ctypes.c_void_p()
3838
self.prog_name = ctypes.create_string_buffer(prog_name)
3939
self.prog_param = ctypes.create_string_buffer(prog_param)
40-
self.chip_names = ctypes.create_string_buffer(chip_names)
40+
self.chip_names = ctypes.create_string_buffer(chip_names) if chip_names else None
4141

4242
if self.c_lib.flashrom_programmer_init(ctypes.pointer(self.flashprog),
4343
self.prog_name,
@@ -100,7 +100,7 @@ def __init__(self, firmware):
100100
try:
101101
self.flash_prog = \
102102
FlashRomProgrammer(b"linux_spi", b"dev=/dev/spidev1.0",
103-
b"MX25L8005/MX25L8006E/MX25L8008E/MX25V8005")
103+
None)
104104
self.write_firmware = self.__get_write_firmware()
105105
except UpgradeError as e:
106106
raise UpgradeError("EIOFirmware: {}".format(e.err))

0 commit comments

Comments
 (0)