Firstly, I love Eventghost. Secondly, I love the forum. Thirdly, Someone asked how to generate an event based on, a state of the Yamaha processor. While this probably isn't the most efficient way, it is probably the easiest to follow

. I have attached the code and a screenshot of it.
I have both Denon and Yamaha receivers. The Denons return events. The Yamaha doesn't. But this plugin DOES bury the result of the GET query in "eg.result". So with some iffing, you can mimic an event by testing the receiver state to a known condition, and jump appropriately.
In my case, I have a whole house audio with multiple receivers. (In hindsight, this is the best way to do it I think; I ended up here by being cheap and on accident sort of; I spent less on my whole system than on a typical whole house receiver). I wanted to ability to, when listening to the whole house, implement a toggle of the master bedroom AVR if there was not a desire for music in there. I also have a similar routine to toggle one of my Denon's Zone 2 to flip state of the Lanai speakers (which is much easier to just use events for, but I digress). Although I have local volume knobs, it seemed like the functionality may be necessary at some point. So with this forum's help, I managed to scrap this together

. Just thought I'd share to show my true thanks.
PS, the mceremote command is a dummy command on my Logitech. I don't adjust the computer MCE volume; I adjust my living room AVR volume via direct IR via the Logitech.
PS, if you have more than one Denon receiver (I have an X2000 and X4000) you can also just copy/rename the plugin and rename some key variables within the code via find/replace and defeat the single "Marantz" limitation.
Code: Select all
<?xml version="1.0" encoding="UTF-8" ?>
<EventGhost Version="1669">
<Folder Name="BED-RXV475 (BED AVR) POWER TOGGLE" Expanded="True">
<Macro Name="Yamaha: POWER TOGGLE BUFFER" id="426" Expanded="True">
<Event Name="MceRemote.Mce.VolumeUp" />
<Action>
EventGhost.EnableItem(XmlIdLink(432))
</Action>
<Action>
EventGhost.EnableItem(XmlIdLink(436))
</Action>
<Action>
YamahaRX.Get Info('Power', 'Main Zone')
</Action>
<Action>
EventGhost.PythonCommand(u'print eg.result')
</Action>
<Action Name='eg.result == " Standby"'>
EventGhost.PythonCommand(u'eg.result == "Standby"')
</Action>
<Action>
EventGhost.PythonCommand(u'print eg.result')
</Action>
<Action>
EventGhost.NewJumpIf(XmlIdLink(432), 0, False)
</Action>
<Action>
EventGhost.NewJumpIf(XmlIdLink(436), 1, False)
</Action>
</Macro>
<Macro Name="Yamaha: POWER TOGGLE - IF OFF, TURN ON" id="432" Enabled="False" Expanded="True">
<Action>
EventGhost.EnableExclusive(XmlIdLink(426))
</Action>
<Action>
YamahaRX.Set Power Status('Main Zone', 'On')
</Action>
</Macro>
<Macro Name="Yamaha: POWER TOGGLE - IF ON, TURN OFF" id="436" Enabled="False" Expanded="True">
<Action>
EventGhost.EnableExclusive(XmlIdLink(426))
</Action>
<Action>
YamahaRX.Set Power Status('Active Zone', 'Standby')
</Action>
</Macro>
</Folder>
</EventGhost>