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

Myuplink integration handles enum-controls incorrect #117942

Closed
hakwest opened this issue May 22, 2024 · 4 comments · Fixed by #118661
Closed

Myuplink integration handles enum-controls incorrect #117942

hakwest opened this issue May 22, 2024 · 4 comments · Fixed by #118661

Comments

@hakwest
Copy link

hakwest commented May 22, 2024

The problem

Myuplink integration do not handle writable enum-controls correct.

When the response from Myuplink contains a enum-control that is writable the integration do not handle the response as expected. It should create a writable-control with the enum values. Instead it creates a sensor that can't be used to set any enum-value.
The response below shows the myuplink-swagger-response for the "comfort mode" that have four enum-value for the warmvater comfort-mode.

{
"category": "VVM 310, 3x400V",
"parameterId": "47041",
"parameterName": "comfort mode",
"parameterUnit": "",
"writable": true,
"timestamp": "2024-05-22T15:02:03+00:00",
"value": 0,
"strVal": "economy",
"smartHomeCategories": [],
"minValue": null,
"maxValue": null,
"stepValue": 1,
"enumValues": [
{
"value": "4",
"text": "smart control",
"icon": ""
},
{
"value": "0",
"text": "economy",
"icon": ""
},
{
"value": "1",
"text": "normal",
"icon": ""
},
{
"value": "2",
"text": "luxury",
"icon": ""
}
],
"scaleValue": "1",
"zoneId": null
},

What version of Home Assistant Core has the issue?

core-2024.5.3

What was the last working version of Home Assistant Core?

No response

What type of installation are you running?

Home Assistant OS

Integration causing the issue

Myuplink

Link to integration documentation on our website

No response

Diagnostics information

No response

Example YAML snippet

No response

Anything in the logs that might be useful for us?

No response

Additional information

No response

@home-assistant
Copy link

Hey there @pajzo, @astrandb, mind taking a look at this issue as it has been labeled with an integration (myuplink) you are listed as a code owner for? Thanks!

Code owner commands

Code owners of myuplink can trigger bot actions by commenting:

  • @home-assistant close Closes the issue.
  • @home-assistant rename Awesome new title Renames the issue.
  • @home-assistant reopen Reopen the issue.
  • @home-assistant unassign myuplink Removes the current integration label and assignees on the issue, add the integration domain after the command.
  • @home-assistant add-label needs-more-information Add a label (needs-more-information, problem in dependency, problem in custom component) to the issue.
  • @home-assistant remove-label needs-more-information Remove a label (needs-more-information, problem in dependency, problem in custom component) on the issue.

(message by CodeOwnersMention)


myuplink documentation
myuplink source
(message by IssueLinks)

@astrandb
Copy link
Contributor

Thank you for reporting this issue. This is the first example we see where there is an enum datapoint with writable attribute set to true. This entity should probably be implemented with the select platform. We will put it on the to-do list for the integration.

@hakwest
Copy link
Author

hakwest commented May 28, 2024

Perfect - looking forward for a release with this implemented. :-)

@astrandb
Copy link
Contributor

astrandb commented Jun 2, 2024

@hakwest I have now prepared a PR that adds a select entity for data points with multiple enum values. It works in theory (pytest) but I need to verify the functionality in real life before submitting the change.
Are you comfortable with running a HA development environment? If not, I think the easiest way is if you share access to your device via the myUplink web site. Please contact me on ake@strandberg.eu if you are willing to assist with the final verification.

@github-actions github-actions bot locked and limited conversation to collaborators Aug 18, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants