Getting HardwareSimulator.bat to run on Win8 - flashing of black screen (solved)

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

Getting HardwareSimulator.bat to run on Win8 - flashing of black screen (solved)

Phil
Hello,

when i double click on the HardwareSimulator.bat win8 starts up the console and
shuts it after one second.
It took me a couple of minutes to get the HardwareSimulator.bat running.

1) Download Java Runtime Environment
2) Set your "path" variable to the path you installed your java.exe (eg. C:\Program Files (x86)\Java\jre7\bin)
  (how to set "path"-variable: http://java-buddy.blogspot.de/2012/01/set-path-for-jdk-7-on-windows-8.html )
3) run HardwareSimulator.bat as administrator.
4) enjoy

greetings,
Phil
Reply | Threaded
Open this post in threaded view
|

Re: Getting HardwareSimulator.bat to run on Win8 - flashing of black screen (solved)

Scope87
Thank you for this! For anyone wondering .... Yes it works on Windows 7!  Thanks Phil ... I spent an hour working on this before I found your help!!

$cope
Reply | Threaded
Open this post in threaded view
|

Re: Getting HardwareSimulator.bat to run on Win8 - flashing of black screen (solved)

mcdon.ron
you don't need to add java to your path environment.  if you're using a 64 bit machine install the x64 version of the java runtime.  There will then be a java.exe in your system32.

on windows x64 you technically have two system32 folders, one used by x86 apps, the other by x64 apps.  strangely enough the system32 folder on windows x64 is still named system32, not system64 :).
Reply | Threaded
Open this post in threaded view
|

Re: Getting HardwareSimulator.bat to run on Win8 - flashing of black screen (solved)

mcdon.ron
a tip for HardwareSimulator.bat
when i run the bat file there is a console window that stays open while the hardware simulator is runing.  you can get rid of this console window by using javaw.exe instead of java.exe.  next you can use start javaw to run java in a seperate process, allowing the current process (HardwareSimulator.bat) to exit.

my final HardwareSimulator.bat looks like

@echo off
cd %0\..
start javaw -classpath "%CLASSPATH%;.;bin/classes;bin/lib/Hack.jar;bin/lib/HackGUI.jar;bin/lib/Simulators.jar;bin/lib/SimulatorsGUI.jar;bin/lib/Compilers.jar" HardwareSimulatorMain %1