Ask Your Question
0

How to implement a custom teleop node?

asked 2021-09-11 14:09:28 -0500

ROS_user gravatar image

Hi everyone. I have a Raspberry Pi running ROS2 Foxy connected via usb to an Arduino Uno.

The first sends custom commands ("packets" created by me) to the other through serial (/dev/ttyACM0) in order to move a robot for 1 second every time a command is received.

Since I stay connected via SSH to the RPi, I would like to implement a node that allows me to move the robot as long as I keep certain keys pressed on my keyboard.

How can I do that? Is there a way to reuse my custom commands mechanism, or do I have to come up with something else?

edit retag flag offensive close merge delete

1 Answer

Sort by » oldest newest most voted
0

answered 2021-09-13 15:30:21 -0500

Ronro gravatar image

Try to code a callback that when you press your keyboard does something (implement the logic). There is plenty of tutorials around the ros wiki and even you could copy the code of the turtlebots tutorials. I think there was a tutorial of teleoperating it with some code but I´m not sure. Hope it helps!

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

2 followers

Stats

Asked: 2021-09-11 14:09:28 -0500

Seen: 60 times

Last updated: Sep 13 '21