Skip to content

Firmware OTA wrongly interprets Query Next Image Command file version parameter #918

@pgaufillet

Description

@pgaufillet

While troubleshooting the Zigbee Firmware OTA process, I have discovered that the field File Version of Query Next Image Command is probably wrongly interpreted in ZigBeeThingHandler:

    @Override
    public ZigBeeOtaFile otaIncomingRequest(QueryNextImageCommand command) {
        // We simply store the requested firmware version information so that it's
        // available for the firmware provider
        lastFirmwareVersion = new ZigBeeFirmwareVersion(command.getManufacturerCode(), command.getImageType(),
                command.getFileVersion());

As stated in the ZigBee Cluster Library Specification (document 075123), section 11.13.4.2.4, The file version included in the payload represents the device’s current running image version, and not the requested version. Due to it, the logic in ZigBeeFirmwareProvider.getFirmware() and ZigBeeFirmwareProvider.getFirmwares() is probably broken: the selection should include files which version is greater than the current version (hence called improperly requestedVersion).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions