Related
I have been trying to use the Arduino extension for VS Code in Ubuntu 18, but when I execute the initialize command, I get the error "Cannot find the Arduino IDE. Please specify the arduino.path in the user settings". So I wrote every path that comes out when executing the command "whereis arduino", I've also tried leaving the box empty (in theory that makes VS Code search for the IDE) and reinstalling both the Arduino IDE and VS Code several times, without any result. Does somebody knows a possible fix for this issue?
Download and extract the appropriate Arduino version according to your need from here, and install it using command sudo ./install. In my case, I have downloaded Arduino 1.8.6 Linux 64 Bit .
Goto Files -> Preferences -> Settings, Open Settings(JSON) as shown below.
Change arduino.path to the path location of extracted Arduino file. In my case it is /home/user/Downloads/arduino-1.8.6 and arduino.commandPath to arduino.
OR
For those who installed Arduino through snap platform refer this post.
Your Settings JSON file should look like this.
{
"arduino.path": "/home/user/Downloads/arduino-1.8.6",
"arduino.commandPath": "arduino",
}
Save and restart.
It's Done!!
Good Luck
P.S.:Add arduino.commandPath if not already exist and should point to Arduino executable present in the arduino.path.
Even when its on mac, someone can find this helpful as I had the same problem and found this thread. On MAC I have solved this one with arduino-cli and following:
install homebrew (if you have, proceed to step 2)
install arduino-cli with brew install arduino-cli
find where the arduino-cli is installed. Usually (on mac) it will be /opt/homebrew/bin/arduino-cli... Which means, if you run the command arduino-cli, it will execute this script... You can find the location with:
which arduino-cli (I have zsh, I am not aware if it will be the same for older bash, probably it will, I am not so skilled in this one, but you can try to use find instead of which. But which is working for me
lets assume you have the path, for me it was /opt/homebrew/bin/arduino-cli
proceed to VScode, go to settings (well, lets assume we will be working with the json settings
in my case, the input is following:
"arduino.useArduinoCli": true,
"arduino.path": "/opt/homebrew/bin/",
"arduino.commandPath": "arduino-cli"
Note, even when the path to arduino-cli is /opt/homebrew/bin/arduino-cli, we are removing the script name from the path... But we are adding this to the commandPath
I found that running whereis arduino or which arduino gave me /usr/local/bin/arduino. However, this didn't make Visual Studio Code happy. After some more digging, it turns out that that path is just a symlink to /opt/arduino-1.8.13. (Use ls -la /usr/local/bin/arduino to see where the symlink points to on your system.)
Also of note: be sure to give the path to the directory, not to the actual executable. For instance, in my case, the proper path was /opt/arduino-1.8.13 NOT /opt/arduino-1.8.13/arduino!
tl;dr
Use /opt/arduino-1.8.13, but be sure to update the version number to whatever is installed on your system.
This might not work for everyone, but the problem for me was using Visual Studio Code for flatpak. There was probably a better way to fix this, but the easiest way to do it (for me) was to install the binary from their website.
Go to "User Settings" > "Extensions" > "arduino.commandPath" > change it to "arduino_debug.exe"
In my case whereis arduino gave me /usr/bin/arduino and /usr/share/arduino, however putting either of them in the arduino.path didn't work.
Entering /usr/bin did the trick though. hope it helps!
(Ubuntu 20.04)
I use Windows and I solved it as follows.
The problem is because you are using the new version Arduino IDE 2.x.x and it has another way to code its sketches and more (I don't know how to say it, I'm a beginner in this) or you haven't activated to use Arduino Cli at least, so -- ->
Intall Arduino 1.8.x. You can donwload it here: Arduino Software
Open your vscode, go to Files>preferences>settings and find your Arduino extension under "Extensions". and put the standard path for Arduino 1.8.x like: C:\Program Files (x86)\Arduino (Remember this is where you installed the Arduino 1.8.x path) in "Arduino Path".
Next, you need to click on "Arduino: Use ArduinoCli" to link the Arduino extension to the correct version (Arduino Legacy is not allowed).
Arduino CLI option in vscode settings
Here's what fix my issue!
1st - Make sure you have the right path ("The path to the folder which contains the 'arduino.exe'", and not the path with the 'arduino.exe') copied to your Arduino Settings in VS Code.
2nd (The Actual Fix for me) - After installing the Arduino IDE and the VS Code extension RESTART you entire computer!! This somehow updates the Registry.
After which you can just Initialize your project, F1 - Arduino Initialize.
That's it enjoy and start up your Golden IoT project.
I installed cygwin (the latest 1.7.xx?), and then installed eclipse cdt (Juno).
When I tried to build a hello world project, despite eclipse identifying that cygwin was installed, it didn't work.
So I manually added c:\cygwin\bin to the path, which found all the executables in cygwin, including g++, make ld, etc.
Now, eclipse can build the project, but when debugging, gdb starts up and can't find the source code. It claims that it can't find:
/cygdrive/c/users/me/workspace/test1/test1.cc
.
even though that's exactly where it is. It's as though cygwin's directory system doesn't work.
I can manually load the source from:
c:\users\me\workspace\test1\test1.cc
and the debugger works, but the next time I start a new project, I have to do it again.
How do you instruct the eclipse/cygwin combo to correctly find source code?
Alternatively, is Mingw any easier? I have experienced similar problems with eclipse seeing that mingw is there, but build failing because it doesn't find the executable.
Here is how I made it work.
I goto Window ==> Preferences ==> C/C++ ==> Debug ==> Source Lookup Path
I Add a Path Mapping: Project Source
On the left side I put the path that Cygwin expects, i.e. \home\MyName\projects and on the right side I put the Windows path, i.e. C:\cygwin\home\MyName\projects
Then when I debug it finds the source file fine.
Go to Windows->Preference->C/C++ -> Debug -> Source Lookup Path. Add following 'Path mapping'.
\cygdrive\c -> c:\
Although Above are given good answers but still it might not solve the problem sometimes phew!!!!
Suppose you install Cygwin in C: but your eclipse workspace is in D: then there is a problem in your mounting
all you should do is, open the cygwing shell & type "mount" to get the following :
Ritvika#Ashutosh ~
$ ls
Ritvika#Ashutosh ~
$ mount
C:/cygwin64/bin on /usr/bin type ntfs (binary,auto)
C:/cygwin64/lib on /usr/lib type ntfs (binary,auto)
C:/cygwin64 on / type ntfs (binary,auto)
C: on /cygdrive/c type ntfs (binary,posix=0,user,noumount,auto)
D: on /cygdrive/d type ntfs (binary,posix=0,user,noumount,auto)
Ritvika#Ashutosh ~
$
here my Projects are all under D:\ECWorkSpace, so my mapping needs to be present
in Eclipse as:
/cygdrive/d d:/
Hence, now Armed with this knowledge do what PathM says
1. goto Window ==> Preferences ==> C/C++ ==> Debug ==> Source Lookup Path
2. Add a Path Mapping: Project Source
3. On the left side put "cygdrive\d", & on the right put : "D:\"
This should work. ( It did for me :) )
You can Check this FAQ as well : https://wiki.eclipse.org/CDT/User/FAQ#I.27m_using_cygwin_and_when_launching_the_debugger.2C_it_complains_that_it_can.27t_find_the_source_file
I use MinGW + CDT, and it is giving me great satisfaction. I installed it many times and never had any disagreement. No much to configure than what you did with cygwin. Download the Eclipse for C/C++ developers (probably what you did) to get CDT (MinGW Tool Chain -> gdb + gcc) directly operational. Set your \\MinGW\bin\ directory into your PATH and you should be good to go...
Note : Like Cygwin, MinGW provides a Linux-like Shell.
For MinGW-64, ready-made builds are a little bit more difficult to locate. See here.
Look at set-up of "Common Source Lookup Path" here: http://wyding.blogspot.dk/2009/04/setup-cygwin-toolchain-in-eclipse-cdt.html
I replaced gdb with msys gdb. For example:
Current configuration:
... Application Configuration .. Debug .. Debug
GDB Debugger gdb
to
GDB Debugger path to msys gdb (like for example c:\msys\bin\gdb.exe
For the past week, i have been hunting a free development environment for STM32F1xx, which is supported by FreeRTOS. And no success yet :( .
Now I've found this: http://www.stf12.org/developers/ODeV.html
It's an Eclipse configuration for STM32 compiling and debugging, and there is a FreeRTOS demo too. Perfect!
So I downloaded a preconfigered version of eclipse and tried to compile a demo project to get this error:
Cannot run program "cs-make": Launching failed.
Depressing. Please help, i am very bad at configuring IDE's, compilers and linkers so this has to be newbie-friendly :)
The Eclipse project is configured for CodeSourcery toolchain. You need to install CodeSourcery compiler toolchain from: http://www.mentor.com/embedded-software/codesourcery. Choose Lite Edition, ARM-NONE-EABI package. After the installation make sure you can start cs-make from command prompt (by typing it's name there). Generally, you want all toolchain programs to be accessible from command prompt, which implies that their installation path must be in system PATH variable.
P.S.
Make sure the path DOES NOT contain spaces like standard Windows programs directory "C:\Program Files", instead install the tools in a directory like "C:\arm-none-eabi", "C:\ARM_tools" or something like that.
Ah, thank you got it to work now!
And I ran into another problem too. When I tried to compile another error came up saying something like: "C:\Program is no file or directory". I Solved it by placing all compilers and OpenOCD in the root of my C-drive. I think it's because the make doesn't understand spaces in the make file, if anyone else get the same problem.
The instructions how to install GoClipse have been followed.
I'm not getting any autocomplete stuff happening at all, either for local packages that I write, for built in stuff, or for GAE stuff (I have downloaded Go src to the SDK folder as the wiki states).
Are there any settings that I can check to ensure it is set up correctly? Is autocomplete supposed to work in the current version?
As the GoClipse with AppEngine article you linked to says:
We assume the reader has a working copy of GoClipse running in their Eclipse environment.
so that’s not the article you want to refer to. Instead, check for GoClipse.
The auto completion is named content assist in eclipse. The GoClipse features state:
Now delivered with content assist via Gocode for Windows, OS X 64bit, and Linux 64bit.
Gocode is an auto-completion daemon. So you will also have to install and run that one besides your eclipse + GoClipse.
There is a bug in the current version of Goclipse for the Linux platform. It currently delivers a prebuilt version of gocode for Windows, 64 bit OS X, and 64 bit Linux. I have only been able to test it locally with limited resources, so I really depend on users to report the problems they find at:
http://code.google.com/p/goclipse/issues/list
If you are having problems, I urge you to download and install gocode into your $GOROOT/bin directory and see if that helps. Otherwise, the fix will come in the next release in a few days.
Also, sorry for causing you any trouble and thank you for trying Goclipse.
If you are not using a gocode upstream (but the one shipped with Eclipse) on Linux you are also no be able to build your application with CRTL+F11, although just clicking in Run->Run is going to work.
So, I strongly recommend to update your gocode on Linux, as simple as:
$ sudo GOPATH=/opt/go/ go get -u github.com/nsf/gocode
I had Eclipse Indigo installed on my computer with the Android plugin and it was working perfectly for about two weeks. Today, I updated java and quicktime then restarted my computer. When it booted back up, eclipse had completely vanished - all the program files have completely disappeared. When I try to reinstall it, I get an error message that says
The Eclipse executable launcher was unable to locate its companion shared library.
What happened and how can I fix it?
I've just encountered the same issue. The problem for me was Windows 7 default unzipper program. It has a problem when it encounters files that have a deep file structure. I read about this issue some time ago but can't recall the article. Fix for me is to unzip the Eclipse download using WinZip (or some other tool which does'nt have this issue).
Check eclipse.ini, there are two entries like:
-startup
plugins/org.eclipse.equinox.launcher_1.3.0.v20120522-1813.jar
--launcher.library
plugins/org.eclipse.equinox.launcher.gtk.linux.x86_64_1.1.200.v20120913-144807
For some twisted reason jars have version in their name - so if you upgrade/have two different version of eclipse( while eclipse.ini is either linked or provided as system wide conf file for eclipse ) it will cause above error.
That sounds pretty bad and weird. But reinstalling isn't that hard - download, unzip, change the default memory allocation, run Eclipse, install necessary plugins and features.
And almost all of the important preferences are in your workspace. The only important one I can think of outside of the workspace is the aforementioned memory allocation, which you can set on the command line or in the ECLIPSE.INI file.
During unzip in a cygwin directory on Win7, .exe and .dll need to be given executable mode. This is the solution from a mintty (or other $TERM) terminal run with cygwin on windows 7:
me#mymachine ~/eclipse
$ find . -name "*.dll" -exec chmod +x {} \;
tried with Juno (eclipse 4.2) freshly unzipped, cygwin 1.7.something
I have seen this in MacOS Sierra. Sometimes unzipping the app leaves extended attributes that seem to prevent the startup. The following command line removes extended attributes and seems to fix the problem:
xattr -c Eclipse.app
It also works for other applications that are built on the eclipse framework.
Another problem (that I ran into) is that Cygwin's unzip utility (UnZip 6.00 of 20 April 2009, by Cygwin. Original by Info-ZIP.) does not always correctly unzip everything needed for Eclipse to actually run.
Using 7ZIP v9.20 got Eclipse Indigo (3.7.2) up and running for me on Win7 64bit with 32bit JVM and 32bit Eclipse.
(First time I've ever had Cygwin's unzip fail on me...)
I just ran into this myself and found that, indeed, as one post above stated: using cygwin and gunzip or unzip to set up your eclipse environment the permissions on the .exe and .dll files will be incorrect and the JVM will not run them properly.
Quick solution:
#switch to the eclipse target folder
cd /cygdrive/c/Program\ Files\ \(x86\) #or wherever you put eclipse
find ./ -regextype posix-extended -mindepth 1 -type f -regex ".*\.exe|.*\.dll" |\
xargs chmod -v 750
I meet this issue after copy a eclipse installation to another pc.I find the eclipse installation auto created the .p2 directory on my c:\Users\xx.p2, and --launcher.library refer to here.So it doesn't exist on my another pc.
My resolution is to reinstall eclipse:
a)Double click eclipse-inst-win64.exe
b)Click to change to advanced mode.
c)Uncheck the Bundle Pool
d)Finish your installation and copy again.Everything will work well.
My experience and advice: Install Eclipse Juno on C: drive.
After download the zip, put it on C:, click the right mouse button -> extract here. Then a folder called eclipse will be created in C: drive.
Then go to Eclipse executable, run it, and all will be ok.
I faced this problem and solved it by running Eclipse as admin.
Problem happened when I unzipped using Cygwin. Used the Windows XP standard unzip program and it worked.
if you are having two eclipse then sometime this happens
you only have to remove
-startup
plugins\org.eclipse.equinox.launcher_1.0.100.v20080509-1800.jar
from eclipse.ini file beside eclipse.exe(Launcher)
Also see this related question's answer.
The gist is: Try unzipping it again with a solid unzip tool. Sometimes unzipping goes wrong, especially with the built-in Windows Explorer tool.
i have this error message when i use extract the files as follows:
action\select all
drag and drow the files to an new folder
Somehow information about the folders get lost
when i use "action\extract to..." it works.
Also, remember to right click on eclipse, then choose Security Unblock
Mostly this is related to problems on windows with the unzipping it seems. (See other answers here for that).
The second largest issue seems to be that eclipse is not able to find java or finds a java version which is too old or even older eclipse installations.
Here's another take to the latter problem and a small twist to solve it. My work environment is on a linux system, without root access, and with software installations where I can configure which versions to use in a kind of config file. However I have no influence on the way those software packages are installed and they are immutable to me.
I download and untar the latest eclipse as usual to a user disk for which I have write permissions. Then I configure myself an alias to always temporarily cd into the eclipse installation when starting. That regardless of where I work on the file systems, eclipse always finds its correct libraries. It seems in some places, eclipses default search path for java digs out an installation (of java or older eclipses or sth else) in my environment that it really should not use.
Here's the alias:
alias eclipse '(pushd /enter_path_to_eclipse_install_dir_here/eclipse ; ./eclipse ; popd)'
Now you can start it normally from e.g. your project or arbitrary work directory:
eclipse
Or also put it in the background
eclipse &
Maybe this helps for people in convoluted work environments.
Try running eclipse.exe as administrator or using Eclipse Helios.
I have copied the Eclipse folder from another machine where the path was different and that was the root of this problem. Changing the plugins path in ECLIPSE.INI worked for me !!
Solution for Mac
Reason:
Eclipse copies from one location to other
Solution:
Paths change needed in /Applications/eclipse/Eclipse.app/Contents/MacOS/eclipse.ini
Fix path for plugins\org.eclipse.equinox.launcher_1.0.100.v20080509-1800.jar
I had the same problem when I was trying to install it on Windows 8.
But it was an zip composed file....
Ones I unzip and Run "eclipes.exe" file as run As 'Administrator' it was resolved.
Now I am enjoying it very well.
I had the same message after a system restore with the eclipse folder (V. 3/2020) being located on a second drive (that was NOT restored at the same time, I use it for large files mainly).
Restoring the faulty installations C:\Users<user>.p2 folder to the new installation (referenced in eclipse.ini of the eclipse folder) worked.
Keep shorter folder name, fixed for me.
I faced this issue recently: (In my case it was installation of STM32CubeMX software):
what I faced: I have two users in my laptop, I had installed the software in one user but on the hard disk partition: D:\
Now I had tried to work on another user!
-- I think you know why I got the error --
So as I was working on the 'other' user account, I got this error every time I tried to compile/build my project - obviously, Because I installed using one user and am working on another.
Workaround: Already mentioned in the above answers clearly!
What I did differently: I tried using the S/W in the other user, but there seems to be issues on the path file/location:
so I reinstalled the location in the user account I want to use and am running it properly now!
Note: While Installing it did ask about installing the software for all user/ current user : I mistakenly had given 'current - user' =(
I also faced ths problem, I just deleted the extracted file and extracted it again.
I have a .rar file.
This problem occurs when the file is not extracted completely.
You might changed your drive-letter:
once u had installed eclipse on D:\, after windows reinstall the drive-letter is now E:\ (for example).
look into eclipse.ini in your eclipse folder, there are some lines where the drive-letter is still D:\
This happened to me when I tried to open eclipse.exe before the .zip file finished extracting. Make sure all dependencies are unzipped or unpacked before opening the .exe.
I had this issue on Linux (CentOS 7 64 bit) with 32-bit Eclipse Neon and 32-bit JRE 8. Non of the answers here or in similar questions were helpful, so I thought it can help someone.
Equinox launcher (eclipse executable) is reading the plugins/ directory and then searches for eclipse_xxxx.so/dll in org.eclipse.equinox.launcher.<os>_<version>/. Typically, the problem is in eclipse.ini pointing to the wrong version of Equinox launcher plugin. But, if the file system uses 64-bit inodes, such as XFS and one of the files gets inode number above 4294967296, then the launcher fails reading the plugins/ directory and this error message pops up. Use ls -li <eclipse>/plugins/ to check the inode numbers.
In my case, moving to another mount with 32-bit inodes resolved the problem.
See: http://www.tcm.phy.cam.ac.uk/sw/inodes64.html
I encountered this error with the Eclipse 4.10 installer. We had failed to complete the install correctly due to platform security settings and attempted to uninstall but had to do it by hand since no uninstaller was introduced during the failed install. We suspected this corrupted the end result - even after re-installing.
The solution was to use the JVM to launch Eclipse and bypass the launcher executable entirely. The following command successfully launches Eclipse 4.10 (some parameters will change based on the version of Eclipse):
%JDK190%\bin\javaw.exe -jar C:\<fully_qualified_path_to_eclipse>\Eclipse410\plugins\org.eclipse.equinox.launcher_1.5.200.v20180922-1751.jar -clean -showsplash
After using this command/shortcut to launch Eclipse we had no further errors with Eclipse itself but we weren't able to use the EXE launcher in the future. Even after a year of using this version, the launcher continues to display this same error.
To be clear, you'll have to modify your javaw.exe command to match your system specifications on MS Windows.
I got similar error sometime back. I had copied the eclipse setup from another laptop to mine. The issue with my setup was that path of the "--launcher.library" in the eclipse.ini file. The path in --launcher.library was that of the old machine and hence I was getting the error
I changed the path of "--launcher.library" in eclipse.ini to the path of eclipse on my laptop and the issue got resolved. I hope this is helpful to someone is getting this error.
remove it and run eclipse-installer again without root
I have create Demo.exe using Eclipse RCP.
I have run Demo.exe using C-Drive to same error generate like...
Solution : You might changed your drive for example
C:\Demo.exe to D:\Demo.exe
Step 1 : First Copy/Cut your .exe file like C:\Demo.exe
Step 2 : After Paste another drive like D:\Demo.exe
After executable file launching successfully.
I hope my answer is useful.