none
Simulation on Vista 64Bit?

    Question

  •  

    I've been trying to use the RoboChamps first chalenge on my Vista 64bit machine and have had no luck so far. I was told that Simulation does not work in 64bit, is this true?

     

    Mark

    Sunday, April 27, 2008 2:30 AM

Answers

  • XNA supports 64-bit windows by running in 32bit processes in the WOW64.  The problem is that we actually want DSSHost to run in native 64-bit mode when it is running under 64-bit windows (and not running the simulator) so that MSRS applications can run in full 64-bit mode. However, when you attempt to run the simulation engine in a 64-bit DSSHost environment, it tries to load XNA which fails.  This problem is not unique to XNA but common to any service that has a dependency on a 32bit only assembly built as x86.

     

    We could provide 32-bit-only versions of all of the MSRS DLLs along with duplicate manifests so that you can run DSSHost in 32-bit mode on 64-bit windows and it will work with XNA.  However, this doubles the number of DLLs that we need to ship and increases the amount of testing our small team would be required to do before every release.

     

    Anyone have a simpler solution?

     

    -Kyle

     

    Wednesday, April 30, 2008 4:50 AM
  • Would it not be possible to have another assembly compiled as x86 load up the dsshost? That should force the rest of the assemblies to be jit'd to x86 code right?

    what about something like this:

    Code Snippet

    using Microsoft.Dss.Tools.CommandLine;

    public class HostLoader

    {

    static void Main(string[] args)

    {

    Type hostType = Type.GetType("Microsoft.Dss.Hosting.CommandLine.RuntimeHost,DssHost");

    MethodInfo runMethod = hostType.GetMethod("Run",BindingFlags.Public|BindingFlags.Instance);

    PropertyInfo argsProperty = hostType.GetProperty("Args", BindingFlags.Public | BindingFlags.Instance);

    object host = Activator.CreateInstance(hostType,true);

    if(host!=null && Parser.ParseArgumentsWithUsage(args,argsProperty.GetValue(host,null)))

    Environment.Exit((int)runMethod.Invoke(host, null));

    }

    }

     

    Make sure its referencing dsshost.exe and dsscmdargs.dll and built with platform x86... this *should* work, however i am not familar enough with the dss system to know what issues this may (and most likely will) introduce...

    if this will not work, then it seems like #2 is your only alternative if the XNA team has effectively eliminated option 1....

     

    Thanks for jumping in Kyle, I am sure we all appreciate you taking time out of your day to help.

    Wednesday, April 30, 2008 6:59 AM

All replies

  • Hi Mark,

     

    The simulation engine doesn't work on 64 bit machines, due to the use of the XNA framework which doesn't support 64 bit. The rest should work, but that doesn't help you for the RoboChamps.

     

    Erik

     

    Sunday, April 27, 2008 10:46 AM
  •  

    Erik,

     

    Are you sure that's correct? Because I can compie XNA 2.0 code on my 64bit machine by having it compile for x86 instead of "Any Cpu". So from my understanding it was more caused that the simulator was compiled under "Any Cpu" when XNA only supports x86.

     

    Mark

    Sunday, April 27, 2008 6:38 PM
  • You are right, they should be able to run it in 32 bit[2] (but I think they want to use 64 bit on a 64 bit machine), but according to [1] the MRDS team wasn't able to fix it last august, so let's hope in the final 2.0 release it will work.

     

    Maybe some of the MRDS developers could hop in?

     

    Erik

     

    [1] http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=1962684&SiteID=1

    [2] http://blogs.msdn.com/shawnhar/archive/2008/02/25/xna-framework-on-64-bit-windows.aspx

     

    Sunday, April 27, 2008 8:15 PM
  • i am experiencing the same problems here. i think the problem is because the dss* assemblies (ie: dsshost, dssruntime, dssproxy) were compiled with the platform Any CPU which means the will be Jit'd to 64bit code at runtime if in a 64bit environment. these assemblies(some of them) reference the XNA Framework (32bit), which causes it to break when trying to load....
    i tried to use the corflags tool to force the assemblies to run in 32bit (corflags .... /32BIT+ ....) the only issue with that was that the assemblies are signed, and will fail to load after corflags modifies the assembly....

    i dont understand why these tools would be built with their platform set to any cpu if they reference 32bit assemblies???

    i would like to see this resolved...
    Sunday, April 27, 2008 8:43 PM
  • XNA supports 64-bit windows by running in 32bit processes in the WOW64.  The problem is that we actually want DSSHost to run in native 64-bit mode when it is running under 64-bit windows (and not running the simulator) so that MSRS applications can run in full 64-bit mode. However, when you attempt to run the simulation engine in a 64-bit DSSHost environment, it tries to load XNA which fails.  This problem is not unique to XNA but common to any service that has a dependency on a 32bit only assembly built as x86.

     

    We could provide 32-bit-only versions of all of the MSRS DLLs along with duplicate manifests so that you can run DSSHost in 32-bit mode on 64-bit windows and it will work with XNA.  However, this doubles the number of DLLs that we need to ship and increases the amount of testing our small team would be required to do before every release.

     

    Anyone have a simpler solution?

     

    -Kyle

     

    Wednesday, April 30, 2008 4:50 AM
  • Would it not be possible to have another assembly compiled as x86 load up the dsshost? That should force the rest of the assemblies to be jit'd to x86 code right?

    what about something like this:

    Code Snippet

    using Microsoft.Dss.Tools.CommandLine;

    public class HostLoader

    {

    static void Main(string[] args)

    {

    Type hostType = Type.GetType("Microsoft.Dss.Hosting.CommandLine.RuntimeHost,DssHost");

    MethodInfo runMethod = hostType.GetMethod("Run",BindingFlags.Public|BindingFlags.Instance);

    PropertyInfo argsProperty = hostType.GetProperty("Args", BindingFlags.Public | BindingFlags.Instance);

    object host = Activator.CreateInstance(hostType,true);

    if(host!=null && Parser.ParseArgumentsWithUsage(args,argsProperty.GetValue(host,null)))

    Environment.Exit((int)runMethod.Invoke(host, null));

    }

    }

     

    Make sure its referencing dsshost.exe and dsscmdargs.dll and built with platform x86... this *should* work, however i am not familar enough with the dss system to know what issues this may (and most likely will) introduce...

    if this will not work, then it seems like #2 is your only alternative if the XNA team has effectively eliminated option 1....

     

    Thanks for jumping in Kyle, I am sure we all appreciate you taking time out of your day to help.

    Wednesday, April 30, 2008 6:59 AM
  • OMG, it works... i just blew my own mind!!!

     

     

    Wednesday, April 30, 2008 7:11 AM
  •  

    BTW, i moved my loader into the bin folder of msrs, and changed the challenge.cmd file to run

    bin\DssLoader.exe -p:50000 -t:50001 -m:"robochamps\Amazedchallenge\config\AmazedChallenge.manifest.xml"

    that

    Wednesday, April 30, 2008 7:13 AM
  •  

    I just uploaded my loader release version to:

    jakeswenson.com/DssLoader.exe Old link, see new codeplex project http://www.codeplex.com/DSSLoader

     

     

    Make sure you put this in the bin folder of MSRS (the folder with dsshost.exe).

    this will load dsshost.exe, so anywhere dsshost.exe would be used should be replaced with dssloader...

     

    Wednesday, April 30, 2008 7:52 AM
  • Very cool indeed! We will have to see on our end how to make this easy in the next release.

     

    thanks,

     

    Henrik

    Wednesday, April 30, 2008 4:54 PM
  • Thanks for the great solution, Cipherzero!

     

    -Kyle

     

    Wednesday, April 30, 2008 5:34 PM
  • I'm getting the following error message when I kick off DssLoader:

    Could not load file or assembly 'DssCmdArgs, Version=2.0.730.3, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)

     

    I've got MSRS 1.5 installed, did you compile this against an unreleased (2.0) version of the DssCmdArgs.dll assembly??  The version on my dll is 1.5.507.0

     

    Sunday, May 04, 2008 1:06 PM
  • Yes, i referenced the 2.0 CTP release (required for robochamps) version of the dlls (its all i have).... Please check my newest release on codeplex, as this should fix the issue.
    Thanks for reporting this!
    Sunday, May 04, 2008 5:08 PM
  • Sweet, it works!!  Cipher = the man

    Monday, May 05, 2008 4:53 PM
  •  

    Hey Cipher,

     

    I just finished working on a small c# cmd line app that fixes up the default shortcuts that use dsshost to use dssLoader instead. Its meant for people that are installing the 2.0 CTP and want everything to "just work", after installing your dssLoader that is!

     

    The current project is targetted at users of Vista 64bit and the MSRDS 2.0 CTP and MSRS 1.5 RTM products.

    The C# app is about 40kb, .net 2.0 and uses windows shell to modify the shortcuts, and modify the startdssnode.vbs. its all stuff you can do manually but really takes the hassle out of it.

     

    I was thinking of posting the app and source code up on your existing codeplex page. What do you think?

    I was thinking of adding XP 64bit support but wanted to see if people think this will be an app worth posting.

    Im about to dash for the weekend, so reply if you want it uploaded i will create a codeplex account and put it up on Monday.

     

    -LM

     

    Friday, May 16, 2008 7:06 AM
  • Absolutely, i would like to see your code. I could see where this could be a very useful application.
    I've been thinking about adding an installer (just really haven't seen the need for one yet) . This might be the encouragement i need to finally create one. I would be interested in trying to work your code in if you post it.
    So if you feel like sharing it and have time to post it (i am in no rush), i think it could go to good use.

    Thanks!
    Friday, May 16, 2008 8:13 AM
  • Ok i couldn't find a way to upload it as a seperate package (i think you need to be contributor first on the project).

    So i created a workitem issue, and linked it to a patch on your source code page.

    Should be easy to find.

    Monday, May 19, 2008 3:32 AM
  • Thanks Kyle & Cipher your responses helped a lot of people in this situation.
    Monday, May 26, 2008 4:39 PM
  • Dear Cypher,

    Although my knowledge of  robotics and computer vision is reasonably good, I'm a novice with MRDS.  I'm trying to learn it on a computer that runs XP Professional x64.  I greatly appreciate that you figured out how to run MRDS on such a machine.  Thank you for making your fix generally available. 

    In your post, you stated,

    [DssLoadrer.exe] will load dsshost.exe, so anywhere dsshost.exe would be used should be replaced with dssloader.

    How should I go about doing that for, say, one of the tutorials?  VPL Tutorial 1 in MRDS 2008 for example?  A global search and replace (dsshost.exe <--- dssloader.exe) in the files associated with the tutorial? or the manifests associated with the objects?

    Also perhaps related, perhaps not:  what is a .xml.compressed file?  I presume it is just that, a compressed xml file.  How can one uncompress this file to see what is in it?

    Thanks again,

    Alan Peters
    Monday, May 26, 2008 8:24 PM
  • can you please tell me what exactly i have to do after putting dssloader.exe in the bin folder?
    Sunday, October 26, 2008 11:25 PM
  • Well it depends on what you're trying to use this with? the VPL? Visual studio?
    basically what needs to happen is anywhere VPL (for example) refers to the dsshost.exe it needs to be changed to execute the loader.
    so somewhere in the project settings dsshost ( or dss or dsservices) .exe is being executed and that needs to be changed, perhaps if i knew what you were trying to use it with i could be of more help.

    Thanks
    Sunday, October 26, 2008 11:40 PM
  • Hi, with the July CTP, there is no need to use dssloader, as we provide DssHost32 and VplHost32 which are in the correct locations and should allow sim and vpl diagrams that use sim to run on 64-bit.
    Monday, October 27, 2008 2:48 AM
  • Thats Great news, thank you
    Monday, October 27, 2008 3:05 AM
  • Great news .thanks for the MRDS group.

    Unlucky when I begin my first MRDS project ,my XP64 mahine  made me irritated.That time my robotics version is 1.5.

    Monday, October 27, 2008 4:51 AM
  •  Cipherzero wrote:
    Well it depends on what you're trying to use this with? the VPL? Visual studio?
    basically what needs to happen is anywhere VPL (for example) refers to the dsshost.exe it needs to be changed to execute the loader.
    so somewhere in the project settings dsshost ( or dss or dsservices) .exe is being executed and that needs to be changed, perhaps if i knew what you were trying to use it with i could be of more help.

    Thanks

    I'm trying to use VPL. I installed MSRS 2008 and although it seemed everything was going right I received this message:

    "/model219d9a1f-26b1-4ce0-9d38-2b38c208a135trueRunningprogram.activity.Diagramprogram.activity.Start.snippet.elementResponseOutput:Microsoft.Ccr.Core.EmptyValueMicrosoft.Ccr.Core.EmptyValueSimplevaluehttp://localhost/mountpoint/7e143749-0514-424c-bc95-6c0787a6bb8e/DEBUG_program.activity.Start.pngRunningprogram.activity.Diagramprogram.activityTupleTupleStateTypeprogram.JoystickFormService.DesktopJoystickprogram.activity.Start.__use__.subscribehttp://schemas.microsoft.com/xw/2004/10/dssp.html:UpdateRequestMicrosoft.Robotics.Services.GameController.Proxy.UpdateAxesMicrosoft.Robotics.Services.GameController.Proxy.Axeshttp://schemas.microsoft.com/robotics/2006/09/gamecontroller.htmldssp.tcp://goncalo:50001/joystickform/70565483-2dcf-4a89-b0d5-30931bfeec6adssp.tcp://goncalo:50001/joystickform/70565483-2dcf-4a89-b0d5-30931bfeec6a/dss/subscriptionmanager/0e290a88-f1dc-4313-8769-49948cbd178adssp.tcp://goncalo:50001/model/dss/notificationtarget/dc553ef6-067e-48ab-b84c-ddf80560dcbc"

    Please tell me what i have to do to fix this or the other problem with the 1.5 version

    best regards,
    gonber
    Monday, October 27, 2008 2:29 PM
  • It is hard to tell from what you have posted exactly what is going on. Can you explain a little more about what you are tring to do? This message seems to refer to the Direction Dialog (JoystickForm).

     

    VPL and simulation are definitely supported in the July CTP of 2008. I use Vista 64 myself.

     

    Trevor

    Friday, October 31, 2008 5:26 AM
    Owner
  • well since my last post the problem has evolved to something more specific:

     

    for example when i run "Environment with terrain" everything seems to go well on the command line, the dashboard and the microsoft visual simulation environment pop up but this later window just stays all blue and nothing happens. (my graphic board supports directX10) can you put lights on this?

     

    thanks, gonber

     

    Friday, October 31, 2008 10:15 PM
  • The window staying blue is something that has been reported before.

     

    What graphics card do you have? Do you have latest drivers for your graphics card?

     

    Also try switching the view to physics mode and then switching back. We haven't been able to repro this but someone reported that as a solution for them before.

    Friday, October 31, 2008 10:20 PM
  •  Michael Wyrzykowski - MSFT wrote:

    The window staying blue is something that has been reported before.

     

    What graphics card do you have? Do you have latest drivers for your graphics card?

     

    Also try switching the view to physics mode and then switching back. We haven't been able to repro this but someone reported that as a solution for them before.


    NVIDIA GeForce 8600M GT (latest drivers installed)

    In physics render mode the window stays all black and when i put it back to visual mode i see the same blue background

    thanks,
    gonber
    Friday, October 31, 2008 11:35 PM
  • Hard to tell exactly what is going wrong.  It sounds like your graphics card is actually rendering something since the color changes between the visual view and the physics view.  Do any of the other simulation scenes render properly?  Are there any error messages in the CMD window that starts up with the simulation?

     

    Based on the fact that both sim and VPL don't work properly, I would say that there is probably something wrong with your installation.  I suggest that you uninstall your current version and any other versions of MSRDS and then re-install.  Watch closely for any errors that occur.  If the installation proceeds without error and you are still unable to run Sim, I suggest that you manually install the latest DirectX runtime and the latest XNA runtime.

     

    -Kyle

     

     

    Saturday, November 01, 2008 6:56 PM