Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[hdpowerview] Add firmware information properties for hub and shade #11980

Merged
merged 1 commit into from
Jan 7, 2022

Conversation

jlaur
Copy link
Contributor

@jlaur jlaur commented Jan 6, 2022

Signed-off-by: Jacob Laursen [email protected]

Fixes #11979

Add firmware information for hub and shade.

Hub:

  • Firmware name.
  • Main processor firmware version (revision, sub revision and build).
  • Radio firmware version (revision, sub revision and build); V2 Hub only

Shade:

  • Firmware version (revision, sub revision and build)
  • Motor firmware version (revision, sub revision and build)

These properties can be useful information for users, but also prepares the binding for handling differences between firmware versions, for example supporting functionality which is only available in V2 Hub. This was almost necessary for #11857.

@jlaur jlaur requested review from andrewfg and a team January 6, 2022 22:18
@fwolter fwolter merged commit 05ebeea into openhab:main Jan 7, 2022
@fwolter fwolter added the enhancement An enhancement or new feature for an existing add-on label Jan 7, 2022
@fwolter fwolter added this to the 3.3 milestone Jan 7, 2022
@fwolter
Copy link
Member

fwolter commented Jan 7, 2022

One of the enhancement/bug/documentation labels must be set to let the PR show up in the release notes.

@lolodomo
Copy link
Contributor

lolodomo commented Jan 7, 2022

You should have rather used the constant from oprnHAB core for firmware version property.

@jlaur
Copy link
Contributor Author

jlaur commented Jan 7, 2022

You should have rather used the constant from oprnHAB core for firmware version property.

Thanks, I was unaware. I'll provide new PR.

@jlaur
Copy link
Contributor Author

jlaur commented Jan 7, 2022

You should have rather used the constant from oprnHAB core for firmware version property.

Thanks, I was unaware. I'll provide new PR.

#11989 - luckily the property text was the same.

@andrewfg
Copy link
Contributor

andrewfg commented Jan 7, 2022

^
LOL, but I think he meant that you could have saved a few bytes by importing the string constants from Thing..

public interface Thing extends Identifiable<ThingUID> {
    final String PROPERTY_VENDOR = "vendor";
    final String PROPERTY_MODEL_ID = "modelId";
    final String PROPERTY_SERIAL_NUMBER = "serialNumber";
    final String PROPERTY_HARDWARE_VERSION = "hardwareVersion";
    final String PROPERTY_FIRMWARE_VERSION = "firmwareVersion";
    final String PROPERTY_MAC_ADDRESS = "macAddress";

@jlaur
Copy link
Contributor Author

jlaur commented Jan 7, 2022

LOL, but I think he meant that you could have saved a few bytes by importing the string constants from Thing..

That's also how I understood it, and how I changed it in #11989? But now I'm not sure I understand anymore, did I miss something? :-)

@andrewfg
Copy link
Contributor

andrewfg commented Jan 7, 2022

I had not seen #11989 -- however I am sure that we both understand it right, and that your new PR is indeed just fine!

@jlaur
Copy link
Contributor Author

jlaur commented Jan 7, 2022

I had not seen #11989 -- however I am sure that we both understand it right, and that your new PR is indeed just fine!

Phew, good. It was a good comment. I was completely unaware of that constant, and by pure luck hit the same name for it, even after a few iterations - originally I had them divided into separate properties for firmwareRevision, firmwareSubRevision and firmwareBuild. IMHO it's not just a few bytes, but a matter of consistency.

mischmidt83 pushed a commit to mischmidt83/openhab-addons that referenced this pull request Jan 9, 2022
moesterheld pushed a commit to moesterheld/openhab-addons that referenced this pull request Jan 18, 2022
nemerdaud pushed a commit to nemerdaud/openhab-addons that referenced this pull request Jan 28, 2022
NickWaterton pushed a commit to NickWaterton/openhab-addons that referenced this pull request Apr 27, 2022
@jlaur jlaur deleted the 11979-hdpowerview-firmware-information branch June 13, 2022 18:44
andan67 pushed a commit to andan67/openhab-addons that referenced this pull request Nov 6, 2022
andrasU pushed a commit to andrasU/openhab-addons that referenced this pull request Nov 12, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement An enhancement or new feature for an existing add-on
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[hdpowerview] Add properties with firmware information
4 participants