This is how I do it...lja wrote:I have a Yamaha RX-V 3900. I have turned on Network Standby and can get the receiver to turn on and off. However I have been unable to get the increase volume and decrease volume to work. Can anyone share their setup to help? Thanks.
Copy and paste this in Eventghost:
Code: Select all
<?xml version="1.0" encoding="UTF-8" ?>
<EventGhost Version="1640">
<Folder Name="Volume Macro" Expanded="True">
<Macro Name="On Volume Up Start" Expanded="True">
<Event Name="Keyboard.F12" />
<Action>
EventGhost.PythonCommand(u'myLastVolumeEvent = eg.event')
</Action>
<Action>
YamahaRX.Increase Volume('Active Zone', 0.5)
</Action>
<Action>
EventGhost.NewJumpIf(XmlIdLink(675), 2, True)
</Action>
<Action>
EventGhost.TriggerEvent(u'VolumeUpRepeat', 0.5)
</Action>
</Macro>
<Macro Name="On VolumeUp Repeat" Expanded="True">
<Event Name="Main.VolumeUpRepeat" />
<Action>
EventGhost.PythonCommand(u'if myLastVolumeEvent.isEnded: eg.StopMacro()')
</Action>
<Action>
YamahaRX.Smart Volume Up('Active Zone', 1.0, 2.0, 1.0)
</Action>
<Action>
EventGhost.NewJumpIf(XmlIdLink(675), 2, True)
</Action>
<Action>
EventGhost.TriggerEvent(u'VolumeUpRepeat', 0.050000000000000003)
</Action>
</Macro>
<Macro Name="On Volume Down Start" Expanded="True">
<Event Name="Keyboard.F11" />
<Action>
EventGhost.PythonCommand(u'myLastVolumeEvent2 = eg.event')
</Action>
<Action>
YamahaRX.Decrease Volume('Active Zone', 0.5)
</Action>
<Action>
EventGhost.NewJumpIf(XmlIdLink(675), 2, True)
</Action>
<Action>
EventGhost.TriggerEvent(u'VolumeDownRepeat', 0.5)
</Action>
</Macro>
<Macro Name="On Volume Down Repeat" Expanded="True">
<Event Name="Main.VolumeDownRepeat" />
<Action>
EventGhost.PythonCommand(u'if myLastVolumeEvent2.isEnded: eg.StopMacro()')
</Action>
<Action>
YamahaRX.Smart Volume Down('Active Zone', 2.0, 4.0, 1.0)
</Action>
<Action>
EventGhost.NewJumpIf(XmlIdLink(675), 2, True)
</Action>
<Action>
EventGhost.TriggerEvent(u'VolumeDownRepeat', 0.050000000000000003)
</Action>
</Macro>
<Macro Name="Yamaha RX-V Network Receiver: Get Info: Power" id="675" Expanded="True">
<Action>
YamahaRX.Get Info('Volume Level', 'Main Zone')
</Action>
<Action>
EventGhost.PythonScript(u'#print eg.result\n\n#print eg.result[1: 5]\n\neg.globals.volume = eg.result')
</Action>
<Action>
EventGhost.ShowOSD(u'Volume: {eg.globals.volume}\n', u'0;-21;0;0;0;700;0;0;0;0;3;2;1;49;Lucida Console', (255, 255, 0), None, 6, (0, 10), 0, 3.0, True)
</Action>
</Macro>
</Folder>
</EventGhost>