Society of Robots - Robot Forum
Software => Software => Topic started by: DancesWithRobots on September 17, 2011, 05:53:12 PM
-
SO, I've been playing around with an arduino Diecimila and some servos. I've gotten multiple servos to work together using a python/wxpython control panel and generally been having what I consider encouraging progress. Then I discovered ROS.
I did a full install of ROS on my Ubuntu 11.04 box, and worked my way through the tutorials with no problem until I switched over to the rosserial arduino tutorials. Right away I had problems with the path for ros_lib folder going to rosrerial/rosserial_arduino/src/ros_lib rather than rosserial/rosserial_arduino/libraries/ros_lib which is where the tutorial I followed had it. But it was no problem to copy the folder to sketchbook/libraries and proceed. (Of course, all of this is happening under the home folder where the .ros, and ros_workspace folders also live.)
Moving on to HelloWorld, I can load it from Examples>ros_lib>HelloWorld, but when I Verify/Compile, I get the following messages:
In file included from HelloWorld.cpp:6:
/home/david/sketchbook/libraries/ros_lib/ros.h:43:26: error: ros/ros_impl.h: No such file or directory
HelloWorld.cpp:7:29: error: std_msgs/String.h: No such file or directory
In file included from HelloWorld.cpp:6:
/home/david/sketchbook/libraries/ros_lib/ros.h:48: error: expected initializer before ‘<’ token
HelloWorld:8: error: ‘NodeHandle’ in namespace ‘ros’ does not name a type
HelloWorld:10: error: ‘std_msgs’ has not been declared
HelloWorld:10: error: expected constructor, destructor, or type conversion before ‘str_msg’
HelloWorld:11: error: ‘Publisher’ in namespace ‘ros’ does not name a type
HelloWorld.cpp: In function ‘void setup()’:
HelloWorld:17: error: ‘nh’ was not declared in this scope
HelloWorld:18: error: ‘chatter’ was not declared in this scope
HelloWorld.cpp: In function ‘void loop()’:
HelloWorld:23: error: ‘str_msg’ was not declared in this scope
HelloWorld:24: error: ‘chatter’ was not declared in this scope
HelloWorld:25: error: ‘nh’ was not declared in this scope
I suspect there is some issue with file locations--probably obvious to someone who knows this a little better than me.
-
Don't know if this will help, I don't use the arduino environment enough to know the answer offhand, but take a look at http://www.arduino.cc/en/Hacking/BuildProcess (http://www.arduino.cc/en/Hacking/BuildProcess) or http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1216805349 (http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1216805349) Maybe they will tell you something useful.
Joe
-
I too face the same error. I request someone to help fixing it.