Go Down

Topic: Launch4j error - IDE won't start - Please HELP!! (Read 8377 times) previous topic - next topic

UMTS

Hi,

I have recently installed Arduino 1 IDE and have encountered a problem that is now preventing this and any previous versions (0022 and 0018) for example from starting.

What happens is you launch the IDE and the splash screen appears instantly and remains on the screen for some considerable time (approx 40 seconds).

The splash screen then disappears and is replaced by a dialogue box 'Launch4j' saying "An error occurred while starting the application." and the only option os to click 'OK'. - attached

All was working fine up till about 2 weeks ago and I have trawled high an low across the web to see if there is a fix, but nothing has corrected this.

Please can anyone help, as I'm totally stuck and desperately want to move on developing with this fantastic platform.

ps. I'm running Windows 7 64 bit SP1 on a i5 3.20GHz with 8GB of RAM if it helps.

Many Thanks

Steve>>>

johnwasser

Make sure you have the latest Java installation.
Send Bitcoin tips to: 1L3CTDoTgrXNA5WyF77uWqt4gUdye9mezN
Send Litecoin tips to : LVtpaq6JgJAZwvnVq3ftVeHafWkcpmuR1e

Louis Davis

#2
Mar 04, 2012, 07:47 pm Last Edit: Mar 04, 2012, 07:55 pm by Louis Davis Reason: 1
Another experiment to try is to delete your preferences.text file that can be found in the following location, depending on what version of Windows you have.

c:\Documents and Settings\<USERNAME>\Application Data\Arduino\preferences.txt (Windows XP)
c:\Users\<USERNAME>\AppData\Roaming\Arduino\preferences.txt (Windows Vista\Windows 7)

There has been some indication that a corrupt preferences.txt file can prevent the IDE from launching.

If that does not work, from a command line, launch arduino.exe with the following command:

arduino.exe --l4j-debug

Then send us the launch4j.log file in the Arduino folder to see if that tells us anything.

UMTS

Hi,

Thanks John and Louis for your quick help.

Louis - your were spot on - deleting the preferences.txt worked a treat.


THANKYOU BOTH VERY MUCH - REALLY APPRECIATED!!!

Best Regards

Steve....

mike1948

I am having the same problem.

I deleted the preferences.txt file but it had no effect.

I ran the launch4j with the debug turned on, following is the log file contents.

---------------------------------------------------------

CmdLine:   C:\Users\Mike\Downloads\arduino-1.0-windows\arduino-1.0\arduino.exe --l4j-debug
WOW64:      no
Working dir:   C:\Users\Mike\Downloads\arduino-1.0-windows\arduino-1.0\.
Bundled JRE:   java
Check launcher:   C:\Users\Mike\Downloads\arduino-1.0-windows\arduino-1.0\java\bin\javaw.exe (OK)
Add classpath:   lib\pde.jar
Add classpath:   lib\core.jar
Add classpath:   lib\jna.jar
Add classpath:   lib\ecj.jar
Add classpath:   lib\RXTXcomm.jar
Launcher:   C:\Users\Mike\Downloads\arduino-1.0-windows\arduino-1.0\java\bin\javaw.exe
Launcher args:   -Xms128m -Xmx128m -classpath "lib;C:\Users\Mike\Downloads\arduino-1.0-windows\arduino-1.0\java\lib\tools.jar;lib\pde.jar;lib\core.jar;lib\jna.jar;lib\ecj.jar;lib\RXTXcomm.jar" processing.app.Base
Args length:   195/32768 chars
Exit code:   1
--------------------------------------------------------------------------------------------------

Does this give you any clues?


Thanks for any help you can provide.

Mike



Louis Davis

Are you able to launch the IDE by entering the following command from a command line?

C:\Users\Mike\Downloads\arduino-1.0-windows\arduino-1.0\java\bin\javaw.exe -Xms128m -Xmx128m -classpath "lib;C:\Users\Mike\Downloads\arduino-1.0-windows\arduino-1.0\java\lib\tools.jar;lib\pde.jar;lib\core.jar;lib\jna.jar;lib\ecj.jar;lib\RXTXcomm.jar" processing.app.Base

If not, use the following command and reply with the output.txt file that is created:

C:\Users\Mike\Downloads\arduino-1.0-windows\arduino-1.0\java\bin\java.exe -verbose -Xms128m -Xmx128m -classpath "lib;C:\Users\Mike\Downloads\arduino-1.0-windows\arduino-1.0\java\lib\tools.jar;lib\pde.jar;lib\core.jar;lib\jna.jar;lib\ecj.jar;lib\RXTXcomm.jar" processing.app.Base > output.txt

mike1948

I tried to enter the first command as you suggested but I could not get an IDE.
I tried the second command and a window came up with data but it closed as soon as it opened.
I could not capture the contents.
I am using "Run" from the accessories folder and it will not take the whole command, it leaves out the "processing.app.Base>output.txt" portion.
I tried using the command prompt and typing in the whole second command but nothing happened at all.
Where would I expect to find the output.txt file?
Is there a way of capturing the window that pops up?

I am new at this.
Thanks for your help.
Mike

Louis Davis

You should be entering these commands from a command prompt.
The output.txt will be in the folder that you executed the command from.

The > output.txt at the end of the command will redirect all the output to this file rather than to the screen. This will make it easier to capture the output and post it here.

If you want to see if the command is executing anything, you can run the second command and leave off the > output.txt. You should see quite a bit of information show up in the command window.

mike1948

I did as you suggested and got an output file which I have attached.
Its quite big at 31K bytes.

Hope this helps.

Thanks again.

Mike

Louis Davis

Unfortunately, the output.txt file does not indicate the problem.
The output.txt shows that java just stops loading the application fairly early in the loading process, but does not show any errors.

As an example, my output.txt on my system is about 169K.

Did this ever work on your system? If so, what types of things have you done to the system before it stopped working?
Software installs? Driver installs? Windows updates? Etc...

mike1948

The program did work on this system several months ago but all sorts of window updates and such have occurred since then. 
Do I need to be administrator to run this program?
Do I need to load the latest java updates?
Is there another way of invoking the executable? Batch?

Thanks again

Louis Davis


Do I need to be administrator to run this program?

No you don't need to be an admin to run it, but that would be an interesting experiment.

Quote

Do I need to load the latest java updates?

Normally this is not required, because the IDE contains it's own copy of the Java runtime. It may be worth a try to see if this changes anything.

Quote

Is there another way of invoking the executable? Batch?

You have already tried the only alternative way to invoke the IDE.  The arduino.exe is just a wrapper to launch the Arduino IDE, which is a Java application. By executing that long command line I had you run for debug purposes, you were basically doing what the arduino.exe was doing.

So, try running as admin first, to see if this changes the behavior.
Then trying updating Java.

mike1948

I ran as administrator and the IDE loaded up.
I ran a sketch and it compiled it.

Thanks Louis for all your help.

Mike

Luse

I.m sorry if this is such a noob question but i got my first arduino uno got the drivers to work and my laptop (running windows 7 ultimate) can see the arduino but i downloaded the arduino-1.0-windows ide and i cannot get it to start, all i get is a splash screen for a few seconds and thats it. i have no idea what to do next i dont even get any error messages i've even tried running as administrator but same thing any info or help pointing me in  the right direction would be greatly appreciated thank you all who take the time to respond,
           Sincerly Richard

Go Up