How to subscribe from ROS Publisher in Arduino?
I am currently working on arduino <-> ROS and now my problem is that I cannot receive published data in arduino. I followed rosserial subscribing, publishing tutorials but it seems received message looking at serial monitor is only 0s.
Below is my code used to subscribe in Arduino
ros::NodeHandle nh;
void receiveANGLE( const angle::FSS& msg) { angle2 = msg.Data; }
ros::Subscriber<angle::fss> sub("FSS", &receiveANGLE);
FSS is the topic I am sending from ROS publisher and it is perfectly sending datas properly. Also, angle is my package name and FSS is also name for my message which is int32. if i look at angle2 in serial monitor, only 0 0 0 0 0 0 values are seen.
what could be the problem??