Pages: 1 ... 4 5 [6] 7 8 ... 30   Go Down
Author Topic: Windows/Linux/Mac Eclipse plugin to compile and upload arduino sketches  (Read 82363 times)
0 Members and 2 Guests are viewing this topic.
Offline Offline
Newbie
*
Karma: 0
Posts: 7
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hi Jantje,

I am using separate WorkSpaces for Arduino 1.0 and Arduino 022.   After setting up the two WorkSpaces, I do not change the Preferences of where the Arduino software is located. 

brownerthanu is correct in that setting the Personal Library seems to resolve the issue.  In your video, you are setting the Personal Library setting as a demonstration.  Since I do not have a Personal Library, I left that box blank.   If I point it to any valid folder, as brownerthanu did, then it works fine. 

Here are the steps to reproduce.

1.  Create a new workspace and set the preference to any version of Arduino.  However, do not touch the box for the Personal Library. 
2.  Create a new Arduino Project in this workspace, select your favorite board and click finish.  It will throw the error I posted previously.
3.  Delete the failed Core Project and the failed user project.
4.  Return to the Preferences and set the Personal Library parameter to any valid folder on the computer.
5.  Repeat step 2 and it will work fine.

I will attach the Eclipse error log from one of the failures.  Perhaps that will give some additional clues. 

* error.log (85.89 KB - downloaded 5 times.)
Logged

Belgium
Offline Offline
Edison Member
*
Karma: 58
Posts: 1742
Arduino rocks; but with my plugin it can fly rocking the world ;-)
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Great that you found the issue.
This defect exists since 1.2. I fixed it and it will be part of the next release. As there is a workaround which I would describe as "do as you should do" smiley-cool there is no hurry.
Best regards
Jantje
Logged

Do not PM me a question unless you are prepared to pay for consultancy.
Nederlandse sectie - http://arduino.cc/forum/index.php/board,77.0.html -

Offline Offline
Newbie
*
Karma: 0
Posts: 18
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hi Jantje,

Thanks so much for your help. Here's what I see:



As you can see, there is no Arduino subfolder. However, all other aspects of 1.2.2 seem to be working.
Logged

Belgium
Offline Offline
Edison Member
*
Karma: 58
Posts: 1742
Arduino rocks; but with my plugin it can fly rocking the world ;-)
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

brownerthanu
Can you send me the content of the error log view (same window as you posted->general->error log)
Best regards
Jantje
Logged

Do not PM me a question unless you are prepared to pay for consultancy.
Nederlandse sectie - http://arduino.cc/forum/index.php/board,77.0.html -

Offline Offline
Newbie
*
Karma: 0
Posts: 18
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hi Jantje,

Here is the error message:

Code:
eclipse.buildId=M20120208-0800
java.version=1.6.0_31
java.vendor=Apple Inc.
BootLoader constants: OS=macosx, ARCH=x86_64, WS=cocoa, NL=en_US
Framework arguments:  -product org.eclipse.epp.package.cpp.product -product org.eclipse.epp.package.cpp.product -keyring /Users/roda/.eclipse_keyring -showlocation
Command-line arguments:  -os macosx -ws cocoa -arch x86_64 -product org.eclipse.epp.package.cpp.product -data /Users/roda/Documents/ACTIVE/Arduino/Eclipse -product org.eclipse.epp.package.cpp.product -keyring /Users/roda/.eclipse_keyring -showlocation

Warning
Thu Jun 21 18:00:32 EDT 2012
While loading class "it.baeyens.avreclipse.core.paths.AVRPath", thread "Thread[Worker-1,5,main]" timed out waiting (5007ms) for thread "Thread[main,6,main]" to finish starting bundle "it.baeyens.avreclipse.core_1.0.6 [312]". To avoid deadlock, thread "Thread[Worker-1,5,main]" is proceeding but "it.baeyens.avreclipse.core.paths.AVRPath" may not be fully initialized.

org.osgi.framework.BundleException: State change in progress for bundle "reference:file:plugins/it.baeyens.avreclipse.core_1.0.6.jar" by thread "main".
at org.eclipse.osgi.framework.internal.core.AbstractBundle.beginStateChange(AbstractBundle.java:1087)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.start(AbstractBundle.java:297)
at org.eclipse.osgi.framework.util.SecureAction.start(SecureAction.java:440)
at org.eclipse.osgi.internal.loader.BundleLoader.setLazyTrigger(BundleLoader.java:268)
at org.eclipse.core.runtime.internal.adaptor.EclipseLazyStarter.postFindLocalClass(EclipseLazyStarter.java:107)
at org.eclipse.osgi.baseadaptor.loader.ClasspathManager.findLocalClass(ClasspathManager.java:463)
at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.findLocalClass(DefaultClassLoader.java:216)
at org.eclipse.osgi.internal.loader.BundleLoader.findLocalClass(BundleLoader.java:400)
at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:476)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:429)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:417)
at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:107)
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
at it.baeyens.avreclipse.core.preferences.AVRPathsPreferences$1.run(AVRPathsPreferences.java:166)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54)
Caused by: org.eclipse.osgi.framework.internal.core.AbstractBundle$BundleStatusException
... 15 more
Root exception:
org.eclipse.osgi.framework.internal.core.AbstractBundle$BundleStatusException
at org.eclipse.osgi.framework.internal.core.AbstractBundle.beginStateChange(AbstractBundle.java:1087)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.start(AbstractBundle.java:297)
at org.eclipse.osgi.framework.util.SecureAction.start(SecureAction.java:440)
at org.eclipse.osgi.internal.loader.BundleLoader.setLazyTrigger(BundleLoader.java:268)
at org.eclipse.core.runtime.internal.adaptor.EclipseLazyStarter.postFindLocalClass(EclipseLazyStarter.java:107)
at org.eclipse.osgi.baseadaptor.loader.ClasspathManager.findLocalClass(ClasspathManager.java:463)
at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.findLocalClass(DefaultClassLoader.java:216)
at org.eclipse.osgi.internal.loader.BundleLoader.findLocalClass(BundleLoader.java:400)
at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:476)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:429)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:417)
at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:107)
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
at it.baeyens.avreclipse.core.preferences.AVRPathsPreferences$1.run(AVRPathsPreferences.java:166)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54)
Logged

Belgium
Offline Offline
Edison Member
*
Karma: 58
Posts: 1742
Arduino rocks; but with my plugin it can fly rocking the world ;-)
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

brownerthanu
Can you check whether "Disable search for system paths at startup" is set or not? This option is available at window->preferences->Arduino->paths.
Please include a print of this preference page.
Best regards
Jantje
« Last Edit: June 24, 2012, 04:38:06 pm by Jantje » Logged

Do not PM me a question unless you are prepared to pay for consultancy.
Nederlandse sectie - http://arduino.cc/forum/index.php/board,77.0.html -

Offline Offline
Newbie
*
Karma: 0
Posts: 5
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Jantje,

Great Plug in!  I am really enjoying it. I am using Eclipse Juno (final release candidate) with arduino plugin 1.2.2
However, it looks like there is a problem when I Delete a library I have added. Looking at project properties just before delete and after delete of a library (not even a compile in between) it is easy to see the include directories are really messed up after the delete but not before.
So my question is this:
Is there anything I can do to fix this (settings, clean something, redo indexes) or am I just forbidden from deleting libraries? 

before and after screen shots of my test project are attached.  The project in question is a completely new project (no new code) but with the wire library included before and deleted in the after picture.



Thanks


* before.png (135.15 KB, 3600x1080 - viewed 14 times.)

* after.png (96.4 KB, 1152x648 - viewed 88 times.)
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 18
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hi Jantje,

I did not have that checked. I've now checked it, and I'm no longer getting that error. However, I still do not see the Arduino folder in Window > Show View > Other. Do I need to do a manual rescan? If so how is this done? Thanks so much for your help!
Logged

Belgium
Offline Offline
Edison Member
*
Karma: 58
Posts: 1742
Arduino rocks; but with my plugin it can fly rocking the world ;-)
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

 @holstine
please see http://eclipse.baeyens.it/Arduino%20eclipse%20plugin%20FAQ.htm#LibraryDelete for more info.

@brownerthanu
If there is no error I really don't know what could be wrong. Maybe reinstalling will fix the issue?

Best regards
Jantje
Logged

Do not PM me a question unless you are prepared to pay for consultancy.
Nederlandse sectie - http://arduino.cc/forum/index.php/board,77.0.html -

Offline Offline
Newbie
*
Karma: 0
Posts: 5
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Jantje,

Thanks for the quick reply.  It was very helpful.

I am still a bit lost, however, on trying to use your tool for some of the more complex projects I have built using the old Arduino IDE.
I have an arduino project that has multiple .ino files as well as a few libraries.
I have seen the video you made and read your compatability page. It was very helpful, but I still am getting confused, especially around the c #includes and what things I have to do to make it all work together (I must admit my C is a bit rusty).

So, I guess what I am asking is:

A: Can I have a multiple .ino project in the eclipse/arduino project?
B: Can it be made to be easy to go between the Arduino IDE and the Eclipse/Arduino IDE?
C: What do I need to do (#includes, function prototypes, etc) to make it compatible?
D: Could you maybe make a video or detailed instructions on how to import a complex (multi .ino and librarys) arduino project?

Any help you give would be much appreciated.  I am absolutely Itching to get my CNC controller project into your plug in.

Thanks.

Logged

Belgium
Offline Offline
Edison Member
*
Karma: 58
Posts: 1742
Arduino rocks; but with my plugin it can fly rocking the world ;-)
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Holstine
A: Can I have a multiple .ino project in the eclipse/arduino project?
You can. You can configure eclipse to handle .ino files as C++ files as described in the compatibility page.
B: Can it be made to be easy to go between the Arduino IDE and the Eclipse/Arduino IDE?
Depends on what you call easy. There are constrains on the Arduino IDE and there are constraints on the eclipse environment. To fully understand all issues a deep knowledge of both tools is needed. However full knowledge is mostly not needed.

C: What do I need to do (#includes, function prototypes, etc) to make it compatible?
This is described in the compatibility page. I'm not sure what I can add.

D: Could you maybe make a video or detailed instructions on how to import a complex (multi .ino and librarys) arduino project?
There are many use cases, I will and can not make a video for all cases.
Note the faq question on why you would want to use the plugin http://www.baeyens.it/eclipse/Arduino%20eclipse%20plugin%20FAQ.htm#why
Quote
This plugin is not meant to replace the Arduino IDE. I think the Arduino IDE is the place to get started with Arduino, no matter what is your background. However when you are growing in writing code, or when you come from a software development background you will feel restrained by the Arduino IDE. In that case the eclipse plugin may be an alternative.
From your questions I feel you need to brush up your C++ coding capabilities and eclipse knowledge. Then all will become clear. Note that the Arduino eclipse plugin runs on WINAVR, CDT and eclipse. Documentation is spread over these tools.

Best regards
Jantje
Logged

Do not PM me a question unless you are prepared to pay for consultancy.
Nederlandse sectie - http://arduino.cc/forum/index.php/board,77.0.html -

Offline Offline
Newbie
*
Karma: 0
Posts: 5
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Jantje,

Thanks again for your quick response. 
I think misunderstood some of the point of the plug in.
I thought it would be a nice eclipse environment for working with pde/ino files.  That would be great since I have been a java programmer in eclipse for most of the past 8 years.
With java and arduino I love the fact that .h files are not necessary.  The arduino make process removes that need very successfully.  By processing .ino files just by changing from .cpp to .ino I thought you had incorporated some of that ability, and that the resulting .ino file would be able to be read and processed by the ADE and conversely the .ino files could be used in your plugin with little modification. This would be very nice to keep ADE and eclipse projects from diverging. In fact, it is the only reason I can think of to change the .cpp suffix to .ino.
Don't get me wrong. This a very nice addition to the AVR programming environment plugin. I spent most of a weekend futzing around with that darn plug in before I got everything working right.  This is 20 times better (by the metric: time spent to "hello world") and I absolutely adore the serial view. 
I am sorry you thought I was a "noob" at programming or the arduino.  I was merely trying to get clear answers that would not only benefit me, but also the community at large.

   Cheers
Logged

Belgium
Offline Offline
Edison Member
*
Karma: 58
Posts: 1742
Arduino rocks; but with my plugin it can fly rocking the world ;-)
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

I thought it would be a nice eclipse environment for working with pde/ino files.
If you think of pde/ino files as input files to generate C++ files taking away the need for predeclaration; indeed the plugin is not.
Thrump had something like this working. We planned to do this plugin together but it turned out differently.
As it is all open source and you have 8 years of java programming in eclipse you are in a far better position than me to port the Arduino code doing this to eclipse   smiley-cool

With java and arduino I love the fact that .h files are not necessary.  The arduino make process removes that need very successfully. 
I like this description. I think I'll add this to my web pages.
Note that you still need to include the headers to the pde/ino files. Not so much for the include but for a way for the Arduino IDE to know the libraries to link in. This because there is no manifest or makefile in the Arduino IDE.

I am sorry you thought I was a "noob" at programming or the arduino.  I was merely trying to get clear answers that would not only benefit me, but also the community at large.
There is nothing wrong with being a "noob". I keep on going to new challenges which makes me a "noob" all the time. Even at domains I see myself as experienced there is still plenty of documentation around from which I can learn plenty.
Learning is the reason why I do this. There is still plenty to learn.
So I'm sorry if you feel insulted by my remarks. It was not my intention to insult you. My intention was to pinpoint you to a problem domain where -based on your questions- I thought there was a gap. 

Best regards
Jantje
Logged

Do not PM me a question unless you are prepared to pay for consultancy.
Nederlandse sectie - http://arduino.cc/forum/index.php/board,77.0.html -

0
Offline Offline
Newbie
*
Karma: 1
Posts: 19
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hello, I'm trying 1.2.3 plugin version on eclipse Juno under OSX
My problem is that I can't edit the paths under Prefs->Arduino->Paths, when I click on the edit button noting happens.
Any idea?

Thanks!
Logged

Belgium
Offline Offline
Edison Member
*
Karma: 58
Posts: 1742
Arduino rocks; but with my plugin it can fly rocking the world ;-)
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

motote
I have installed this in juno on a mac on Friday. My first install myself on a mac  smiley
What I noticed with juno is that the preferences are no longer under windows-> preferences but under file->preferences.
if you go to Prefs->Arduino->Paths you are probably in the project preferences and not in the workspace preferences. try file->preferences.
there you should be able to edit the settings.

Best regards
Jantje
Logged

Do not PM me a question unless you are prepared to pay for consultancy.
Nederlandse sectie - http://arduino.cc/forum/index.php/board,77.0.html -

Pages: 1 ... 4 5 [6] 7 8 ... 30   Go Up
Jump to: