UMAX140900RST. Ethernet to CAN Converter. Version 1
Page: 34-41
For example, the following request resets all diagnostics:
The following request reboots the converter:
8.4 Firmware Update
The update procedure can be performed by HTTP POST request with MIME type
multipart/form-data to
/api/firmware_update
. After uploading the Converter checks the firmware
checksum and whether it can be programmed into the unit, then the firmware is programmed
into the microcontroller and the unit is restarted.
The Converter sends success-response with information about uploaded firmware in JSON-
format :
In case of failure the Converter will send error-response in JSON-format:
The update procedure can also be performed in two stages:
1)
Send HTTP POST request to
/api/firmware
. During this stage the Converter checks the
firmware and uploads into the unit.
2)
Send HTTP PUT request to
/api/fimware?Apply
. During this stage the firmware is
programmed into the microcontroller and the unit is restarted.
After stage 1, a GET to
/api/fimware?UploadedFileInfo
will respond with information about
uploaded firmware. A PUT to
/api/fimware?Cancel
will clean uploaded firmware from the
Controller’s memory.
{
"Status" : "success, converter restarting",
"DevSerialNumber" : "AF-21153-1.00.af",
"FlashFileName" : "AF-21153-1.00.af",
"FlashFirmwareId" : "21153",
"FlashFirmwareVerNum" : "1.0",
"FlashFirmwareComments" : "RESTful API supported"
}
{
"Status" : "fail"
“File name” :
“Error code” :
“Detail” :
}
{
"Status" : "success ",
"DevSerialNumber" : "AF-21153-1.00.af",
"FlashFileName" : "AF-21153-1.00.af",
"FlashFirmwareId" : "21153",
"FlashFirmwareVerNum" : "1.0",
"FlashFirmwareComments" : "RESTful API supported"
}
PUT http://192.168.0.34/api/diagnostics?ResetDiagnostics
{
"Status" : "success"
}
PUT http://192.168.0.34/api/diagnostics?RebootConverter
{
"Status" : "success"
}