ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question

calvintanct's profile - activity

2019-07-18 03:23:41 -0500 received badge  Taxonomist
2019-03-26 22:07:42 -0500 commented answer Problem with tf tutorial

Hello, thank you for the answer, I will update again if it is working or not. I used the same ros package with same pack

2019-03-26 19:54:21 -0500 received badge  Famous Question (source)
2019-03-26 08:30:23 -0500 received badge  Notable Question (source)
2019-03-26 06:48:42 -0500 commented question Problem with tf tutorial

hello, I have included my CMakeLists inside my posts here. There is a lot of comments generated from auto catkin_create_

2019-03-26 06:47:35 -0500 edited question Problem with tf tutorial

Problem with tf tutorial I followed the tutorial http://wiki.ros.org/tf/Tutorials/Writing%20a%20tf%20broadcaster%20%28C%

2019-03-25 15:48:24 -0500 received badge  Popular Question (source)
2019-03-25 11:30:47 -0500 asked a question Problem with tf tutorial

Problem with tf tutorial I followed the tutorial http://wiki.ros.org/tf/Tutorials/Writing%20a%20tf%20broadcaster%20%28C%

2017-04-26 22:42:28 -0500 received badge  Famous Question (source)
2017-04-26 22:42:28 -0500 received badge  Notable Question (source)
2017-03-01 07:51:04 -0500 received badge  Famous Question (source)
2017-01-23 17:49:07 -0500 received badge  Notable Question (source)
2017-01-19 16:25:58 -0500 received badge  Popular Question (source)
2017-01-19 03:29:59 -0500 commented question Lost sync with device, restarting...

the hello world from the ros_lib example is working, and somehow for this updated code i edited just now is working too, but I don't know why adding logger make this thing works. it's still weird i cannot troubleshoot it

2017-01-19 02:22:58 -0500 commented question Lost sync with device, restarting...

i have updated the code and still the error occurs. My arduino can work with simple hello world but this one cannot.

2017-01-19 02:21:32 -0500 received badge  Editor (source)
2017-01-18 22:51:36 -0500 commented question Lost sync with device, restarting...

okay i will try and give you an update, thanksss!!

2017-01-18 03:02:18 -0500 received badge  Organizer (source)
2017-01-18 03:00:27 -0500 asked a question Lost sync with device, restarting...

I have an arduino ros code for my project but I always get this error when I run this code. I have no idea what's wrong with this code. Can someone help me


[ERROR] [WallTime: 1484729320.445844] Lost sync with device, restarting...
[INFO] [WallTime: 1484729320.458178] Setup publisher on gripper/force [gripper_driver/force]

Oh, and one more my subscriber topic never published to the list of rostopic I attached the code for my project too :

#define USE_USBCON
#include <ros.h>
#include <std_msgs string.h="">
#include <std_msgs float32.h="">
#include <std_msgs bool.h="">
#include <gripper_driver force.h="">
#define pumpSensor 1
#define pumpOut 7

//Pump Imput
bool pump_input = false;

//Force Sensor
float force1=0;
float force2=0;
float rest_m= 2700; //in ohm
float v_supply=5;
float rest1= 10000;
float rest2= 1000;

const float p1l= 1217.7;
const float p2l= -2941.6;
const float p3l= 2928.9;
const float p4l= 157.2 ;
const float p5l= 2.4420;

const float p1h= 0.8532;
const float p2h= -14.6476;
const float p3h= 405.0821;
const float p4h= 914.0176;
const float p5h= -1.3282;

float rest_fsr1=0;
float cond_fsr1=0;
float rest_fsr2=0;
float cond_fsr2=0;

/******************* ROS configuration  *******************/
ros::NodeHandle                     nh;

gripper_driver::force               force_msg;

ros::Publisher force_publisher("gripper/force", &force_msg); 

void publishForce(){
  float v_in1=(float)analogRead(A1)/1023*5;
  float v_in2=(float)analogRead(A2)/1023*5;

  //for fsr1
  rest_fsr1= (v_supply*rest_m/v_in1)-rest_m;  // >>>>>>>>>>>>>>>>>>>>>> rest_far undefined <<<<<<<<<<<<<<<<<<<<
  rest_fsr1=rest_fsr1/1000;
  cond_fsr1=1/rest_fsr1; //in k ohm           // >>>>>>>>>>>>>>>>>>>>>> cond_far undefined <<<<<<<<<<<<<<<<<<<<

  //low-high borderline C=0.8(1/kohm) or R=1.25 kohm
  if(rest_fsr1<1250){
    force1=p1l*pow(cond_fsr1,4) + p2l*pow(cond_fsr1,3) + p3l*pow(cond_fsr1,2) + p4l*cond_fsr1;
  }
  else{
    force1=p1h*pow(cond_fsr1,4) + p2h*pow(cond_fsr1,3) + p3h*pow(cond_fsr1,2) + p4h*cond_fsr1;
  }

  //for fsr2
  rest_fsr2= (v_supply*rest_m/v_in2)-rest_m;  // >>>>>>>>>>>>>>>>>>>>>> rest_far undefined <<<<<<<<<<<<<<<<<<<<
  rest_fsr2=rest_fsr2/1000;
  cond_fsr2=1/rest_fsr2; //in k ohm           // >>>>>>>>>>>>>>>>>>>>>> cond_far undefined <<<<<<<<<<<<<<<<<<<<

  //low-high borderline C=0.8(1/kohm) or R=1.25 kohm
  if(rest_fsr2<1250){
    force2=p1l*pow(cond_fsr2,4) + p2l*pow(cond_fsr2,3) + p3l*pow(cond_fsr2,2) + p4l*cond_fsr2;
  }
  else{
    force2=p1h*pow(cond_fsr2,4) + p2h*pow(cond_fsr2,3) + p3h*pow(cond_fsr2,2) + p4h*cond_fsr2;
  }

  force_msg.force1=force1;
  force_msg.force2=force2;
  force_publisher.publish(&force_msg);
  return;
}

void set_pump_input(const std_msgs::Bool &set_pump_input){
  pump_input    = set_pump_input.data;
 }

ros::Subscriber<std_msgs::bool> pump_in_subscriber("gripper/pump_input", &set_pump_input);

void setup() {
  // put your setup code here, to run once:
  pinMode(pumpOut, OUTPUT);

  nh.initNode();

  nh.subscribe(pump_in_subscriber);

  nh.advertise(force_publisher);

}

void loop() {
  // put your main code here, to run repeatedly:

   publishForce();

  if(pump_input){
    digitalWrite(pumpOut, HIGH);
  }
  else{
    digitalWrite(pumpOut, LOW);
  }

  // >>>>> Maybe put a short delay here <<<<<
  nh.spinOnce();
  delay(1000);
}

This is my updated code, the simple implementation to get bogus data. Now this thing is working after i added the logger.


#define USE_USBCON
#include <ros.h>
#include <std_msgs string.h="">
#include <std_msgs float32.h="">
#include <std_msgs bool.h="">
#include <gripper_driver force.h="">
#define pumpSensor 1
#define pumpOut 7

float force1=0;
float force2=0;

bool pump_input=false;


/******************* ROS configuration  *******************/
ros::NodeHandle                     nh;

std_msgs::Bool                              boolean_msg;
gripper_driver::force ...
(more)
2016-10-28 05:37:16 -0500 received badge  Student (source)
2016-10-28 05:36:20 -0500 received badge  Famous Question (source)
2016-10-28 04:49:13 -0500 received badge  Popular Question (source)
2016-10-28 04:49:13 -0500 received badge  Notable Question (source)
2016-08-18 05:21:37 -0500 received badge  Notable Question (source)
2016-06-19 15:26:29 -0500 received badge  Popular Question (source)
2016-06-05 04:58:21 -0500 received badge  Popular Question (source)
2016-04-28 03:49:31 -0500 received badge  Enthusiast
2016-04-28 03:49:30 -0500 received badge  Enthusiast
2016-04-25 22:24:02 -0500 asked a question Error cannot find package (Mastering ROS Chapter 10)

Hello, I want o do the simple grasps and I copy the file from Mastering ROS code bundle

When i run

roslaunch moveit_simple_grasps grasp_generator_server.launch

I will get this message

SUMMARY
========

PARAMETERS
 * /moveit_simple_grasps_server/base_link: base_link
 * /moveit_simple_grasps_server/left_hand/end_effector_name: left_hand
 * /moveit_simple_grasps_server/left_hand/end_effector_parent_link: left_hand_graspin...
 * /moveit_simple_grasps_server/left_hand/grasp_pose_to_eef: [0.054, 0.0, 0.018]
 * /moveit_simple_grasps_server/left_hand/grasp_pose_to_eef_rotation: [0, 1.5708, 0]
 * /moveit_simple_grasps_server/left_hand/grasp_posture: [4.5, 4.5, 2.0]
 * /moveit_simple_grasps_server/left_hand/grasp_time_from_start: 4.0
 * /moveit_simple_grasps_server/left_hand/joints: ['hand_left_index...
 * /moveit_simple_grasps_server/left_hand/pregrasp_posture: [0.0, 0.0, 2.0]
 * /moveit_simple_grasps_server/left_hand/pregrasp_time_from_start: 4.0
 * /moveit_simple_grasps_server/right_hand/end_effector_name: right_hand
 * /moveit_simple_grasps_server/right_hand/end_effector_parent_link: right_hand_graspi...
 * /moveit_simple_grasps_server/right_hand/grasp_pose_to_eef: [0.054, 0.0, 0.018]
 * /moveit_simple_grasps_server/right_hand/grasp_pose_to_eef_rotation: [0, 1.5708, 0]
 * /moveit_simple_grasps_server/right_hand/grasp_posture: [4.5, 4.5, 2.0]
 * /moveit_simple_grasps_server/right_hand/grasp_time_from_start: 4.0
 * /moveit_simple_grasps_server/right_hand/joints: ['hand_right_inde...
 * /moveit_simple_grasps_server/right_hand/pregrasp_posture: [0.0, 0.0, 2.0]
 * /moveit_simple_grasps_server/right_hand/pregrasp_time_from_start: 4.0
 * /rosdistro: indigo
 * /rosversion: 1.11.19

NODES
  /
    moveit_simple_grasps_server (moveit_simple_grasps/moveit_simple_grasps_server)

auto-starting new master
process[master]: started with pid [7097]
ROS_MASTER_URI=http://localhost:11311

setting /run_id to 208bb01c-0b5d-11e6-aa8f-40a8f066d068
process[rosout-1]: started with pid [7110]
started core service [/rosout]
ERROR: cannot launch node of type [moveit_simple_grasps/moveit_simple_grasps_server]: can't locate node [moveit_simple_grasps_server] in package [moveit_simple_grasps]

If someone read and follow the tutorial in this book, can you helo me what's gong on?

2016-04-18 20:35:27 -0500 asked a question Dynamixel Controller for MX28AT

Hello, I am new to ROS, I want to control Dynamixel motor MX28AT with ROS. Which controller should i use? and how to use it? Thank you

2016-04-07 03:56:57 -0500 asked a question Cannnot Install PR2-Simulator in Indigo, Unmet dependencies

I have received this message when i try to install it using

sudo apt-get install ros-indigo-pr2-gazebo

and then i get this

Reading package lists... Done
Building dependency tree       
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
The following packages have unmet dependencies:
 ros-indigo-pr2-gazebo : Depends: gazebo2 but it is not going to be installed
                         Depends: ros-indigo-gazebo-plugins but it is not going to be installed
                         Depends: ros-indigo-pr2-gazebo-plugins but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

What should i do? I tried to install gazebo-plugins and 2 other mentioned in the message but still i cannot install all of them