ROS Flashcards
ROS stand for?
Robot Operating System
an open-source robotics middleware suite.
Although ROS is not an operating system (OS) but a set of software frameworks for robot software development, it provides services designed for a heterogeneous computer cluster such as hardware abstraction, low-level device control, implementation of commonly used functionality, message-passing between processes, and package management
Benefits of ROS?
- in charge of interfacing the hardware
- so you can recycle the software module
Main components of ROS communication
Node
Master
Topic
What model is used in ROS communication?
Publisher/Subscriber
*language needs to be same between publisher/subscriber
*one subscriber can subscribe to different languages
pub / sub topic
Key features of ROS
*Hardware abstraction
*Low-level device control
*Messaging between process
*package managment
in linux how to make a folder into a ROS workspace
in the folder
catkin_make
3 key components of a ROS application
*workspace
*package
*node
in linux how to create a ROS package
in the folder
catkin_create_pkg [package name] [dependencies]
e.g. catkin_create_pkg arduinobot_test roscpp rospy std_msgs
what to do after creating a new package
go back to workspace folder and
**catkin_make **
rebuld the workspace, including the new package
then
cd devel
source setup.bash
OR
source devel/setup.bash
*important: you need to source your workspace everytime you open a new terminal!
to inform ROS about the workspace and its pacakges
to prove it:
**roscd [ROS package name]
in linux in the workspace, how to run the ROS master? (like opening up the post office)
roscore
enable communication between nodes, the creation of topics, and publication of messages
flow after creating a publisher (python)
to see details like topic type, publisher, subscriber
cd to workspace
catkin_make
rosecore #to start to post office
#split terminal
cd to workspace
source devel/setup.bash
rosrun [package name] [nodename]
e.g. rosrun arduinobot_test simple_publisher.py
* to stop: ctrl+C
#split terminal
rostopic list # list existing topics
rostopic echo [topic name] #see what’s flying around in for that topic
e.g. rostopic echo /chatter
*additionally use
rostopic info [topic name] # see details like type, publisher, subscriber
e.g. rostopic info /chatter
rostopic hz [topic name] # analize frequency
3 main components of a ROS application
*workspace
*package (microfunction)
*nodo (one function) ? node
how to publish in terminal
rostopic pub [topic name] <tab></tab>