ROBOTIS-GIT / turtlebot3

ROS packages for Turtlebot3
http://turtlebot3.robotis.com
Apache License 2.0
1.49k stars 1.02k forks source link

Navigating unexplored environment with turtlebot3 burger #892

Open PhilipAmadasun opened 2 years ago

PhilipAmadasun commented 2 years ago

ISSUE TEMPLATE ver. 0.4.0

  1. Which TurtleBot3 platform do you use?

    • [Yes ] Burger
    • [ ] Waffle
    • [ ] Waffle Pi
  2. Which ROS is working with TurtleBot3? Melodic

    • [ ] ROS 1 Kinetic Kame
    • [Yes ] ROS 1 Melodic Morenia
    • [ ] ROS 1 Noetic Ninjemys
    • [ ] ROS 2 Dashing Diademata
    • [ ] ROS 2 Eloquent Elusor
    • [ ] ROS 2 Foxy Fitzroy
    • [ ] etc (Please specify your ROS Version here)
  3. Which SBC(Single Board Computer) is working on TurtleBot3?

    • [ ] Intel Joule 570x
    • [ Yes] Raspberry Pi 3B+
    • [ ] Raspberry Pi 4
    • [ ] etc (Please specify your SBC here)
  4. Which OS you installed on SBC?

    • Yes[ ] Raspbian distributed by ROBOTIS
    • [ ] Ubuntu MATE (16.04/18.04/20.04)
    • [ ] Ubuntu preinstalled server (18.04/20.04)
    • [ ] etc (Please specify your OS here)
  5. Which OS you installed on Remote PC?

    • [ ] Ubuntu 16.04 LTS (Xenial Xerus)
    • [Yes ] Ubuntu 18.04 LTS (Bionic Beaver)
    • [ ] Ubuntu 20.04 LTS (Focal Fossa)
    • [ ] Windows 10
    • [ ] MAC OS X (Specify version)
    • [ ] etc (Please specify your OS here)
  6. Specify the software and firmware version(Can be found from Bringup messages)

    • Software version: [x.x.x]
    • Firmware version: [x.x.x]
  7. Specify the commands or instructions to reproduce the issue.

    • HERE
  8. Copy and Paste the error messages on terminal.

    • HERE
  9. Please describe the issue in detail.

I'm trying to figure out what I can't set way points on unexplored environments while SLAM is on.In the Rviz, when I click the map with "2D Nav Goal", nothing happens, even on the parts of the mpa that SLAM has discovered. Is there a parameter in one of the turtlebot3 config files I have to set?

My test code also doesnt work either.

#/usr/bin/python2.7
import rospy
import math
from move_base_msgs.msg import MoveBaseActionGoal
from geometry_msgs.msg import PoseStamped
from nav_msgs.msg import Odometry
from nav_msgs.msg import OccupancyGrid
from nav_msgs.msg import Path

goal= PoseStamped()
goal.header.stamp = rospy.get_rostime()
goal.header.frame_id = 'map'
goal.pose.position.x = 1.203
goal.pose.position.y = -0.4769
goal.pose.position.z = 0

goal.pose.orientation.x = 0
goal.pose.orientation.y = 0
goal.pose.orientation.z = 0
goal.pose.orientation.w = 1

def callback(msg):
    pass

rospy.init_node("control")
pub = rospy.Publisher("goal", PoseStamped, queue_size=1, latch=True)
rospy.Subscriber("/odom", Odometry, callback)

while not rospy.is_shutdown():
    pub.publish(goal)
    rospy.sleep(10.5)
    goal.pose.position.x = 0.203
    goal.pose.position.y = -0.4769
    pub.publish(goal)
    rospy.sleep(10.5)

My launch file I use to run this code:

<launch>
    <node pkg="action_practice" type="tester.py" name="control"    ns="move_base_simple" output="screen"/>
</launch> 
ROBOTIS-Ashe commented 2 years ago

@PhilipAmadasun Sorry for the late reply You need to launch the Navigation node to activate the 2D Nav Goal. Please refer to the attached link and launch the Navigation. Unfortunately, Turtlebot3 provides technical support only for the official package. Thank you for your understanding.