Notice: This forum has been recovered from an old backup, so some content, links, and dates may be outdated. The forum is currently read-only while we restore sign-in and registration functionality. Details

If you find this forum valuable and would like to help keep it online, donations to help cover hosting and domain costs are greatly appreciated, but never expected. You can support the forum through Buy Me a Coffee or Ko-fi. Thank you for helping preserve the EventGhost community.

Advice for better solution

If you have a question or need help, this is the place to be.
Post Reply
BeerMeMore
Posts: 9
Joined: Sat Jan 03, 2009 6:34 pm

Advice for better solution

Post by BeerMeMore »

XP Pro SP3, EG 0.3.6.1487

PC1=HTPC on port 1 of KVM running SageTV, USB-UIRT direct attached
PC2=Sandbox on port 2 of KVM
Gyration keyboard and remote/air mouse dongle attached to KVM USB port and swapped with KVM transfer.

Issue: Gyration device is accessed through HID plugin. Current config (listed below) works well on startup. KVM swap seems to cause mis-alignment when Gyration USB triggers System.DeviceAttached on hot swap. Restarting EG seems to resolve.

Brute Force Solution: Not elegant, but it works. On System.DeviceAttached event find EG and close application. Use AppMonitor to perform automatic restart of EG.

Given the simple script at this stage of my efforts, the restart is not noticible. However I expect to introduce more to EG and expect that this approach will ultimately be unacceptable. I would appreciate any alternative or oher creative suggestions for a better approach.

Code: Select all

  <?xml version="1.0" encoding="UTF-8" ?> 
- <EventGhost Name="Configuration Tree" Expanded="True" Version="1487" Guid="{F988542A-8C3E-4460-8A5A-18EE0B6A1185}" Time="1231199594.1">
- <Autostart Name="Autostart" Expanded="True">
  <Plugin File="Serial" Identifier="Serial">gAIoSwBNgCVLA0sASwBLAIhYAgAAAFxycQBYBgAAAFNlcmlhbHEBdHECLg==</Plugin> 
  <Plugin File="USB-UIRT" Identifier="USB_UIRT">gAKIiIiHcQAu</Plugin> 
  <Plugin File="HID" Identifier="HID">gAIoWAUAAABGaXJzdHEAiImIVV1cXD9caGlkI3ZpZF8wYzE2JnBpZF8wMDAyJm1pXzAwJmNvbDAyIzgmZDlkY2E0NSYwJjAwMDEjezRkMWU1NWIyLWYxNmYtMTFjZi04OGNiLTAwMTExMTAwMDAzMH1xAU0WDFgIAAAAR3lyYXRpb25xAksCWB8AAABHeXJhdGlvbiBSRiBUZWNobm9sb2d5IFJlY2VpdmVycQNNIAKJdHEELg==</Plugin> 
  <Plugin File="HID" Identifier="HID2">gAIoWAYAAABTZWNvbmRxAIiJiFVdXFw/XGhpZCN2aWRfMGMxNiZwaWRfMDAwMiZtaV8wMCZjb2wwMyM4JmQ5ZGNhNDUmMCYwMDAyI3s0ZDFlNTViMi1mMTZmLTExY2YtODhjYi0wMDExMTEwMDAwMzB9cQFNFgxYCAAAAEd5cmF0aW9ucQJLAlgfAAAAR3lyYXRpb24gUkYgVGVjaG5vbG9neSBSZWNlaXZlcnEDTSACiXRxBC4=</Plugin> 
  <Plugin File="HID" Identifier="HID3">gAIoWAUAAABUaGlyZHEAiImIVV1cXD9caGlkI3ZpZF8wYzE2JnBpZF8wMDAyJm1pXzAwJmNvbDA0IzgmZDlkY2E0NSYwJjAwMDMjezRkMWU1NWIyLWYxNmYtMTFjZi04OGNiLTAwMTExMTAwMDAzMH1xAU0WDFgIAAAAR3lyYXRpb25xAksCWB8AAABHeXJhdGlvbiBSRiBUZWNobm9sb2d5IFJlY2VpdmVycQNNIAKJdHEELg==</Plugin> 
  <Plugin File="HID" Identifier="HID4">gAIoWAAAAABxAIiJiFVeXFw/XGhpZCN2aWRfMGMxNiZwaWRfMDAwMiZtaV8wMSZjb2wwMiM4JjMxNzUwODA3JjAmMDAwMSN7NGQxZTU1YjItZjE2Zi0xMWNmLTg4Y2ItMDAxMTExMDAwMDMwfXEBTRYMWAgAAABHeXJhdGlvbnECSwJYHwAAAEd5cmF0aW9uIFJGIFRlY2hub2xvZ3kgUmVjZWl2ZXJxA00gAol0cQQu</Plugin> 
  <Plugin File="HID" Identifier="HID5">gAIoWAUAAABGaWZ0aHEAiImIVV5cXD9caGlkI3ZpZF8wYzE2JnBpZF8wMDAyJm1pXzAxJmNvbDAzIzgmMzE3NTA4MDcmMCYwMDAyI3s0ZDFlNTViMi1mMTZmLTExY2YtODhjYi0wMDExMTEwMDAwMzB9cQFNFgxYCAAAAEd5cmF0aW9ucQJLAlgfAAAAR3lyYXRpb24gUkYgVGVjaG5vbG9neSBSZWNlaXZlcnEDTSACiXRxBC4=</Plugin> 
  </Autostart>
- <Folder Name="HTPC" Expanded="True">
- <Folder Name="Equipment Power" Expanded="True">
- <Macro Name="Power Down" id="12" Expanded="True">
  <Event Name="Fifth.Button.1" /> 
  <Action>EventGhost.DisableItem(XmlIdLink(12))</Action> 
  <Action>EventGhost.EnableItem(XmlIdLink(19))</Action> 
  <Action>Serial.Write(u'\x02POF\x03')</Action> 
  <Action Name="DenPower">USB_UIRT.TransmitIR(u'0000 006F 0000 0020 000A 001E 000A 0045 000A 001E 000A 001E 000A 001E 000A 0045 000A 001E 000A 001E 000A 001E 000A 001E 000A 001E 000A 0045 000A 0045 000A 001E 000A 001E 000A 06E5 000A 001E 000A 0045 000A 001E 000A 001E 000A 001E 000A 001E 000A 0045 000A 0045 000A 0045 000A 0045 000A 0045 000A 001E 000A 001E 000A 0045 000A 0045 000A 063C', 4, 0)</Action> 
  <Action>EventGhost.StopProcessing()</Action> 
  </Macro>
- <Macro Name="Power Up" id="19" Enabled="False" Expanded="True">
  <Event Name="Fifth.Button.1" /> 
  <Action>EventGhost.DisableItem(XmlIdLink(19))</Action> 
  <Action>EventGhost.EnableItem(XmlIdLink(12))</Action> 
  <Action>Serial.Write(u'\x02PON\x03')</Action> 
  <Action Name="DenPower">USB_UIRT.TransmitIR(u'0000 006F 0000 0020 000A 001E 000A 0045 000A 001E 000A 001E 000A 001E 000A 0045 000A 001E 000A 001E 000A 001E 000A 001E 000A 001E 000A 0045 000A 0045 000A 001E 000A 001E 000A 06E5 000A 001E 000A 0045 000A 001E 000A 001E 000A 001E 000A 001E 000A 0045 000A 0045 000A 0045 000A 0045 000A 0045 000A 001E 000A 001E 000A 0045 000A 0045 000A 063C', 4, 0)</Action> 
  <Action>EventGhost.StopProcessing()</Action> 
  </Macro>
  </Folder>
- <Folder Name="External Vol (SPDIF)" Expanded="True">
- <Macro Name="Volume Up" Expanded="True">
  <Event Name="First.Button.233" /> 
  <Action Name="DenVolUp">USB_UIRT.TransmitIR(u'0000 006F 0000 0020 000A 001E 000A 0045 000A 001E 000A 001E 000A 001E 000A 0045 000A 001E 000A 001E 000A 001E 000A 0045 000A 0045 000A 0045 000A 0045 000A 001E 000A 001E 000A 0696 000A 001E 000A 0045 000A 001E 000A 001E 000A 001E 000A 001E 000A 0045 000A 0045 000A 0045 000A 001E 000A 001E 000A 001E 000A 001E 000A 0045 000A 0045 000A 068B', 4, 0)</Action> 
  <Action Name="DenVolUp">USB_UIRT.TransmitIR(u'0000 006F 0000 0020 000A 001E 000A 0045 000A 001E 000A 001E 000A 001E 000A 0045 000A 001E 000A 001E 000A 001E 000A 0045 000A 0045 000A 0045 000A 0045 000A 001E 000A 001E 000A 0696 000A 001E 000A 0045 000A 001E 000A 001E 000A 001E 000A 001E 000A 0045 000A 0045 000A 0045 000A 001E 000A 001E 000A 001E 000A 001E 000A 0045 000A 0045 000A 068B', 4, 0)</Action> 
  <Action>EventGhost.StopProcessing()</Action> 
  </Macro>
- <Macro Name="Volume Down" Expanded="True">
  <Event Name="First.Button.234" /> 
  <Action Name="DenVolDn">USB_UIRT.TransmitIR(u'0000 006E 0000 0020 000A 001E 000A 0046 000A 001E 000A 001E 000A 001E 000A 001E 000A 0046 000A 001E 000A 001E 000A 0046 000A 0046 000A 0046 000A 0046 000A 001E 000A 001E 000A 06B0 000A 001E 000A 0046 000A 001E 000A 001E 000A 001E 000A 0046 000A 001E 000A 0046 000A 0046 000A 001E 000A 001E 000A 001E 000A 001E 000A 0046 000A 0046 000A 06A3', 4, 0)</Action> 
  <Action Name="DenVolDn">USB_UIRT.TransmitIR(u'0000 006E 0000 0020 000A 001E 000A 0046 000A 001E 000A 001E 000A 001E 000A 001E 000A 0046 000A 001E 000A 001E 000A 0046 000A 0046 000A 0046 000A 0046 000A 001E 000A 001E 000A 06B0 000A 001E 000A 0046 000A 001E 000A 001E 000A 001E 000A 0046 000A 001E 000A 0046 000A 0046 000A 001E 000A 001E 000A 001E 000A 001E 000A 0046 000A 0046 000A 06A3', 4, 0)</Action> 
  <Action>EventGhost.StopProcessing()</Action> 
  </Macro>
  </Folder>
- <Folder Name="Swap Computers" Expanded="True">
- <Macro Name="Close on KVM swap back" Expanded="True">
  <Event Name="System.DeviceAttached" /> 
  <Action>Window.FindWindow(u'EventGhost.exe', None, None, None, None, None, True, 0.0, 0)</Action> 
  <Action>Window.Close()</Action> 
  </Macro>
- <Macro Name="Swap to other PC" Expanded="True">
  <Event Name="HID.Button.554" /> 
  <Action>Window.SendKeys(u'{Scrolllock}{Scrolllock}', False)</Action> 
  <Action>EventGhost.StopProcessing()</Action> 
  </Macro>
  </Folder>
  </Folder>
  </EventGhost>
Post Reply