Eclipse marks commands related to ros as unresolved when writing nodes for Arduino

asked 2019-05-23 16:04:29 -0600

I have created a Project, where one node should run on a Arduino. Since I am working in Eclipse, I have used the structure given in this rosserial tutorial. In my case the directory structure is package_name/ardunio. In package_name/ardunio I put the code for the Arduino node. For testing, I just used the Blink sketch from the Tutorial.

When I press "Build" in Eclipse, everything builds without an error and I can upload the node to the Arduino successfully. However, Eclipse marks/underlines all lines of code related to Ros as unresolved. For instance,

ros::Subscriber<bieber_controller::CarControl> sub("toggle_led", &messageCb);

cannot be resolved.

Previously, I had similar issues with the Arduino command as well. I was able to fix them by including

/home/USERNAME/.arduinocdt/packages/arduino/hardware/avr/1.6.23/cores/arduino

However, I tried to include

/home/USERNAME/Arduino/libraries

, where the ros_lib is located, but the issues are still there.

This is my Eclipse Build ID information :

Version: 2019-03 (4.11.0)
Build id: 20190314-1200
OS: Linux, v.4.15.0-48-generic, x86_64 / gtk 3.18.9, WebKit 2.20.5
Java version: 1.8.0_191
edit retag flag offensive close merge delete