2023-08-04 14:26:30 -0500 | received badge | ● Nice Question
(source)
|
2019-03-29 05:46:02 -0500 | received badge | ● Student
(source)
|
2017-08-11 13:09:58 -0500 | received badge | ● Famous Question
(source)
|
2017-01-26 04:13:29 -0500 | received badge | ● Famous Question
(source)
|
2016-11-23 16:47:41 -0500 | received badge | ● Famous Question
(source)
|
2016-10-28 14:25:31 -0500 | received badge | ● Famous Question
(source)
|
2016-09-05 07:38:13 -0500 | received badge | ● Notable Question
(source)
|
2016-08-30 11:49:56 -0500 | received badge | ● Notable Question
(source)
|
2016-07-29 20:35:12 -0500 | received badge | ● Notable Question
(source)
|
2016-07-22 13:15:32 -0500 | received badge | ● Popular Question
(source)
|
2016-07-22 08:16:41 -0500 | commented question | Gazebo ROS Collision Detection I have tried it in several places. Including the one you suggested in the gazebo wiki site. The other ones I have tried are from here and here. |
2016-07-22 08:16:41 -0500 | received badge | ● Commentator
|
2016-07-21 12:34:15 -0500 | asked a question | Gazebo ROS Collision Detection Hello all, I am trying to get a topic with the collision by using the gazebo-ros-bumper plugin, but all of the resources I have found online have not worked for me. Here is my xacro code for the robot arm. <!-- ***************Robot Arms*************** -->
<xacro:include filename="$(find robsim_description)/urdf/kuka.xacro" />
<!-- ***************Robot Hands*************** -->
<xacro:include filename="$(find robsim_description)/urdf/sdhhand.xacro" />
<!-- ***************Joint*************** -->
<xacro:rev_joint_block parent="arm_extension" child="sdh_gehaeuse" xyz="0 0 0.0411" rpy="0 0 0" lower="0" upper="0"/>
<!-- ***************Gazebo Plugin************************ -->
<gazebo>
<plugin name="gazebo_ros_control" filename="libgazebo_ros_control.so">
<robotNamespace>/robarm</robotNamespace>
</plugin>
</gazebo>
Here is the code for my kuka arm: <xacro:macro name="link_block" params="link xyz rpy filename material">
<link name="${link}">
<visual>
<origin xyz="${xyz}" rpy="${rpy}"/>
<geometry>
<mesh filename="package://robsim_description/models/${filename}"/>
</geometry>
</visual>
<collision>
<origin xyz="${xyz}" rpy="${rpy}"/>
<geometry>
<mesh filename="package://robsim_description/models/${filename}"/>
</geometry>
</collision>
<inertial>
<mass value="1"/>
<inertia ixx="0.1" ixy="0" ixz="0" iyy="0.1" iyz="0" izz="0.1"/>
</inertial>
</link>
<gazebo reference="${link}">
<turnGravityOff>true</turnGravityOff>
<material>Gazebo/${material}</material>
</gazebo>
</xacro:macro>
<xacro:macro name="rev_joint_block" params="parent child xyz rpy lower upper">
<joint name="${parent}_${child}_joint" type="revolute">
<parent link="${parent}"/>
<child link="${child}"/>
<origin xyz="${xyz}" rpy="${rpy}"/>
<axis xyz="0 0 1" rpy="0 0 0"/>
<limit lower="${lower}" upper="${upper}" effort="300.0" velocity="1000.0"/>
<joint_properties damping="0.0" friction="0.0"/>
</joint>
</xacro:macro>
<xacro:macro name="transmission_block" params="parent child">
<transmission name="${parent}_${child}_trans">
<type>transmission_interface/SimpleTransmission</type>
<joint name="${parent}_${child}_joint">
<hardwareInterface>PositionJointInterface</hardwareInterface>
</joint>
<actuator name="${parent}_${child}_motor">
<mechanicalReduction>1</mechanicalReduction>
</actuator>
</transmission>
</xacro:macro>
<!-- ***************Kuka Base Plate*************** -->
<xacro:link_block link="base_link" xyz="0 0 0.016" rpy="0 0 0" filename="kuka_base_plate.dae" material="Grey"/>
<!-- ***************Kuka A1 Joint***************** -->
<xacro:link_block link="a1" xyz="0 0 0.016" rpy="0 0 0" filename="a1.dae" material="Orange"/>
<joint name="base_a1" type="fixed">
<parent link="base_link"/>
<child link="a1"/>
</joint>
<!-- ***************Kuka A2 Joint**************** -->
<xacro:link_block link="a2" xyz="0 0 0" rpy="0 0 0" filename="a2.dae" material="Orange"/>
<xacro:rev_joint_block parent="a1" child="a2" xyz="0 0 0.3265" rpy="0 0 0" lower="-2.96706" upper="2.96706"/>
<xacro:transmission_block parent="a1" child="a2"/>
<!-- ***************Kuka E1 Joint**************** -->
<xacro:link_block link="e1" xyz="0 0 0" rpy="0 0 0" filename="e1.dae" material="Orange"/>
<xacro:rev_joint_block parent="a2" child="e1" xyz="0 0 0" rpy="1.5707 3.14159 0" lower="0" upper="3.14159"/>
<xacro:transmission_block parent="a2" child="e1"/>
<!-- ***************Kuka A3 Joint**************** -->
<xacro:link_block link="a3" xyz="0 0 0" rpy="0 0 0" filename="a3.dae" material="Orange"/>
<xacro:rev_joint_block parent="e1" child="a3" xyz="-0.4 0 0" rpy="-1.5707 0 1.5707" lower="-2.0944" upper="2.0944"/>
<xacro:transmission_block parent="e1" child="a3"/>
<!-- ***************Kuka A4 Joint**************** -->
<xacro:link_block link="a4" xyz="0 0 0" rpy="0 0 0" filename="a4.dae" material="Orange"/>
<xacro:rev_joint_block parent ... (more) |
2016-07-14 09:30:36 -0500 | received badge | ● Famous Question
(source)
|
2016-07-14 08:53:51 -0500 | commented question | Install library in ros When I do that I get an error that says this: CMake Error at robsim/robsim_gazebo/CMakeLists.txt:214 (target_link_libraries):
Cannot specify link libraries for target "publisher_node" which is not
built by this project.
|
2016-07-13 07:50:26 -0500 | commented answer | Install library in ros What I mean by install is that I want to use the .c and .h files from ulapi (which is what we use to talk to the robot arms we have in the lab) in my c++ code I have written. I am familiar with the way you install libraries for arduino if that is of any help. |
2016-07-13 07:48:53 -0500 | commented question | Install library in ros The files I have are C and H. I am use to installing libraries for Arduino and was wondering how to do it for ROS. |
2016-07-12 07:36:52 -0500 | received badge | ● Notable Question
(source)
|
2016-07-12 04:37:18 -0500 | received badge | ● Popular Question
(source)
|
2016-07-11 14:53:13 -0500 | commented answer | Gazebo & ROS Subscriber and Publisher C++ I managed to get it working without using a plugin. Thanks for your time and help! |
2016-07-11 14:51:52 -0500 | asked a question | Install library in ros I am wondering how I would incorporate a library in ROS. The library I am trying to install is called ulapi to communicate with the kuka robot we have in the lab. Thanks Update (7.13.16):
Here is part of my code that I am trying to add the ulapi library. Might be useful. #include <ros/ros.h>
//library for type of message sent to gazebo topics
#include <std_msgs/Float64.h>
//libraries to control model in gazebo
#include <geometry_msgs/Pose.h>
#include <geometry_msgs/Twist.h>
#include <gazebo_msgs/ModelState.h>
#include <gazebo_msgs/SetModelState.h>
#include <cstdlib>
#include <robsim_gazebo/ulapi.h>
int main (int argc, char** argv)
{
//initialize node
ros::init(argc, argv, "publisher_node");
//create node handle
ros::NodeHandle rob_pose;
ros::NodeHandle a1a2;
ros::NodeHandle a2e1;
ros::NodeHandle e1a3;
ros::NodeHandle a3a4;
ros::NodeHandle a4a5;
ros::NodeHandle a5a6;
ros::NodeHandle a6tp;
Here is the part of my CMakeLists.txt file add_library(unix_ulapi src/unix_ulapi.c)
#target_link_libraries(publisher_node unix_ulapi)
add_library(ulapi_getopt src/ulapi_getopt.c)
#target_link_libraries(publisher_node ulapi_getopt)
|
2016-07-07 07:34:09 -0500 | received badge | ● Notable Question
(source)
|
2016-07-06 16:23:04 -0500 | received badge | ● Popular Question
(source)
|
2016-07-06 14:40:35 -0500 | received badge | ● Editor
(source)
|
2016-07-06 14:12:25 -0500 | commented answer | Writing publisher c++ code |
2016-07-06 12:35:47 -0500 | asked a question | Writing publisher c++ code Im trying to write c++ code to publish joint angles to have Gazebo update the model. I am getting this error message: Client [/gazebo] wants topic /kuka/a1_a2_joint_position_controller/command to have datatype/md5sum [std_msgs/Float64/...], but our version has [trajectory_msgs/JointTrajectoryPoint/...]. Dropping Connection
My knowledge of C++ is limited and the version of ROS im using is Indigo and Gazebo is 2.2.3 Here is the code I have written for the publisher: {
ros::init(argc, argv, "publisher_node");
ros::NodeHandle p;
ros::Publisher a1_a2_pub = p.advertise<trajectory_msgs::JointTrajectoryPoint>("/kuka/a1_a2_joint_position_controller/command", 1000);
ros::Rate rate(10);
while (ros::ok())
{
trajectory_msgs::JointTrajectoryPoint msg; //= new trajectory_msgs::JointTrajectoryPoint();
msg.positions.resize(6);
msg.positions[0] = 1.0;
a1_a2_pub.publish(msg);
//ROS_INFO_STREAM("Sending position command" << msg.positions[0]);
rate.sleep();
ros::spinOnce();
}
return 0;
}
UPDATE:
Here is the working final code: #include "ros/ros.h"
#include "std_msgs/Float64.h"
#include <iostream>
#include "trajectory_msgs/JointTrajectory.h"
#include <cstdlib>
int main (int argc, char** argv)
{
ros::init(argc, argv, "publisher_node");
ros::NodeHandle a1a2;
ros::NodeHandle a2e1;
ros::NodeHandle e1a3;
ros::NodeHandle a3a4;
ros::NodeHandle a4a5;
ros::NodeHandle a5a6;
ros::NodeHandle a6tp;
ros::Publisher a1_a2_pub = a1a2.advertise<std_msgs::Float64>("/kuka/a1_a2_joint_position_controller/command", 1000);
ros::Publisher a2_e1_pub = a2e1.advertise<std_msgs::Float64>("/kuka/a2_e1_joint_position_controller/command", 1000);
ros::Publisher e1_a3_pub = e1a3.advertise<std_msgs::Float64>("/kuka/e1_a3_joint_position_controller/command", 1000);
ros::Publisher a3_a4_pub = a3a4.advertise<std_msgs::Float64>("/kuka/a3_a4_joint_position_controller/command", 1000);
ros::Publisher a4_a5_pub = a4a5.advertise<std_msgs::Float64>("/kuka/a4_a5_joint_position_controller/command", 1000);
ros::Publisher a5_a6_pub = a5a6.advertise<std_msgs::Float64>("/kuka/a5_a6_joint_position_controller/command", 1000);
ros::Publisher a6_tp_pub = a6tp.advertise<std_msgs::Float64>("/kuka/a6_tp_joint_position_controller/command", 1000);
//ROS_INFO_STREAM("PUBLISHER");
ros::Rate rate(10);
while (ros::ok())
{
std_msgs::Float64 a1a2msg;
std_msgs::Float64 a2e1msg;
std_msgs::Float64 e1a3msg;
std_msgs::Float64 a3a4msg;
std_msgs::Float64 a4a5msg;
std_msgs::Float64 a5a6msg;
std_msgs::Float64 a6tpmsg;
//ROS_INFO_STREAM("OBJECT");
a1a2msg.data = rand() % 2 + -2;
a2e1msg.data = rand() % 3 + 0;
e1a3msg.data = rand() % 2 + -2;
a3a4msg.data = rand() % 2 + -2;
a4a5msg.data = rand() % 2+ -2;
a5a6msg.data = rand() % 2 + -2;
a6tpmsg.data = rand() % 2 + -2;
ROS_INFO_STREAM("A1 / A2: " << a1a2msg.data);
ROS_INFO_STREAM("A2 / E1: " << a2e1msg.data);
ROS_INFO_STREAM("E1 / A3: " << e1a3msg.data);
ROS_INFO_STREAM("A3 / A4: " << a3a4msg.data);
ROS_INFO_STREAM("A4 / A5: " << a4a5msg.data);
ROS_INFO_STREAM("A5 / A6: " << a5a6msg.data);
ROS_INFO_STREAM("A6 / TP: " << a6tpmsg.data);
a1_a2_pub.publish(a1a2msg);
a2_e1_pub.publish(a2e1msg);
e1_a3_pub.publish(e1a3msg);
a3_a4_pub.publish(a3a4msg);
a4_a5_pub.publish(a4a5msg);
a5_a6_pub.publish(a5a6msg);
a6_tp_pub.publish(a6tpmsg);
//ROS_INFO_STREAM("PUBLISH");
rate.sleep();
ros::spinOnce();
}
return 0;
}
|
2016-07-06 12:26:54 -0500 | commented answer | Gazebo & ROS Subscriber and Publisher C++ Update:
I was able to get the subscriber working and now I am having issues with the publisher. |
2016-07-06 08:37:36 -0500 | received badge | ● Enthusiast
|
2016-07-05 12:36:03 -0500 | commented question | Joint Control in Baxter using ROS in C++ Hi, I am wondering if you could send me your code for the subscriber. I am also a beginner and trying to get a subscriber and publisher thing going as well. Thanks. |
2016-07-05 09:56:37 -0500 | commented answer | Gazebo & ROS Subscriber and Publisher C++ I apologize if what I wrote is confusing. I am not a computer science major. Is there anything I can provide that would be helpful in clearing whether I would need a gazebo plugin or not. I would like to stay away from plugins if possible since my programming knowledge is limited. |
2016-07-02 09:49:14 -0500 | received badge | ● Popular Question
(source)
|
2016-06-30 08:51:43 -0500 | asked a question | Gazebo & ROS Subscriber and Publisher C++ Hello all, I am new to ROS and I am trying to write a subscriber and publisher c++ code to talk with Gazebo. I want to get the states of each link and be able to publish to each link to control its joint angles. I was successfully able to control my model in Gazebo via a rostopic pub command and am struggling to write a c++ code to do the same. Similarly, I have not been able to write any code to get the link states. I was able to get code working to subscribe to the /joint_states, but this does not reflect the link states in Gazebo. Any help would be appreciated! Ubuntu: 14.04 LTS
ROS: Indigo
Gazebo: 2.2.3 |
2016-06-30 08:46:32 -0500 | marked best answer | Does Rviz have collision detection like gazebo? I am wondering if rviz has a collision detection system similar to gazebo implemented. I see that there is an option to enable collision, but I have not found and information online about what it does exactly. Ubuntu 14.04 LTS
ROS: Indigo |