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

Add Aeotec ZW175-C EU firmware version 1.3 #135

Merged
merged 1 commit into from
Aug 29, 2024

Conversation

mundschenk-at
Copy link
Contributor

This adds firmware 1.3 for the EU version of the Aeotec Smart Switch 7 which was recently made available. It fixes a rather annoying bug where the change threshold settings don't do anything when the initial value is above 0 (at least for the Watts sensor, though I'm not entirely sure other sensors were not affected as well).

@Aeotec-ccheng Could you please review this PR?

Copy link
Contributor

@Aeotec-ccheng Aeotec-ccheng left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In the IF statement, you may need to change this statement:

"$if": "firmwareVersion < 1.3",
"version": "1.3",

to

"$if": "firmwareVersion < 1.3.1",
"version": "1.3.1",

Most ZW175-C units are already on V1.3.0 so it may not go through, need the 3rd decimal point to get it to others. Otherwise everything else looks good.

@mundschenk-at
Copy link
Contributor Author

mundschenk-at commented Aug 9, 2024

In the IF statement, you may need to change this statement:

"$if": "firmwareVersion < 1.3", "version": "1.3",

to

"$if": "firmwareVersion < 1.3.1", "version": "1.3.1",

Most ZW175-C units are already on V1.3.0 so it may not go through, need the 3rd decimal point to get it to others. Otherwise everything else looks good.

According to the documentation, that is not necessary, patch number 0 is implied (i.e. 1.3.0 and 1.3 are equivalent for the comparison).

As for the current shipping firmware, I recently bought a large number of ZW175-C which were apparently shipped directly from Z-Wave Europe GmbH and so far all were on 1.2.

@Aeotec-ccheng
Copy link
Contributor

In the IF statement, you may need to change this statement:
"$if": "firmwareVersion < 1.3", "version": "1.3",
to
"$if": "firmwareVersion < 1.3.1", "version": "1.3.1",
Most ZW175-C units are already on V1.3.0 so it may not go through, need the 3rd decimal point to get it to others. Otherwise everything else looks good.

According to the documentation, that is not necessary, patch number 0 is implied (i.e. 1.3.0 and 1.3 are equivalent for the comparison).

As for the current shipping firmware, I recently bought a large number of ZW175-C which were apparently shipped directly from Z-Wave Europe GmbH and so far all were on 1.2.

Ah ok, that was my misunderstanding and probably quickly glanced over it. This is fine then.

@AlCalzone
Copy link
Member

AlCalzone commented Aug 12, 2024

Just to clarify, the $if statement is not required per se in this case. If a device is already on firmware 1.3, it won't be offered as an update.
What it achieves though is that the firmware will also not be offered as a downgrade to devices on higher versions. For example if there is a firmware 1.4 in the future and a user desires to downgrade to 1.3 for whatever reason, they won't be able to with the condition firmwareVersion < 1.3.

Not sure if that's what you intended with the other definitions @Aeotec-ccheng ?

@mundschenk-at
Copy link
Contributor Author

@Aeotec-ccheng Is it necessary to prevent downgrades?

@Aeotec-ccheng
Copy link
Contributor

@AlCalzone ah ok that makes sense - it isn't but if it can't be helped then that's fine.

@mundschenk-at it isn't necessary to prevent downgrades, but in some cases downgrade of a specific version can cause bricking in some of our devices. This particular device doesn't care so much

@mundschenk-at
Copy link
Contributor Author

@AlCalzone Should I change the PR to allow downgrades?

@AlCalzone
Copy link
Member

IMO allowing users to downgrade where it is supported would be good.
After all, users can just download another version from the website anyways, but this service is more convenient and can add guardrails for the cases where users shouldn't downgrade.

@mundschenk-at
Copy link
Contributor Author

IMO allowing users to downgrade where it is supported would be good. After all, users can just download another version from the website anyways, but this service is more convenient and can add guardrails for the cases where users shouldn't downgrade.

OK, I've removed the $if condition.

@AlCalzone
Copy link
Member

Thanks! I'll just need a final confirmation from @Aeotec-ccheng then I'll merge.

@Aeotec-ccheng
Copy link
Contributor

@AlCalzone Don't see any issues, just confirming everything is good (file URL and hash)

@AlCalzone AlCalzone merged commit ead1488 into zwave-js:main Aug 29, 2024
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants