Volume control doesn't update

Are you implementing the get volume side of things?

No, not sure how to.
Haven’t found a reference to get_volume in documentation. I am able to set the initial volume with
volume_value: PostCode(NilesZone, “volume”), //returns niles volume as integer

How do give roon the new volume once I move the volume slider? I thought
this.state.volume_value = PostCode(NilesZone, newvol); // sets & returns niles new volume as integer
would set the new volume slider value.

Figured out what was missing

this.update_state({ volume_value: this.state.volume_value });

1 Like

Hello,

I have the same problem, how to get the slider in Roon to update after a volume change.
Is it only working with Meridian devices, which give feedback to update the slider? I have a RS232 pre which I only want vol up/down to control. :wink:

After a lot of trial and error, I am wondering If this is even possible…I am just using the data from Volume change to use it in small microcontroller.
Thing is, there is no feedback to update volume value.

Code:
function ev_volume(val) {
let control = meridian.control;
console.log("[Meridian Extension] received volume change from device:", val);
if (meridian.volume_control)
meridian.volume_control.update_state({ volume_value: val });

You have to update it back. If there’s no feedback over rs232 you will have to either keep track of the current volume in your extension or just expose a relative rather than absolute volume control. What pre?

Thanks Joe,

So I have to get feedback somehow, and I will try.
Nice customized Roon web controller you made btw. :slight_smile:

Well, my controller finally reports status back, but how to get the updated state working is another matter.
Mike’s solution doesn’t seem to work in my case.
Harder than I thought to get this done.

Joe, the pre is a diy affair with microcontoller motor volume.

<- REQUEST 7 com.roonlabs.volumecontrol:1/set_volume {“control_key”:“1”,“mode”:“absolute”,“value”:31}
-> COMPLETE 7 Success
[Meridian] writing: VN31
[Meridian] received: VN31

I hope that I can get someone can help me.
After a week of fiddling, I simply can not make this work.
Why does receive in the meridian extension say received source change, while instead it should be received volume change…

Output Console:

pi@raspberrypi:~/ok/roon-extension-meridian $ node .
{ volume: ‘40’, source: ‘T1’, port: ‘/dev/ttyUSB0’ }
[Meridian] writing: T1
[Meridian] writing: VN40
-> REQUEST 0 com.roonlabs.registry:1/info
<- COMPLETE 0 Success {“core_id”:“12c1b1e1-f504-48ec-94f5-4fbde0644e47”,“display_name”:“DESKTOP-VUUT4NG”,“display_version”:“1.7 (build 667) stable”}
-> REQUEST 1 com.roonlabs.registry:1/register {“extension_id”:“com.roonlabs.meridian”,“display_name”:“Meridian Volume/Source Control”,“display_version”:“1.0.0”,“publisher”:“Rod Labs, LLC",“email”:"contact@roonlabs.com”,“required_services”:[],“optional_services”:[],“provided_services”:[“com.roonlabs.volumecontrol:1”,“com.roonlabs.sourcecontrol:1”,“com.roonlabs.settings:1”,“com.roonlabs.status:1”,“com.roonlabs.ping:1”],“website”:“https://github.com/RoonLabs/roon-extension-meridian",“token”:"84be477f-6a66-43f6-82f9-6adc842967ef”}
<- CONTINUE 1 Registered {“core_id”:“12c1b1e1-f504-48ec-94f5-4fbde0644e47”,“display_name”:“DESKTOP-VUUT4NG”,“display_version”:“1.7 (build 667) stable”,“token”:“84be477f-6a66-43f6-82f9-6adc842967ef”,“provided_services”:[],“http_port”:9100}
<- REQUEST 1 com.roonlabs.volumecontrol:1/subscribe_controls {“subscription_key”:“99”}
-> CONTINUE 1 Subscribed {“controls”:[]}
<- REQUEST 2 com.roonlabs.sourcecontrol:1/subscribe_controls {“subscription_key”:“100”}
-> CONTINUE 2 Subscribed {“controls”:[]}
<- REQUEST 3 com.roonlabs.status:1/subscribe_status {“subscription_key”:“101”}
-> CONTINUE 3 Subscribed {“message”:null,“is_error”:null}
[Meridian Extension] Connected
-> CONTINUE 3 Changed {“message”:“Connected to Meridian”,“is_error”:false}
[Meridian] writing: T1
-> CONTINUE 1 Changed {“controls_added”:[{“display_name”:“Meridian”,“volume_type”:“number”,“volume_min”:1,“volume_max”:99,“volume_value”:“40”,“volume_step”:1,“is_muted”:false,“control_key”:“1”}]}
-> CONTINUE 2 Changed {“controls_added”:[{“display_name”:“Meridian”,“supports_standby”:true,“status”:“deselected”,“control_key”:“1”}]}
<- REQUEST 9 com.roonlabs.volumecontrol:1/set_volume {“control_key”:“1”,“mode”:“absolute”,“value”:41}
-> COMPLETE 9 Success
[Meridian] writing: VN41
<- REQUEST 10 com.roonlabs.volumecontrol:1/set_volume {“control_key”:“1”,“mode”:“absolute”,“value”:42}
-> COMPLETE 10 Success
[Meridian] writing: VN42
<- REQUEST 20 com.roonlabs.volumecontrol:1/set_volume {“control_key”:“1”,“mode”:“absolute”,“value”:41}
-> COMPLETE 20 Success
[Meridian] writing: VN41
[Meridian] received: VN41
[Meridian Extension] received source change from device: VN41
-> CONTINUE 1 Changed {“controls_changed”:[{“display_name”:“Meridian”,“volume_type”:“number”,“volume_min”:1,“volume_max”:99,“volume_value”:“40”,“volume_step”:1,“is_muted”:false,“control_key”:“1”}]}
-> CONTINUE 2 Changed {“controls_changed”:[{“display_name”:“Meridian”,“supports_standby”:true,“status”:“deselected”,“control_key”:“1”}]}