I’ve got a handful of devices that I have firmware files for, and would like to update the devices with them.
As far as I understand, the zigbee binding itself supports firmware updates (here), but the firmware provider to actually link device types to firmware files is missing (here).
I’m curious where I would start looking to learn how to implement this firmware provider. I’ve skimmed through the documentation I’ve been able to find, but I haven’t managed to find a good starting place for this.
Alternatively, if this is something that somebody’s working on already, point me towards it and I’ll see if I can help by offering some test subjects.
This isn’t really anything to do with the ZigBee binding. The firmware provider is completely independent, and the OTA protocol itself is already supported in the binding.
I believe in the past the plan was to have such a provider, but that was in ESH so I’m not sure what the status is now. I’m also not sure where the documentation is - I think there was an issue raised to add documentation as there was/is none in ESH, but I’m not sure.
I have implemented a provider, but unfortunately I can’t provide that publicly at the moment - maybe in future I will find some time to sort it out.
Alright. Well, it doesn’t look like any of the other bindings implement firmware updating, so I think I’m kinda stuck. I’m not familiar enough with the project’s architecture to start from just the comments on the generic FirmwareProvider. I guess I’ll see if I can update these some other way for now.
@chris is there any update on the topic?
A few companies (IKEA, Osram) offer download links for their firmware files, would be great to have at least a manual way to trigger an update - maybe directly via the karaf console.
Would you be so kind to share the firmware links? I couldn’t find any for Osram.
Others like IKEA or Philips did not try yet, but would appreciate if you would share the valuable information you’ve collected so far.
I will shortly be able to provide a way to update ZigBee devices via the binding - either using the console, or using PaperUI. So, if we actually have the OTA files, in the official ZigBee format, then it should be possible to load these soon (I really just need to do some final testing with the binding).
@chris I’m trying to get the “image type” attribute for my bulbs, but there doesn’t seem to be a way to get it via karaf or via the zigbee java console. Any change you could make it available at some point?
But getting the firmwares for all manufacturers seems to be hard as they are not published openly (besides of course, getting the update process to work)
What do you mean exactly - you want to know what image type the bulb expects, or you want to know what image type a file is for?
Normally this isn’t available to the user - it’s stored in the files, and the device will request the image type when it starts the OTA. But first you need to get the files from the manufacturer and that can be difficult - most of the ones I have here are only available under a non-disclosure agreement so I can’t provide them.
The ZigBee binding has had OTA updates for the past few years - it was implemented for Deutche Telekom some time back.
What do you mean exactly - you want to know what image type the bulb expects, or you want to know what image type a file is for?
I want to know what image type the bulb expects - I see that deconz/phoscon has a way to check for this (Technical support) and it’s used to provide guidance on which file to download from the firmware archives
Normally this isn’t available to the user - it’s stored in the files, and the device will request the image type when it starts the OTA.
That’s what I was missing as far as I understand, the OTA process is started by the bulb itself, I’ll try to inspect the traffic and find out what’s requested. Caching this in the zigbee binding and showing the attribute would be very useful
Normally you don’t need to worry about this - just get the right firmware. If you want to read it though, it is attribute id 8 so you can read this from the CLI.
Correct. The binding will notify a device that there is a file available, the device then starts the upgrade and one of the first parts of this is to check the file types etc and the transfer will stop if it’s not consistent.
Why? I don’t really understand why this is useful. This is a protocol issue - if you get the files from the manufacturer for your model of bulb, then you should not care. Some devices will also require multiple file types, so it’s not 100% straight forward.
Normally you don’t need to worry about this - just get the right firmware.
That’s exactly the point: I can’t figure out which firmware is the right one, I tried multiple ones and I can’t get the binding to start the upload process, so I want to double-check what the bulb says and make sure I am using the right file. I’m starting to suspect the manufacturer_id is not correct, even if the Ledvance download page has OSRAM-specific files.
If you want to read it though, it is attribute id 8 so you can read this from the CLI.
Success!
After rebuilding the binding using ZSS 1.3.1 (with the CC2531 serial fixes), I finally managed to update all my bulbs with the newest firmware.
The debug log has been very useful to find the image type ID: