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

faraziii's profile - activity

2023-04-09 20:46:13 -0500 received badge  Popular Question (source)
2022-10-10 00:56:04 -0500 asked a question launching ros navigation on SBC (computer startup) and automatically localizing the robot

launching ros navigation on SBC (computer startup) and automatically localizing the robot Hello everbody, I am using th

2022-10-10 00:56:02 -0500 asked a question launching ros navigation on SBC (computer startup) and automatically localizing the robot

launching ros navigation on SBC (computer startup) and automatically localizing the robot Hello everbody, I am using th

2022-10-10 00:35:47 -0500 received badge  Famous Question (source)
2022-06-03 09:41:21 -0500 received badge  Notable Question (source)
2022-05-12 14:22:36 -0500 received badge  Famous Question (source)
2022-03-24 17:20:19 -0500 received badge  Notable Question (source)
2022-03-08 18:14:36 -0500 received badge  Popular Question (source)
2022-03-08 07:08:59 -0500 answered a question rosserial communication breaks after certain amount of time

Hello, I had 3 Jetson Xavier. Two of the jetsons were purchased from SeedsStduio. Both of them caused the same error.

2022-03-03 06:04:20 -0500 edited question rosserial communication breaks after certain amount of time

rosserial communication breaks after certain amount of time Hello, I am working on a mobile robot that consists of Jets

2022-03-03 06:04:20 -0500 received badge  Editor (source)
2022-03-03 05:01:36 -0500 edited question rosserial communication breaks after certain amount of time

rosserial communication breaks after certain amount of time Hello, I am working on a mobile robot that consists of Jets

2022-03-03 00:26:16 -0500 asked a question rosserial communication breaks after certain amount of time

rosserial communication breaks after certain amount of time Hello, I am working on a mobile robot that consists of Jets

2022-02-15 05:01:06 -0500 received badge  Enthusiast
2022-01-20 03:56:09 -0500 commented question How to publish float64 array to a topic?

Sorry, i didn't know how to do that but someone did that for me. Thanks to him.

2022-01-20 03:55:27 -0500 commented answer How to publish float64 array to a topic?

Thank you! That's what i was missing.

2022-01-19 21:10:53 -0500 marked best answer How to publish float64 array to a topic?

Hello, I am trying to publish fake joint states on a topic. My code compiles successfully, however, it gives an error "Segmentation fault, core dumped" when is run the node. Basically, I want to publish two fake positions (0) and two velocities.

#include<ros/ros.h>
#include<std_msgs/Float64.h>
#include <sensor_msgs/JointState.h>
float lVel = 0, rVel = 0, lPos = 0, rPos = 0;

int main(int argc, char** argv){
    ros::init(argc, argv, "custom_joint_state_publisher");
    ros::NodeHandle n;
    ros::Publisher statePub = n.advertise<sensor_msgs::JointState>("measured_joint_states", 100); 
    sensor_msgs::JointState joint_values;
    ros::Rate r(10);
    while(ros::ok()){
        joint_values.header.stamp = ros::Time::now();
        joint_values.position[0] = 0 ;
        joint_values.position[1] = 0;
        joint_values.velocity.push_back(0);
        joint_values.velocity.push_back(0);
        statePub.publish(joint_values);
        r.sleep();
        ros::spinOnce();
    }
    return 0;
}

Here you can see that I am using the assignment operator and pushback() function. The segmentation fault error appears with the assignment operator only. The issue with push_back function is that instead of publishing one value (0), it publishes multiple values (array of 0s) on the topic. How to publish one 0 at a time to the topic? I am using ROS melodic, Ubuntu 18.04. Thank you!

2022-01-19 21:10:53 -0500 received badge  Scholar (source)
2022-01-19 21:09:12 -0500 received badge  Popular Question (source)
2022-01-19 13:57:55 -0500 received badge  Famous Question (source)
2022-01-19 13:57:21 -0500 commented question How to publish float64 array to a topic?

Thank you for comment. I actually went through above links but couldn't fix the issue i am facing.

2022-01-19 13:28:18 -0500 asked a question How to publish float64 array to a topic?

How to publish float64 array to a topic? Hello, I am trying to publish fake joint states on a topic. My code compiles su

2021-08-29 12:53:44 -0500 received badge  Notable Question (source)
2021-08-05 07:41:58 -0500 received badge  Popular Question (source)
2021-07-08 08:58:39 -0500 asked a question Segmentation fault (core dumped)

Segmentation fault (core dumped) Hello ROS developers, I hope you are doing well. I am trying to control individual joi