Integrating a serial output window with Eclipse
This tutorial shows how to integrate a basic serial terminal in Eclipse. This terminal can only receive and output serial data from the Arduino and not actually send data to the Arduino. It's simple to install and tutorial for all major operating systems are(soon) available. A tutorial of how to configure the serial terminal is also available at the bottom of this tutorial.
-
Use the menu "Help --> Install New Software" and enter http://download.eclipse.org/releases/luna
Then check the box next to "Target Management Terminal" in "Mobile and device management", then keep pressing "Next" until the install is complete.
-
Download these files:
http://jlog.org/v4/macosx/mac-10.5/RXTXcomm.jar
http://jlog.org/v4/macosx/mac-10.5/librxtxSerial.jnilib
http://jlog.org/v4/macosx/fixperm-217-leo.sh -
Move "RXTXcomm.jar" and "librxtxSerial.jnilib" into "/Library/Java/Extensions"
-
Move "fixperm-217-leo.sh" to Desktop
-
Open "Terminal"(found under Application --> Utilities)
$ cd Desktop
$ sudo sh ./fixperm-217-leo.sh
Password: <your administrator password>
-
Open(or restart) Eclipse
-
Go into "Windows --> Show View --> Other ..."
-
Choose "Terminal" under the "Terminal"-category, then press OK.
-
Done! You should not see a terminal window available within Eclipse!
Continue reading "Configuring the serial terminal" below, to properly configure your serial terminal!
Sources:
http://mcuoneclipse.com/2014/03/23/serial-terminal-view-with-eclipse-kepler/
http://jlog.org/rxtx-mac.html
Download files from here: http://jlog.org/rxtx-win.html
Put 'RXTXcomm.jar' in the 'lib/ext' folder of the Java VM (e.g. 'C:\Program Files\Java\jre1.8.0_20\lib\ext').
Put 'rxtxSerial.dll' in the 'bin' folder of the Java VM (e.g. for Sun's Java 1.6.0_04 it will be 'C:\Program Files\Java\jre1.8.0_20\bin').
Use the menu "Help --> Install New Software" and enter 'http://download.eclipse.org/releases/luna'
Then check the box next to "Target Management Terminal" in "Mobile and device management", then keep pressing "Next" until the install is complete.
To show the terminal you go to Show View -> Other -> Terminal -> Terminal
You should now have a functioning terminal inside of Eclipse. See below for configuration.
-
Use the menu "Help --> Install New Software" and enter http://download.eclipse.org/releases/luna
Then check the box next to "Target Management Terminal" in "Mobile and device management", then keep pressing "Next" until the install is complete.
-
Launch Eclipse, go to Help->Install New Software, add this site location:
rxtx: http://archive.eclipse.org/tm/updates/rxtx/
Check the lastest version and click next until installed
Just installing this alone will not work on linux, on ubuntu eclipse will crash every time you try to connect to a serial port.
Follow these additional steps to make it work:
-
update sources
sudo apt-get update
-
install the Ubuntu version of the serial java library
sudo apt-get install librxtx-java
-
delete the plugin version of the library
rm eclipse/plugins/gnu.io.rxtx.linux.x86_64_2.1.7.3_v20071015/os/linux/x86_64/librxtxSerial.so
-
create a soft link from the system version of the library
sudo ln -s /usr/lib/jni/librxtxSerial.so eclipse/plugins/gnu.io.rxtx.linux.x86_64_2.1.7.3_v20071015/os/linux/x86_64/librxtxSerial.so
** Do not use the one at /usr/lib/librxtxSerial.so instead of /usr/lib/jni/librxtxSerial.so **, it doesn’t work that way.
-
Launch Eclipse and go to Window->Show View->Other on the pop-up window, select Terminal- >Terminal and click OK.
Sources: http://karibe.co.ke/2014/03/eclipse-kepler-terminal-plugin-serial-port-console-in-linux/
-
Press the "yellow notepad"-button in the "Terminal"-window. It looks like this:
-
A new window should appear. In this window you primarily have to choose "Serial" in the "Connection Type:"-drop-down list. (Look at the image below)
-
The window should update and show additional settings you can customize for the serial connection. What works fine so far cross over the operating system are the settings shown in the image below. What will vary between computer and operating system is the port setting, which should be easily configured using the drop-down list. Also note the "Baud Rate: " value can change depending on the program running on the Arduino you are trying to serial communicate with.
- Choice of tools and rationale behind it
- How to set up the project
- Integrating Doxygen with Eclipse
- Integrating a serial output window with Eclipse
- Standard System Initialization