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

tercelkisor's profile - activity

2017-11-08 15:41:37 -0500 received badge  Famous Question (source)
2017-11-08 15:41:37 -0500 received badge  Notable Question (source)
2016-05-24 18:07:15 -0500 commented question Husky navigation stack setup

did you ever get this to work? I'm currently having trouble with the navigation stack and husky

2016-05-24 14:27:29 -0500 received badge  Commentator
2016-05-24 14:27:29 -0500 commented answer Navigation with Clearpath Husky

I have looked at sending simple goals, but I haven't tried anything since I don't even have the navigation stack running.

2016-05-24 13:27:01 -0500 commented answer Navigation with Clearpath Husky

It's like I said earlier. It's not that simple stuff that I have an issue with. I guess I don't see how any of the tutorials are helpful for the navigation stack. It seems like there is some other knowledge that isn't covered in the tutorials.

2016-05-24 13:25:42 -0500 commented answer Navigation with Clearpath Husky

I' know that that is how you start the physical husky. I don't know how to make the physical husky work from the navigation stack tutorial.

2016-05-24 13:21:15 -0500 commented question Navigation with Clearpath Husky

I mean that it has no GUI. It is the server version of ubuntu, i guess. I already can do what that tutorial teaches. I can sub and pub from with computer. I can even run rviz, but I guess I am doing something else wrong.

2016-05-24 13:14:24 -0500 commented answer Navigation with Clearpath Husky

I'll give it another shot. If the husky_bringup already has the gps and imu as dependencies, could I just include that package to cover the move_base, gps, and imu all in one? I think I read that on the navigation tutorial.

2016-05-24 07:48:09 -0500 received badge  Famous Question (source)
2016-05-22 19:02:17 -0500 answered a question Navigation with Clearpath Husky

I just need an example of what this:

catkin_create_pkg my_robot_name_2dnav move_base my_tf_configuration_dep my_odom_configuration_dep my_sensor_configuration_dep

would look like for a clearpath husky. Anyone?

2016-05-22 14:28:33 -0500 received badge  Scholar (source)
2016-05-21 06:25:34 -0500 received badge  Notable Question (source)
2016-05-20 15:32:16 -0500 commented answer Navigation with Clearpath Husky

can the parameter arguments just be listed in any order? The wording is what is confusing me.

2016-05-20 12:46:34 -0500 answered a question Navigation with Clearpath Husky

Hi Icehawk. Thanks for the response. I have a few more questions. How would I go about adapting this demo for use on a real husky? I've been through the catkin tutorials, and basically understand how to create a workspace, but the format, naming, and choice of dependencies is what I don't get. I'm running indigo, so that's good, but the computer on the husky only has a terminal output, so I couldn't use rviz. I've tried running it from the remote pc that I ssh into the husky from, but I've had no luck with that. It seems like the tutorials are really good at teaching you to run demos or creating very simple nodes and whatnot, but it's not very helpful when doing things more complicated than basic publishers and subscribers. Thanks again.

2016-05-20 12:31:14 -0500 received badge  Popular Question (source)
2016-05-19 20:52:38 -0500 asked a question Navigation with Clearpath Husky

Hello all,

I am currently working on getting a Husky to navigate to GPS coordinates. I was able to do a simple version by writing a simple script that subscribes to GPS and magnetometer data and publishes velocity commands. Now I need to take advantage of the navigation stack to implement obstacle avoidance and more robust navigation, but I'm honestly at a loss. I have read through the navigation tutorial, and they lose me when they say:

catkin_create_pkg my_robot_name_2dnav move_base my_tf_configuration_dep my_odom_configuration_dep my_sensor_configuration_dep

I understand conceptually what it means. I just don't know what to put there. The same goes for making the launch file. Currently the husky publishes these topics:

/diagnostics
/diagnostics_agg
/diagnostics_toplevel_state
/gps/fix
/gps/nmea_sentence
/gps/nmea_sentence_out
/gps/time_reference
/gps/vel
/imu/data
/imu/data_raw
/imu/mag
/imu_filter/parameter_descriptions
/imu_filter/parameter_updates
/imu_manager/bond
/imu_um6/data
/imu_um6/mag
/imu_um6/rpy
/imu_um6/temperature
/joy_teleop/cmd_vel
/joy_teleop/joy
/odometry/filtered
/odometry/gps
/rosout
/rosout_agg
/status
/tf
/tf_static

I have attached a Hokuyo UG01 laser to it, and it publishes a topic called /scan which I am able to subscribe to with a simple python script.

From my current understanding, I need to :
1. Get the laser node to launch with the other nodes on startup
2. Create the catkin workspace with all the correct dependencies (very lost on that one)
3. Create launch files for the required nodes. (Maybe 1 and 3 are overlapping?)
4. ??? Maybe do something with tf?

That's where my understanding breaks down, I think.

I would greatly appreciate any help on this. It's due in three weeks and I am stressing out.

To give a bigger picture, the ultimate goal of the project is to have the husky navigate to GPS coordinates, then, at that location, read a color sequence using open cv or something similar (haven't done too much with that part yet), then travel to colored cones in the order of the color sequence that was read. For example, the lights flash red, green, blue, and the husky finds the red cone, travels to it, then the green, and so on. Thanks again for the help.

EDIT:

Hi Icehawk. Thanks for the response. I have a few more questions. How would I go about adapting this demo for use on a real husky? I've been through the catkin tutorials, and basically understand how to create a workspace, but the format, naming, and choice of dependencies is what I don't get. I'm running indigo, so that's good, but the computer on the husky only has a terminal output, so I couldn't use rviz. I've tried running it from the remote pc that I ssh into the husky from, but I've had no luck with that. It seems like the tutorials are really good at teaching you to run demos or creating very simple nodes and whatnot, but it's not very helpful when doing things more complicated than basic publishers and subscribers. Thanks again.

2016-05-12 13:47:11 -0500 received badge  Enthusiast
2016-05-11 16:17:26 -0500 received badge  Editor (source)
2016-05-03 05:12:43 -0500 received badge  Popular Question (source)
2016-04-24 14:48:43 -0500 commented answer Multiple subscribers and single publisher in one python script?

I think I've decided to go this route. I've never used classes before, so I'll do a little reading on that first. Thanks.

2016-04-24 14:47:49 -0500 commented answer Multiple subscribers and single publisher in one python script?

Yes, I tried the while loop. It sort of works, but it won't stop the script when I crtl+c.

2016-04-24 14:46:01 -0500 received badge  Famous Question (source)
2016-04-20 13:12:27 -0500 commented answer Multiple subscribers and single publisher in one python script?

So I removed the rospy.spin(), and the script just closes itself after printing "lat = 0 long = 0" I've read that the spin function is required to keep the script from "jumping out or something.

2016-04-20 02:19:38 -0500 received badge  Notable Question (source)
2016-04-19 12:24:27 -0500 received badge  Popular Question (source)
2016-04-19 10:13:16 -0500 received badge  Student (source)
2016-04-19 09:53:30 -0500 commented answer Multiple subscribers and single publisher in one python script?

I've edited my question.

2016-04-18 22:41:00 -0500 asked a question Multiple subscribers and single publisher in one python script?

I'm having issues with getting this to work. What I need to do is pull magnetometer data from the imu topic, pull gps data from gps topic, do calculations, and publish to cmd_vel topic. It seems like it would be simple, but I can't seem to get it to work. I can get both subscribers and the publisher to work simoultenously, but I cannot get the data to play together, and I'm pretty sure i'm getting stuck in a callback function.

My code is currently printing my bearing and heading, but it isn't moving, and I'm not sure what else I can try.

My most recent code:

    #!/usr/bin/env python

import rospy
from geometry_msgs.msg import Twist
from geometry_msgs.msg import Vector3Stamped
from geometry_msgs.msg import Vector3

from math import radians
from sensor_msgs.msg import NavSatFix
import time
import numpy

global lat1
global long1


def call_head(um6):

    global heading
    global bearing 

    r = rospy.Rate(5);
    # rospy.loginfo("Bearing: %s", um6.vector)          #Print mag reading for bearing
    z = um6.vector.z
    y = um6.vector.y

    angles = Vector3()

    heading = numpy.rad2deg(numpy.arctan2(z, y)) + 90

    angles.x = heading
    angles.z = bearing

    call_bear_pub = rospy.Publisher("navStuff", Vector3, queue_size=10)


    call_bear_pub.publish(angles)


    r.sleep()
    return "done heading"


def call_nav(navsat):

    global heading
    global bearing 

    global lat1
    global long1


    r = rospy.Rate(5);
    # rospy.loginfo("Latitude: %s", navsat.latitude)        #Print GPS co-or to terminal
    # rospy.loginfo("Longitude: %s", navsat.longitude)

    angles = Vector3()

    lat1 = navsat.latitude
    long1 = navsat.longitude

    ###########################################################
    lat2 = 30.210406
    #                                   Destination
    long2 = -92.022914
    ############################################################

    dLon = long2 - long1
    y = numpy.sin(dLon) * numpy.cos(lat2)
    x = numpy.cos(lat1)*numpy.sin(lat2) - numpy.sin(lat1)*numpy.cos(lat2)*numpy.cos(dLon)

    bearing = (numpy.rad2deg(numpy.arctan2(y, x)) + 360) % 360

    angles.z = bearing

    call_nav_pub = rospy.Publisher("navStuff", Vector3, queue_size=10)

    # if (heading != 0):
    #   call_nav_pub.publish(angles)
    # else:
    #   pass



    r.sleep()
    return "done bearing"

def call_move(data):


    r = rospy.Rate(5);

    pub = rospy.Publisher('/husky_velocity_controller/cmd_vel', Twist, queue_size=10)


    move_cmd = Twist()
    turn_cmd = Twist()

    ###########################################################
    lat2 = 30.210406
    #                                   Destination
    long2 = -92.022914
    ############################################################



    move_cmd.linear.x = 2
    turn_cmd.angular.z = radians(45)


    heading = data.z
    bearing = data.x



    turn_angle = heading - bearing

    rospy.loginfo("bearing: %s", bearing)
    rospy.loginfo("heading: %s", heading)


    if (turn_angle > 180):
        turn_angle -= 360
    elif (turn_angle < -180):
        turn_angle += 360
    else:
        turn_angle = turn_angle

    if (abs(lat1-lat2)<.0005 and abs(long1-long2)<.0005):
        pub.publish(Twist())
        r.sleep()
    else:
        if (abs(turn_angle) < 8):
            pub.publish(move_cmd)
            rospy.spin()
        else:
            pub.publish(turn_cmd)
            r.sleep()
    return "done move"      



def run():
    rospy.init_node('navigate_that_husky')
    rospy.Subscriber("/imu_um6/mag", Vector3Stamped, call_head)
    rospy.Subscriber("/gps/fix", NavSatFix, call_nav)
    rospy.Subscriber("navStuff", Vector3, call_move)

    rospy.spin()


if __name__ == '__main__':
    run()

That's actually what I tried first, bit I couldn't get it to work. I switched to this method because of this

I'm sure I just don't understand how to use global variables enough. I'll post a simple version my attempt at using global variables.

#!/usr/bin/env python

import rospy
from ...
(more)
2016-03-02 02:33:23 -0500 asked a question Simple GPS logging with Husky

Hello all,

I am currently attempting to have a husky move in some arbitrary path (a square for now) while logging or the GPS coordinates at each turn. I'm new to python and ros, and c++ is totally foreign to me, so it's a little overwhelming. I've been able to write a script that moves a simulated husky around however I like, but the GPS part is stumping me.

I've read through so many questions and wiki pages, but I think I'm just no familiar enough with ros to even understand exactly what I'm reading. Could someone provide a breakdown of each sub-task that must be completed to accomplish my goal?

please be as basic as possible. I'm not even positive that I'm creating a work space correctly, though I guess running a python script that controls the husky means that something is right.

Here is a version of my code with some GPS quesswork added in. I know it's probably not even close.

square w/ gps attempt1

thanks