![background image](http://html1.mh-extra.com/html/ifm/al1330/al1330_operating-instructions-manual_3887894058.webp)
IO-Link master with EtherCAT interface DataLine 4 ports IP 65 / IP 66 / IP 67
58
>
9.2.19
Gateway: Updating the firmware
59789
Substructure:
firmware
Available data points:
Name
Description
Access
../version
Software version
r
../type
Software type
r
../container
Structure for updating the firmware
w
../container/maxsize
Maximum size of the container structure (in bytes)
r
../container/chunksize
Size of a data segment (in bytes)
r
../container/size
Size of the container content (in bytes)
r
r = only read
w = write only
Applicable services:
Name
Description
../install
Install firmware transferred to the IO-Link master
../container/stream_set
Transfer an individual data segment
../container/start_stream_set
Start sequential transmission of several data segments
>
Example: Update firmware
52252
Task:
Update the firmware of the device; size of the firmware file: 356676 bytes
Solution:
The firmware is transferred to the device in fragments (chunks). The size of the fragments depends on
the size of the flash memory of the IO-Link master. To transfer the firmware, the firmware file must be
converted into a character string using BASE64.
1 Preparations
►
Determine the size of the fragments (g = number of bytes):
{"code":"request", "cid": -1, "adr":"/firmware/container/chunksize/getdata"}
►
Convert the firmware file into a BASE64 string.
2 Start the transfer of the firmware
►
Start the transfer of the firmware via the service start_stream_set (parameter "size": size of the firmware file):
{"code":"request", "cid": -1, "adr":"/firmware/container/start_stream_set", "data":{"size":356676}}
3 Load the firmware into the flash memory of the IO-Link master
►
Send the BASE64 string of the firmware file to the IO-Link master fragment by fragment (value = string value with
length g).
{"code": "request", "cid": -1, "adr": "/firmware/container/stream_set", "cid": -1, "data": {"value":
"aWZtfgIAAABBTDF4NXhfY25faXRfdDIuMi43Nw..."}
►
Repeat step 3 until all fragments of the firmware file have been sent to the IO-Link master.
>
IO-Link master stores the segments received in the container area.
4 Install firmware
►
Start the installation of the transmitted firmware.
{"code": "request", "cid": -1, "adr": "/firmware/install", "data": {}}
>