Pioneeravr binding - volume up/down

Did you include the TCP KEEPALIVE change posted above or is that missing in your release? I’m wonderin cause after two days of running your binding one of my pioneer receivers has a broken pipe, same behavior as I had before that patch above.

Hi,

Sorry for the (very) long delay, I have done a pull request with the fix of the broken pipe issue: https://github.com/openhab/openhab2-addons/pull/740

No worries, at least that sort of confirms that it’s not in this volume patch. @mgbowman would you be able to join the two?

@tobo On it! I will pull in the latest openhab/master changes and apply my latest work on top. Will report back when I have another build that needs testing.

Three thumbs up!

Just submitted a PR formatting all the binding code: [PioneerAVR Binding] Format code

Once that gets merged in I’ll apply my code on top and create a PR to be merged in the master distro branch.

In the meantime, please test my latest changes which include the fixes from @Stratehm

pioneeravr-2.0.0.201603171717.jar

Here’s the updated procedure I used to swap the bundles:

openhab> bundle:stop org.openhab.binding.pioneeravr
openhab> bundle:uninstall org.openhab.binding.pioneeravr
openhab> bundle:install https://github.com/mgbowman/openhab2-addons/releases/download/2.0.0-SNAPSHOT/org.openhab.binding.pioneeravr-2.0.0.201603171717.jar
Bundle ID: XXX
openhab> bundle:start org.openhab.binding.pioneeravr

Again, you should see this in the log:

2016-03-17 19:39:51.804 [INFO ] [l.protocol.StreamAvrVolumeController] - AVR @192.168.1.x:8102 - VOLUME_SET commands are UNSUPPORTED

Let me know how it works.

Thanks for the quick assist, unfortunately I had no time to test this today, maybe tomorrow but it’s looking bad, Saturday at the latest. Then I’ll report back!

Installed, up and running. So far so good! No errors, slider working on both receivers, we’ll see what happens with time and the tcp KEEPALIVE.

It seems that something isn’t working with regards to status updates, input and volume don’t change when turning off the receiver for one, they stay the same which was not the case before. Anything in particular you want me to test with regards to this?

@mgbowman

I tried out the binding more thoroughly during Sunday and what I wrote above seems correct, your changes are having the desired effects in terms of being able to use percentage and so on. The TCP has not flaked out so far so hopefully the keepalive is fine as well, time will tell.

However, basically no status updates are received, I can increase decrease volume without the percentage for the volume being changed. Inputs and volume stay set on the last value when receiver is shut off and so on, a change in behavior from before.

I’ll setup a proper OH2 server / testing environment next week - don’t have time this week.

Thankfully, I have a spare RPI2 somewhere around here that needs something to do :smile:

Sounds good M :slight_smile:

I have three pi1s and one pi2 in a drawer not doing much after “cancelled” projects, might be time to go dedicated Oh2 on one of them just for the help of it!

@mgbowman I’ve had to revert now to the @Stratehm build, yours was good in terms of the volume but displayed some funkiness in terms of updating statuses and not loosing the connection over time. I’ll get back to it when you need me to for more OH2 testing.

@mgbowman have you had a chance to test the OH2 binding yourself?

@Stratehm I think I might have found a “bug”, looking at the below it seems that Mute and Volume are correctly updated to UNDEF when the receiver is shut off, but not input?

2016-05-25 15:49:33.014 [INFO ] [marthome.event.ItemStateChangedEvent] - LivingRC_Power changed from ON to OFF
2016-05-25 15:49:33.051 [INFO ] [marthome.event.ItemStateChangedEvent] - LivingRC_Mute changed from OFF to UNDEF
2016-05-25 15:49:33.052 [INFO ] [marthome.event.ItemStateChangedEvent] - LivingRC_Input changed from 19 to
2016-05-25 15:49:33.052 [INFO ] [marthome.event.ItemStateChangedEvent] - LivingRC_Vol changed from 41 to UNDEF

Hello@all,
I have a Pioneer XC-HM81 Micro-Hifi-System and use the Pioneer AVR binding (binding-pioneeravr - 2.5.2) for controlling it remotely via network. The command set of this system is very limited, but at least it is possible to control power, mute, volume up/down (no numbers, only VU/VD), source selection via telnet.
With the binding i am able to switch the box on/off and un-/mute. But increase/decrease the volume with the binding fails.

This is my current items-configuration which is working for power and mute. It is also possible to receive the actual volume value, but increasing/decreasing volume won’t work.

//items
Switch   XCHM81_Zone1Power                             "Zone1 power"                               {channel="pioneeravr:ipAvrUnsupported:xchm81:zone1#power"}
Switch   XCHM81_Zone1Mute                              "Zone1 mute"                                {channel="pioneeravr:ipAvrUnsupported:xchm81:zone1#mute"}
Number   XCHM81_Zone1VolumeDb                          "Zone1 volume db"                           {channel="pioneeravr:ipAvrUnsupported:xchm81:zone1#volumeDb"}

In my sitemap I tried following configurations

//sitemap
Switch item=XCHM81_Zone1VolumeDb mappings=[ON="Vol+", OFF="Vol-"]
Switch item=XCHM81_Zone1VolumeDb mappings=[INCREASE="Vol+", DECREASE="Vol-"]
Switch item=XCHM81_Zone1VolumeDb mappings=[UP="Vol+", DOWN="Vol-"]
Setpoint item=XCHM81_Zone1VolumeDb step=1 minValue=-80.5 maxValue=0

Following warning messages are thrown in the Log Viewer after the respective vol+/- buttons are pushed in the basic ui:

[WARN ] [rest.core.internal.item.ItemResource] - Received HTTP POST request at 'items/XCHM81_Zone1VolumeDb' with an invalid status value 'ON'.
[WARN ] [rest.core.internal.item.ItemResource] - Received HTTP POST request at 'items/XCHM81_Zone1VolumeDb' with an invalid status value 'OFF'.

[WARN ] [rest.core.internal.item.ItemResource] - Received HTTP POST request at 'items/XCHM81_Zone1VolumeDb' with an invalid status value 'INCREASE'.
[WARN ] [rest.core.internal.item.ItemResource] - Received HTTP POST request at 'items/XCHM81_Zone1VolumeDb' with an invalid status value 'DECREASE'.

[WARN ] [rest.core.internal.item.ItemResource] - Received HTTP POST request at 'items/XCHM81_Zone1VolumeDb' with an invalid status value 'UP'.
[WARN ] [rest.core.internal.item.ItemResource] - Received HTTP POST request at 'items/XCHM81_Zone1VolumeDb' with an invalid status value 'DOWN'.

[nt.ItemStatePredictedEvent] - XCHM81_Zone1VolumeDb predicted to become -53
[vent.ItemStateChangedEvent] - XCHM81_Zone1VolumeDb changed from -54.0 to -53
[vent.ItemStateChangedEvent] - XCHM81_Zone1VolumeDb changed from -53 to -54.0

Is it actually possible to send the VU/VD commands with this binding version and if so, how can I do this?

Thanks!

P.S.: This has already been posted in PioneerAVR 2.0 issues