It is always nice to have all your views in one perspective in your IDE when you are debugging, including the serial console. For me eclipse juno and Kepler crashes in Ubuntu if I try to open a serial port. I found a bug report on launchpad that explains how to do a workaround. The problem is that the serial library the plugin ships with doesn’t work in my OS.
Install Target management component from the list on this update site:
where $version is kepler or luna or neon or whatever version of eclipse you have :P. Just go to the menu Help->Install new software and paste that URL as the site to “Work with”. then check under “Mobile and Device management” [for neon, its Mobile and Device Development], you will find “Target Management Terminal” [in neon its TM Terminal]. The rest is just clicking next, I agree and finish to the end.
Install the Plugin
Launch Eclipse, got to Help->Install New Software, add this site location:
The rest is just trivial, clicking buttons till the end 🙂
Update: for Kinetis Design Studio 3.0, I was able to make the serial terminal work with TM rxtx plugin from this site:
RxTx - http://rxtx.qbang.org/eclipse/
Make it work
So here is how to solve it according to
Gregor Riepl (onitake)’s comment
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
for Eclipse Neon on Ubuntu 16.04:
For earlier versions:
create a soft link from the system version of the library
for Eclipse neon on Ubuntu 16.04[not sure if its different with eclipse versions or Ubuntu versions]
ln -s /usr/lib/jni/librxtxSerial.so .p2/pool/plugins/gnu.io.rxtx.linux.x86_64_126.96.36.199_v20071015/os/linux/x86_64/librxtxSerial.so
For earlier versions:
sudo ln -s /usr/lib/jni/librxtxSerial.so eclipse/plugins/gnu.io.rxtx.linux.x86_64_188.8.131.52_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.
Click on the yellow icon for settings and select serial, change the settings and click OK, it auto-connects. Now you can use a serial port in your hardware to output further debug information that can be viewed in the terminal view in Eclispe, in addition to breakpoints and register/memory inspection.