Are you the publisher? Claim or contact us about this channel

Embed this content in your HTML


Report adult content:

click to rate:

Account: (login)

More Channels

Channel Catalog

Articles on this Page

(showing articles 41 to 42 of 42)
(showing articles 41 to 42 of 42)

Channel Description:

Open source question and answer forum written in Python and Django

older | 1 | 2 | (Page 3)

    0 0
  • 07/27/18--07:36: Controller for robots
  • Hi, i found two ways to setup a controller to drive around with my mobile platform robot and am a bit confused. First I found the way to create a new xacro file and will it with a gazebo-tag and options for the controller:100.0/joint_base_wheel_front_leftjoint_base_wheel_front_rightjoint_base_wheel_rear_leftjoint_base_wheel_rear_right${2*0.77}${2*wheel_radius}heros_base_link130cmd_velodomodom1 Whats this file The second way is to load a controller in my gazebo launch file like that: Then I had this .yaml file for all the settings: robot_joint_publisher: type: "joint_state_controller/JointStateController" publish_rate: 50 robot_velocity_controller: type: "diff_drive_controller/DiffDriveController" left_wheel: ['joint_base_wheel_front_left', 'joint_base_wheel_rear_left'] right_wheel: ['joint_base_wheel_front_right', 'joint_base_wheel_front_right'] publish_rate: 100 pose_covariance_diagonal: [0.001, 0.001, 0.001, 0.001, 0.001, 0.03] twist_covariance_diagonal: [0.001, 0.001, 0.001, 0.001, 0.001, 0.03] cmd_vel_timeout: 0.25 # Base frame_id base_frame_id: robot_base_link # Odometry fused with IMU is published by robot_localization, so # no need to publish a TF based on encoders alone. enable_odom_tf: false # Wheel separation and radius multipliers wheel_separation_multiplier: 0.580 wheel_radius_multiplier : 0.32 # Velocity and acceleration limits linear: x: has_velocity_limits : true max_velocity : 0.9 # m/s has_acceleration_limits: true max_acceleration : 3.0 # m/s^2 angular: z: has_velocity_limits : true max_velocity : 2.0 # rad/s has_acceleration_limits: true max_acceleration : 6.0 # rad/s^2 In option 1 I added the topic to publish the odometry and so on. In the second way i didnt. Where does ROS know how to publish those things? To use all of this I have to add a transmission tag to my wheels like that. Is that right? transmission_interface/SimpleTransmissionhardware_interface/VelocityJointInterface100 Are this two described ways the same thing or does it make any difference to do it like one of this ways? Are these ways common to setup the control setting for a robot or did i do incorrect things? Thanks for your help Max

    0 0

    I'm using arduino to send values from 0.00 to 5.00 and I'm trying to read them but I get this error raise ROSSerializationException(str(e)) rospy.exceptions.ROSSerializationException: : 'required argument is not a float' when writing 'x: "0.92" this is the code, how can I convert the value to float? def __init__(self): rospy.init_node('my_tf_broadcaster') self.ser = serial.Serial('/dev/ttyACM0', 115200) self.get_odometry() def get_odometry(self): self.pub_tf = rospy.Publisher("/tf", tf.msg.tfMessage) change = 0.0 while not rospy.is_shutdown(): # Run this loop at about 10Hz rospy.sleep(0.1) message = self.ser.readline() t = geometry_msgs.msg.TransformStamped() t.header.stamp = t.header.frame_id = "odom" t.child_frame_id = "base_link" t.transform.translation.x = message.rstrip() #trying to read this value t.transform.translation.y = 1.0 t.transform.translation.z = 0.0 t.transform.rotation.x = 0.0 t.transform.rotation.y = 0.0 t.transform.rotation.z = 0.0 t.transform.rotation.w = 1.0 tfm = tf.msg.tfMessage([t]) self.pub_tf.publish(tfm)

older | 1 | 2 | (Page 3)