How to upgrade firmware through python code?
file = open("firmware_iskra.bin", "rb")
reply = GXReplyData()
ImageTransfer = GXDLMSImageTransfer()
imageBlockSize = self.read(ImageTransfer, 2)
fw_filename = "firmware_iskra.bin"
imageIdentifier = "firmware_iskra"
forImageSize = int(os.path.getsize(fw_filename))
data=ImageTransfer.imageTransferInitiate(self.client,imageIdentifier,forImageSize)
reply = GXReplyData()
init_val = self.readDataBlock(data, reply)
ImageTransfer.imageBlockValue = file.read()
ImageTransfer.imageBlockCount = None
frames = ImageTransfer.imageBlockTransfer(self.client,
ImageTransfer.imageBlockValue, ImageTransfer.imageBlockCount)
reader.readDataBlock(frames,reply)
This code return access error: unknown error
What is the issue causing with this I tried in GuruxDLMSDirector its working fine while select the file and click update
Hi, Check first that the…
Hi,
Check first that the image identifier is correct. Some meters accept only specific names.
Can you transfer all the blocks for the meter or are you getting the exception right after imageTransferInitiate?
BR,
Mikko
data=ImageTransfer…
data=ImageTransfer.imageTransferInitiate(self.client,imageIdentifier,forImageSize)
self.readDataBlock(data, reply)
when I am try to read this data issue is occuring and I passed active firmware identifier what I got from GuruxDLMS director now its showing
Access Error : Device reports a unmatched type.
Hi, Check the image size…
Hi,
Check the image size that that is correct. What image identifier you was using in GuruxDLMSDirector? Use the same.
BR,
Mikko
same error Access Error :…
same error
Access Error : Device reports a unmatched type.
identifier and image size is correct
Hi, Our clients can update…
Hi,
Our clients can update Iskraemeco meters, but the firmware identifier is not "firmware_iskra".
You need to verify that from the meter vendor.
BR,
Mikko
Is there any way to check…
Is there any way to check the firmware identifier with gurux director?
Hi, No. The meter doesn't…
Hi,
No. The meter doesn't tell it and meter manufacturers are using different names for it.
BR,
Mikko
Hi Mikko, While I am…
Hi Mikko,
While I am updating firmware I am getting the error below
byte must be in range(0, 256)
In this line of code
frames = ImageTransfer.imageBlockTransfer(self.client,ImageTransfer.imageBlockValue, ImageTransfer.imageBlockCount)
Any updates regarding in…
Any updates regarding in this?