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

Roon Volumetric dB-scale not converted to percentage #81138

Closed
juliusvaart opened this issue Oct 28, 2022 · 7 comments
Closed

Roon Volumetric dB-scale not converted to percentage #81138

juliusvaart opened this issue Oct 28, 2022 · 7 comments
Assignees

Comments

@juliusvaart
Copy link

The problem

The extension doesn't convert a dB-scale to percentage scale, volume adjustment in HA always sets the volume to 0 (which is maximum on a dB-scale).

Looking at the code there is a function that tries to convert the scale in media_player.py on line 192 but that doesn't seem to work.

Already tried other possibilities like "Input Number" and "Compensation" but can't get it to work.

What version of Home Assistant Core has the issue?

2022.10.4

What was the last working version of Home Assistant Core?

No response

What type of installation are you running?

Home Assistant Container

Integration causing the issue

roon

Link to integration documentation on our website

https://www.home-assistant.io/integrations/roon/

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 @pavoni, mind taking a look at this issue as it has been labeled with an integration (roon) you are listed as a code owner for? Thanks!

Code owner commands

Code owners of roon can trigger bot actions by commenting:

  • @home-assistant close Closes the issue.
  • @home-assistant rename Awesome new title Change the title of the issue.
  • @home-assistant unassign roon Removes the current integration label and assignees on the issue, add the integration domain after the command.

(message by CodeOwnersMention)


roon documentation
roon source
(message by IssueLinks)

@pavoni
Copy link
Contributor

pavoni commented Oct 28, 2022

It works in my setup (see photos attached), so will needs some more info to understand why it isn’t working for you.

278DED4C-78C9-4E43-AC30-935D3E68D678
A05FFE16-EC21-4A81-A562-A10D2F02AB5A

@juliusvaart
Copy link
Author

Hi @pavoni,

I'm using a Matrix Audio Mini i3 Pro (Roon Ready) device.

In HA it reports the volume between -1.27 and 0. When I drag the volume control it bumps to the left and stays at 0. Happened one time when playing music... i feel sorry for my ears and my neighbours ;-).

In roon and on the device itself, it reports the volume between -127.0 and 0 with 0.5 increments.

Just installed the extension, that's it.

Can i give you more information?

@pavoni
Copy link
Contributor

pavoni commented Oct 28, 2022

I think the code is likely assuming the level is between -80 and 0 for a db based device.

What happens if you set the volume in roon - does HA show something sensible - or always 100%.

@pavoni
Copy link
Contributor

pavoni commented Oct 28, 2022

I've had a look at the roon api docs and the pyroon library and the HA integration are both making some assumptions about endpoints, rather than looking at the information from the api (basically that a db volume control is always -80 to 0, and a regular volume control is always 0-100)

So this is probably the source of the problem.

Will take a look when I'm next working on the library.

@juliusvaart
Copy link
Author

In HA i's a scale from 0 to 100. Whatever I put in it jumps back to 0 and sets the dB to 0 (max volume on Matrix Mini):
Naamloos

When I check the current volume in HA dev tools it gives me a number between -1.27 and 0 in this case -0.54):
Scherm­afbeelding 2022-10-28 om 18 30 23

And in Roon it gives the native level for the Device (-54.0):
roon

@github-actions github-actions bot added the stale label Nov 27, 2022
@github-actions github-actions bot closed this as not planned Won't fix, can't repro, duplicate, stale Dec 4, 2022
@pavoni
Copy link
Contributor

pavoni commented Dec 31, 2022

Reopening - as now have a fix

@pavoni pavoni reopened this Dec 31, 2022
@github-actions github-actions bot removed the stale label Dec 31, 2022
@pavoni pavoni closed this as completed Feb 5, 2023
@github-actions github-actions bot locked and limited conversation to collaborators Mar 7, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants