Home of the Squeezebox™ & Transporter® network music players.
Page 2 of 3 FirstFirst 123 LastLast
Results 11 to 20 of 25
  1. #11
    Senior Member
    Join Date
    Oct 2005
    Location
    Ireland
    Posts
    17,835
    Quote Originally Posted by Manul View Post
    Why not? I think having both volume controls in sync would be a perfect solution.
    So if Squeezelite vol is reduced to half and so the device volume is also reduced to 50% - the user hears only 25% of the volume ? Very non-linear control results if both volume controls are active and used..

  2. #12
    Quote Originally Posted by Manul View Post
    I guess the distinction between relative and absolute volume control in getexternalvolumeinfo comes from that same line of thought, but to me it's not quite clear how LMS treats players which report either or both capabilities.
    I expect bpa (BTW, it's nice to hear from you, fellow old-timer!) is right about the non-AV amps and IR Blaster especially since DenonSerial expects to set precise amp volume - even "relative" changes are translated into specific Denon volume levels as the Denon API (serial command syntax) expects/requires that. (FWIW oiut of the box DenonSerial also supports TCP transport; my own setup uses a Raspberry Pi running Raspbian and ser2net so volume changes generate ASCII strings sent to a simple TCP service.)

    Also DenonSerial uses a cache and delay model - if you tap the volume up button on an IR remote a few times in quick succession, DenonSerial will likely only send one or two commands to the amp (change the volume and it adds an item to its work queue basically noting it should tell the amp to go to whatever the SB virtual volume is at the time it processes that queue item). Volume up on an SB Classic/Touch is theoretically something like 0.5 dB per step (Boom uses bigger steps at lower volumes but dB/step is constant with Touch) but if the user sends a few more IR volume up commands quickly, the amp volume will be changed by 1.5 dB or whatever. For your non-AV you might want to pass along every volume up command.

    Personally I really like seeing the actual current volume in the various add software interfaces - iPeng, web UI, Squeezebox screen. So I have always tried to either fix the amp output (which is only really viable of the SB is the only audio source) or to use the DenonSerial model of SB volume fixed at 100% and LMS controlling the amp gain, aligning it with the fictional SB volume. I've never used Felix's IR Blaster plugin.

    -Peter
    owner of the stuff at https://tuxreborn.netlify.com/
    (which used to reside at www.tux.org/~peterw/)
    Note: The best way to reach me is email or PM, as I don't spend much time on the forums.
    Free plugins: AllQuiet Auto Dim/AutoDisplay BlankSaver ContextMenu DenonSerial
    FuzzyTime KidsPlay KitchenTimer PlayLog PowerCenter/BottleRocket SaverSwitcher
    SettingsManager SleepFade StatusFirst SyncOptions VolumeLock

  3. #13
    Senior Member
    Join Date
    Oct 2005
    Location
    Ireland
    Posts
    17,835
    Hi Peterw, nice to hear from you - doing what we can to encourage a new group of plugin developers or at the very least writing down some plugin knowledge & past experience.

    For Manul, background on IRBlaster can be found here http://wiki.slimdevices.com/index.php/IR_Blaster . There is an old hardware "addon" solution for SB3 and Transporter which needed the IRBlaster plugin to make it work work. I think getexternalvolumeinfo was added specifically for IRBlaster may have been added when cometd based controllers (e.g. Touch, Controller , iPeng ) had to be supported.

    I had a quick look at IRBlaster code. There is a lot of code which is about supporting IR remote controls (e.g.defining & learning codes for different devices) and are not relevant to OP.

    The interesting bits are where I think it intercepts the LMS volume controls notifications for a player from the various UI (e.g. IR control for SB3, WebUI, cometd). Then based on the received volume change (up, down and absolute setting) and knowledge of current volume level decide what series of output have to be sent from the IR controller. If this is how it works it is thr basis of what Manul needs - however it is a very technical plugin using bits of LMS code which I have only occasionally wandered.

    Depending on the technical ability of Manul (i.e. ability or willingness to program in 'C') . If all the players are squeezelite based, a much easier solution might be to modify squeezelite. Intercept Squeezelite volume management and redirect to an added device controller support of choice. Squeezelite is well written and there are a number of developers who very familiar with it. This option was never available to previous developers as only players were closed systems.

  4. #14
    Quote Originally Posted by bpa View Post
    So if Squeezelite vol is reduced to half and so the device volume is also reduced to 50% - the user hears only 25% of the volume ? Very non-linear control results if both volume controls are active and used..
    Oops, no, you're of course right. Seems I had a hiccup in my eye-to-brain connection: I misread your post as meaning the LMS volume. The squeezelite volume would indeed need to be fixed. I think this could be achieved by creating a dummy ALSA control and paasing this to squeezelite to use for volume.

    Quote Originally Posted by peterw View Post
    Personally I really like seeing the actual current volume in the various add software interfaces - iPeng, web UI, Squeezebox screen. So I have always tried to either fix the amp output (which is only really viable of the SB is the only audio source) or to use the DenonSerial model of SB volume fixed at 100% and LMS controlling the amp gain, aligning it with the fictional SB volume. I've never used Felix's IR Blaster plugin.
    I'd like that too but I see no way to achieve that with the IR-controlled amps (short of trying image recognition on their displays which seems a bit over the top), so I'd be willing to settle for second best: Being able to control the volume through LMS and its interfaces while LMS knows it doesn't know the actual current volume.

  5. #15
    Quote Originally Posted by bpa View Post
    Depending on the technical ability of Manul (i.e. ability or willingness to program in 'C') . If all the players are squeezelite based, a much easier solution might be to modify squeezelite.
    That was actually my first idea, but that would leave me with the problem of LMS thinking it knew the current volume while in fact it has no clue. Then I stumbled upon the getexternalvolumeinfo command and concluded that others have thought in that direction before.

    Peter, since you have some experience, do you know how LMS handles a player for which the command reports only relative volume control ability? The answer could determine whether it's worthwhile to follow this road any further.

    P.S. Could anybody give me a hint on how to do a barebones plugin that just reports these capabilities? I've looked at Peter's Denon code but it's somewhat biggish and hard to get an overview. Is there something like a minimal do-nothing plugin example anywhere?
    Last edited by Manul; 2019-04-12 at 07:45.

  6. #16
    Senior Member
    Join Date
    Oct 2005
    Location
    Ireland
    Posts
    17,835
    Quote Originally Posted by Manul View Post
    That was actually my first idea, but that would leave me with the problem of LMS thinking it knew the current volume while in fact it has no clue.
    All players send the volume change control command to LMS (i.e. the player does not act immediately on the volume change control command) and then LMS sends a command to the player to change the hardware volume level. So LMS always know the volume level of the player.

    I think you will always have a problem of how to sync the device volume with the LMS volume levels since most device (e.g. IR control) cannot report back the volume level (e.g. what happen when a user turns the device's volume control and not use LMS control). I think IRBlaster may tackle this issue.

  7. #17
    Quote Originally Posted by Manul View Post
    Peter, since you have some experience, do you know how LMS handles a player for which the command reports only relative volume control ability? The answer could determine whether it's worthwhile to follow this road any further.
    I'm sorry to say that I do not know.

    Quote Originally Posted by bpa View Post
    All players send the volume change control command to LMS (i.e. the player does not act immediately on the volume change control command) and then LMS sends a command to the player to change the hardware volume level.
    I think that's only true of the old style "slim" players like SB3 and Transporter. I'm pretty sure Touch and Radio act locally (when the touchscreen or knob are used) and tell LMS after the fact. This caused trouble for VolumeLock - my plugin could not prevent a change but could only react afterwards. I would expect similar for Jive-derived software players.
    owner of the stuff at https://tuxreborn.netlify.com/
    (which used to reside at www.tux.org/~peterw/)
    Note: The best way to reach me is email or PM, as I don't spend much time on the forums.
    Free plugins: AllQuiet Auto Dim/AutoDisplay BlankSaver ContextMenu DenonSerial
    FuzzyTime KidsPlay KitchenTimer PlayLog PowerCenter/BottleRocket SaverSwitcher
    SettingsManager SleepFade StatusFirst SyncOptions VolumeLock

  8. #18
    Senior Member
    Join Date
    Oct 2005
    Location
    Ireland
    Posts
    17,835
    Quote Originally Posted by peterw View Post
    I think that's only true of the old style "slim" players like SB3 and Transporter. I'm pretty sure Touch and Radio act locally (when the touchscreen or knob are used) and tell LMS after the fact. This caused trouble for VolumeLock - my plugin could not prevent a change but could only react afterwards. I would expect similar for Jive-derived software players.
    You're correct and in fact IIRC older players with buttons Boom and possibly Transporter also react - I think it was to avoid response delays. However, my main point was that always LMS knows the volume level of a SB player and I think LMS does send the absolute volume level to the player so then the player has to reconcile volume levels. Without feedback, volume levels on the external device cannot be determined.

    However as I believe Manul is only using squeezelite, this is not the case as squeezelite is not a controller (no Jive Lua code only 'C') or has buttons - volume control is via LMS (although I think there is an option for ALSA volume control - not sure of this functionality) . Again if this is an issue IRBlaster may have addressed it.

  9. #19
    Quote Originally Posted by bpa View Post
    You're correct and in fact IIRC older players with buttons Boom and possibly Transporter also react -
    Hmm. My experience suggested that when Boom uses LMS it is a dumb slim unit (VolumeLock seemed to actually prevent changes) but it's true that it can be used as a standalone powered speaker for the line in jack, and I'm not 100% certain... darn you!

    Quote Originally Posted by bpa View Post
    I think it was to avoid response delays.
    That's the explanation I recall, too.

    Quote Originally Posted by bpa View Post
    However, my main point was that always LMS knows the volume level of a SB player and I think LMS does send the absolute volume level to the player so then the player has to reconcile volume levels. Without feedback, volume levels on the external device cannot be determined.
    I hope IR Blaster will help, but I'm curious how it would. Does it merely do something like keep the virtual volume between 5 and 95 so all the UIs continue to offer Quieter/Louder options? Manul, you might actually want to read the VolumeLock source, see how it intercepts mixer volume commands. Should be pretty easy to have it send IR commands when appropriate even when preventing the virtual volume from changing...
    owner of the stuff at https://tuxreborn.netlify.com/
    (which used to reside at www.tux.org/~peterw/)
    Note: The best way to reach me is email or PM, as I don't spend much time on the forums.
    Free plugins: AllQuiet Auto Dim/AutoDisplay BlankSaver ContextMenu DenonSerial
    FuzzyTime KidsPlay KitchenTimer PlayLog PowerCenter/BottleRocket SaverSwitcher
    SettingsManager SleepFade StatusFirst SyncOptions VolumeLock

  10. #20

    Approaching external volume control (for squeezelite players)

    Quote Originally Posted by peterw View Post
    I'm pretty sure Touch and Radio act locally (when the touchscreen or knob are used) and tell LMS after the fact.
    How do they do that? I looked at the SlimProto description and could not find any client to server command that could tell the server the client's current volume. Do clients use the CLI as well or did I just overlook something.

    Thanks for the VolumeLock suggestion, I'll give that a look.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •