Interfacing ROS with Arduino Error Can't Locate ros.h

Hello,

I'm trying to interface Arduino with ROS and am receiving the error "fatal error: ros.h: No such file or directory compilation terminated." Is there any advice available to solve this? The steps I followed are:

Step 1.

<
sudo apt-get install ros-kinetic-rosserial-arduino
sudo apt-get install ros-kinetic-rosserial

Step 2.

<
cd /src
git clone GitHub - ros-drivers/rosserial: A ROS client library for small, embedded devices, such as Arduino. See: http://wiki.ros.org/rosserial
cd
catkin_make

For my I used cd Home/catkin_ws/src and it installed rosserial there and the for the catkin_make was cd Home/catkin_ws

Step 3.

<
cd /libraries
rm -rf ros_lib
rosrun rosserial_arduino make_libraries.py

For my location I used Home/libraries

So, the procedure added the ros_lib library into the IDE - great. I cant compile any sketches with this library however without receiving the above mentioned error. Any ideas why the system cant locate the ros.h?

Many Thanks,
James

jamesmacintosh:
For my location I used Home/libraries

It's not clear exactly what you mean but this doesn't look right to me. You need to make sure the folder matches the setting in the Arduino IDE's File > Preferences > Sketchbook location. Note that libraries are stored under the libraries subfolder of your sketchbook. So if your sketchbook folder was Home/arduino_sketchbook then the library should be under something like Home/arduino_sketchbook/libraries/rosserial_arduino. The library should also be directly under the libraries folder, not down multiple subfolder layers.

Did you re-start the Arduino IDE after installing a library manually? It doesn't scan for new libraries every time you compile.

What is the full path to the 'ros.h' file? Is the filename in lowercase as shown?