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

problem with p2os teleop

asked 2012-07-26 22:30:16 -0500

Park gravatar image

updated 2012-07-26 22:56:47 -0500

I have pioneer 3-AT robot. It connected my notebook with serial to usb cable. ROS fuerte has installed in my notebook with Ubutu 11.10. I installed p2os referred to p2os_tutorial.

When I launch the p2os teleop_keyboard, it works well, but pioneer doesn't move. The motor is fully enabled with p2os_dashboard. p2os teleop_joy has the same problem. The pioneer beeps only..in regularly.

Could you give me a help?


  • roscore
jhp@ubuntu:~$ roscore
... logging to /home/jhp/.ros/log/5d906d6c-d7c3-11e1-9b40-001d728c5b11/roslaunch-ubuntu-19950.log
Checking log directory for disk usage. This may take awhile.
Press Ctrl-C to interrupt
Done checking log file disk usage. Usage is <1GB.

started roslaunch server http://ubuntu:47612/
ros_comm version 1.8.10

SUMMARY
========

PARAMETERS
 * /rosdistro
 * /rosversion

NODES

auto-starting new master
process[master]: started with pid [19966]
ROS_MASTER_URI=http://ubuntu:11311/

setting /run_id to 5d906d6c-d7c3-11e1-9b40-001d728c5b11
process[rosout-1]: started with pid [19979]
started core service [/rosout]
  • Run the p2os_driver
jhp@ubuntu:~$ rosrun p2os_driver p2os 
[ INFO] [1343377049.882478998]: using serial port: [/dev/ttyUSB0]
[ INFO] [1343377049.904677981]: P2OS connection opening serial port /dev/ttyUSB0...
[ INFO] [1343377050.313218974]: SYNC0
[ INFO] [1343377050.513818710]: turning off NONBLOCK mode...
[ INFO] [1343377050.714331842]: SYNC1
[ INFO] [1343377051.114779904]: SYNC2
[ INFO] [1343377051.715227279]: Done: Connected to Samtronics3233, a Pioneer p3at-sh
[ INFO] [1343377054.118100925]: resetting raw positions
  • Run teleop_keyboard
jhp@ubuntu:~$ roslaunch p2os_launch teleop_keyboard.launch 
... logging to /home/jhp/.ros/log/5d906d6c-d7c3-11e1-9b40-001d728c5b11/roslaunch-ubuntu-21208.log
Checking log directory for disk usage. This may take awhile.
Press Ctrl-C to interrupt
Done checking log file disk usage. Usage is <1GB.

started roslaunch server http://ubuntu:55497/

SUMMARY
========

PARAMETERS
 * /p2os_teleop/axis_vw
 * /p2os_teleop/axis_vx
 * /p2os_teleop/deadman_button
 * /p2os_teleop/run_button
 * /rosdistro
 * /rosversion
 * /spawn_teleop_keyboard/run_vel
 * /spawn_teleop_keyboard/walk_vel
 * /spawn_teleop_keyboard/yaw_rate
 * /spawn_teleop_keyboard/yaw_run_rate

NODES
  /
    p2os_teleop (p2os_teleop/p2os_teleop)
    pioneer_joy_controller (joy/joy_node)
    spawn_teleop_keyboard (pr2_teleop/teleop_pr2_keyboard)

ROS_MASTER_URI=http://localhost:11311

core service [/rosout] found
process[spawn_teleop_keyboard-1]: started with pid [21230]
Reading from keyboard
---------------------------
Use 'WASD' to translate
Use 'QE' to yaw
Press 'Shift' to run
process[p2os_teleop-2]: started with pid [21249]
process[pioneer_joy_controller-3]: started with pid [21278]
[ERROR] [1343377381.019514449]: Couldn't open joystick /dev/input/js0. Will retry every second.

-rostopic list


jhp@ubuntu:~$ rostopic list
/aio
/base_controller/command
/battery_state
/cmd_motor_state
/cmd_vel
/diagnostics
/diagnostics_agg
/dio
/gripper_control
/gripper_state
/joy
/motor_state
/p2os_teleop/cmd_vel
/p2os_teleop/des_vel
/p2os_teleop/joy
/pose
/ptz_control
/ptz_state
/rosout
/rosout_agg
/sonar
/tf
edit retag flag offensive close merge delete

4 Answers

Sort by ยป oldest newest most voted
2

answered 2012-07-30 03:28:45 -0500

It looks that /cmd_vel should be connected to /p2os_teleop/cmd_vel to make it work. You can verify the connection by using rxgraph command. If they are not connected, you can remap the topics to solve it.

Another typical problem with keyboard teleop nodes is that they require the focus on the corresponding terminal window. Otherwise, the key strokes are not received by the node.

edit flag offensive delete link more

Comments

This is also true for the ROSARIA package, where /cmd_vel should be remapped to /RosAria/cmd_vel.

RafBerkvens gravatar image RafBerkvens  ( 2013-03-20 22:22:00 -0500 )edit
0

answered 2012-07-30 03:19:11 -0500

Park gravatar image

I found that beep means not to receive command from user in two second..so I've revised pulse time(-1.0 --> 1). There are no beep now. but teleop_joy & keyboard don't work..as before. However, "$ rostopic pub /cmd_vel ...(I'm forget..)" works well..finally, pioneer moves..

There is one problem to solve teleop...I think teleop_joy.launch file has something wrong.....

anyone else give me a help?

edit flag offensive delete link more
0

answered 2012-07-30 17:08:17 -0500

Park gravatar image

Thanks you Pablo!!!

You're right. It was topic connection problem.

I added remap command in "teleop_joy.launch".

remap from="/p2os_teleop/cmd_vel" to="/cmd_vel"
and
remap from="/p2os_teleop/joy" to ="/joy"

I works well..The robot moves now..

Thanks for your help..

edit flag offensive delete link more

Comments

If it's not too much trouble, would you mind posting the rx_graph?

magnate gravatar image magnate  ( 2013-03-15 21:19:38 -0500 )edit
0

answered 2012-08-01 03:58:18 -0500

ReedHedges gravatar image

Glad you got it working. By the way, the meanings of the Pioneer beep sounds are documented here: http://robots.mobilerobots.com/wiki/Robot_Beeps

Reed

edit flag offensive delete link more

Question Tools

1 follower

Stats

Asked: 2012-07-26 22:30:16 -0500

Seen: 1,651 times

Last updated: Aug 01 '12