A couple commands not working

Oct 30, 2009 at 8:29 PM

I am running windows 7 64bit, and most of the commands work fine. However, it seems none of the button or number commands work ie:

button-up
button-down
button-num-4
button-num-5

Any thoughts?

Developer
Oct 31, 2009 at 2:02 PM

I'm working on this issue. the problem is known and caused by x64. i hope to get a new version online in the next few days. pretty short on time at the moment.

Nov 7, 2009 at 1:45 PM
Edited Nov 7, 2009 at 1:46 PM

Any update getting the buttons working?

Developer
Nov 7, 2009 at 1:53 PM

currently working on it. hope to get it done today. at least for Win 7 x64.

Nov 7, 2009 at 2:34 PM

Thank you so much.  Will the play, stop, pause, fw, rw, buttons work for videos too?

Nov 13, 2009 at 3:33 PM

Any update for the win7 x64 fixes?

Developer
Nov 21, 2009 at 7:27 PM

sorry dude. i'm still not ready to release it. pretty short on time at the moment. :( the video commands should work too, if the general problem is fixed. but not tested yet with video.

Nov 22, 2009 at 7:01 PM

So getting pretty desperate on the x64 stuff. The problem appears to be with the SendInput native function on x64 (see this thread: http://discuss.mediacentersandbox.com/forums/thread/9364.aspx). When complied as x86, the function works, but the add-in fails to initialize. So it appears we must make it work on x64. Any tips greatly appreciated...

Nov 22, 2009 at 7:37 PM

OK, success (at lest, for the buttons that weren't working like up, down, etc). Two things are necessary:

First, the project has to be set to target x64. This is accomplished by adding the following XML to the first four PropertyGroup elements in the VmcController.Add-In.csproj xml file (for VC# express, at least, which is what I use):

<PlatformTarget>x64</PlatformTarget>

Then, in the file SendKeyCmd.cs, the following:

[StructLayout(LayoutKind.Sequential)]

public struct KEYBDINPUT

{

public ushort wVk;

public ushort wScan;

public uint dwFlags;

public uint time;

public IntPtr dwExtraInfo;

};

[StructLayout(LayoutKind.Explicit, Size = 28)]

public struct INPUT

{

[FieldOffset(0)]

public uint type;

[FieldOffset(4)]

public KEYBDINPUT ki;

};

Needs to be replaced with:

<font size="2">

[

</font>

StructLayout(LayoutKind.Sequential)]<font size="2">

 

</font>

public struct KEYBDINPUT

{

<font size="2">

 

</font>

public ushort wVk;<font size="2">

 

</font>

public ushort wScan;<font size="2">

 

</font>

public uint dwFlags;<font size="2">

 

</font>

public uint time;<font size="2">

 

</font>

public IntPtr dwExtraInfo;

};

<font size="2">

[

</font>

StructLayout(LayoutKind.Sequential)]<font size="2">

 

</font>

public struct MOUSEINPUT

{

<font size="2">

 

</font>

public int dx;<font size="2">

 

</font>

public int dy;<font size="2">

 

</font>

public uint mouseData;<font size="2">

 

</font>

public uint dwFlags;<font size="2">

 

</font>

public uint time;<font size="2">

 

</font>

public IntPtr dwExtraInfo;

}

 

<font size="2">

[

</font>

StructLayout(LayoutKind.Explicit)]<font size="2">

 

</font>

public struct INPUT

{

<font size="2">

[

</font>

FieldOffset(0)]<font size="2">

 

</font>

public uint type;<font size="2">

[

</font>

FieldOffset(8)]<font size="2">

 

</font>

public MOUSEINPUT mi;<font size="2">

[

</font>

FieldOffset(8)]<font size="2">

 

</font>

public KEYBDINPUT ki;

};

That did the trick (for me at least). Hopefully these changes can be incorporated in the next x64 build package (along with the Announce command, pretty please!)

-James

Developer
Dec 6, 2009 at 5:39 PM

i just updated the Win 7 alpha release. commands should be working now on x86 and x64. code in repository will be updated shortly. please give it a try.

Dec 7, 2009 at 12:35 AM

I tired uninstalling the old version, and installing the new version.  Now MC gives me an error when i start: VMC controller has stopped working, press ok to return to media center.

Developer
Dec 7, 2009 at 7:30 AM

are you on x86 or x64? can you please take a look in the "event viewer > applications and services logs > media center" if there is a error message? i tested the installer on x86 and x64 and it worked fine.

Dec 8, 2009 at 11:34 PM

Here's the error from my logs

Exception System.Security.SecurityException: The source was not found, but some or all event logs could not be searched. Inaccessible logs: Security.

 

Server stack trace:

at System.Diagnostics.EventLog.FindSourceRegistration(String source, String machineName, Boolean readOnly)

at System.Diagnostics.EventLog.SourceExists(String source, String machineName)

at System.Diagnostics.EventLog.VerifyAndCreateSource(String sourceName, String currentMachineName)

at System.Diagnostics.EventLog.WriteEntry(String message, EventLogEntryType type, Int32 eventID, Int16 category, Byte[] rawData)

at System.Diagnostics.EventLog.WriteEntry(String source, String message, EventLogEntryType type, Int32 eventID, Int16 category, Byte[] rawData)

at System.Diagnostics.EventLog.WriteEntry(String source, String message, EventLogEntryType type)

at VmcController.AddIn.AddInModule.Launch(AddInHost host)

at MediaCenter.Extensibility.AddInEntryPointWrapper.Launch(AddInHost host)

at System.Runtime.Remoting.Messaging.Message.Dispatch(Object target, Boolean fExecuteInContext)

at System.Runtime.Remoting.Messaging.StackBuilderSink.SyncProcessMessage(IMessage msg, Int32 methodPtr, Boolean fExecuteInContext)

Exception rethrown at [0]:

at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg)

at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type)

at MediaCenter.Extensibility.AddInEntryPointWrapper.Launch(AddInHost host)

at System.Runtime.Remoting.Messaging.StackBuilderSink._PrivateProcessMessage(IntPtr md, Object[] args, Object server, Int32 methodPtr, Boolean fExecuteInContext, Object[]& outArgs)

at System.Runtime.Remoting.Messaging.StackBuilderSink.SyncProcessMessage(IMessage msg, Int32 methodPtr, Boolean fExecuteInContext)

Exception rethrown at [1]:

at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg)

at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type)

at MediaCenter.Extensibility.ExtensibilityPlugInEntryPointInfo.ExtensibilityPlugInLaunchInfo.AddInModalLauncher.AddInLaunchDelegate.EndInvoke(IAsyncResult result)

at MediaCenter.Extensibility.ExtensibilityPlugInEntryPointInfo.ExtensibilityPlugInLaunchInfo.AddInModalLauncher.LaunchComplete(IAsyncResult result)

Developer
Dec 10, 2009 at 8:35 AM

Never seen this error before. looks like a log can't be accessed. are you using x32 or x64? i'll take a look an will update the installer if i find something.

Dec 10, 2009 at 1:18 PM

win7 x64

Developer
Dec 10, 2009 at 4:37 PM

just updated the installer. please remove the plugin from control panel > uninstall a program. the install it again with the new installer. i packaged the previous installer with my dev version that uses the event log for tracing. have to investigate why this isn't running on every box. kind of permission problem i guess. please report back if you issue is solved.

Dec 10, 2009 at 5:05 PM

Yup, it fixed the error. I noticed the button-rec ie the record button does not work.  Is this part of the EPG commands?

Developer
Dec 10, 2009 at 5:10 PM

it is. and everything related to EPG/TV isn't working at the moment on WIn 7. as i wrote in another thread i'll try to fix the EPG/TV stuff soon. so i hope. great that it is working for you now.