Closed AndrejOrsula closed 1 year ago
Hi @AndrejOrsula
Thank you very much for this review!! I will take all into account in the revision :+1:
Francisco
I would also like to suggest a fix for 5.1.6 Running the AvoidanceNode
The command has a typo:
ros2 launch mr2_tiago_sim.launch.py
Must be br2 instead of mr2
ros2 launch br2_tiago_sim.launch.py
Hello,
First of all, many thanks @fmrico for your effort in creating this book and putting the repository together! Similarly, congratulations on the success it has accomplished so far!
I saw your LinkedIn post about preparing the first revision, so here are my comments after reading the book.
Disclaimers: I have only read the book once — from start to finish. I did not execute/test the code examples myself, nor did I review the code in the repository/appendix. However, I went through all the code snippets that are within the main chapters — although I might have only briefly skimmed through some of them. English is not my first language, so I did not attempt to correct grammar or phrasing — except for obvious typos and missing/extra words. If unsure, take all my comments with a grain of salt and ignore them. I might be incorrect in many of them. :)
General comments
First, some very general comments.
Overall feedback
I like the conciseness of the book. It provides a good overview and guidelines about programming robots with ROS 2 without making the text appear excessively descriptive. It manages to provide extra details about certain concepts, which is welcome. It is great that the book comes with this repository containing code that is actively updated (such as the update now from
foxy
tohumble
). Similarly, the accompanying slides are great for providing an overview of each chapter/topic and I believe they will be appreciated by educators.The book also manages to dive into more complex topics that I would not initially expect from looking at the book cover (at least what I consider to be more complex). Examples of these are software testing, computer vision and behaviour trees — all of which are important topics. However, I suspect that a complete ROS beginner might get overwhelmed. Even though the book states the assumption that "Prior knowledge of ROS/ROS2 is not needed.", I think that prior knowledge (and experience) with ROS might greatly improve understanding and even be necessary for the comprehension of some details. The same applies to the prior knowledge of C++ that is necessary for comprehending the included code snippets, but this is already well-explained in the introduction — together with hyperlinks to external C++ references.
Ultimately, I agree with this statement from the book: "This book is not intended to be a new ROS2 tutorial. The ones on the official website are great!", and I think it is important that readers are aware of that. In this way, the official tutorials could serve as an introduction to ROS for complete beginners, while this book complements it nicely with concrete project examples and suggestions for development guidelines.
While reading the book, I really appreciated these kinds of suggestions and details. Here are two examples that are memorable for me:
Missing epilogue/conclusion
I feel that the book ends abruptly with no final words, which might make the reader wonder what to do after reading the book. I think it might be nice to conclude what the reader has learned and give some pointers for further learning. For example, if the reader is interested in learning more about robotic manipulation (not covered in the book), it might be worth referring the reader to MoveIt 2. And the same could be applied to other concepts, e.g. refer to Gazebo or another robotics simulator if the reader is interested in learning more about simulators.
"ROS2" vs "ROS 2"
This one might be controversial — so I will just insert some links.
Specific comments
Now for some specific comments. Each comment is linked to particular page(s). All markdown quotes
> ...
refer to text from the book on that page. Please, let me know if something is unclear.I went through existing/closed issues and tried to remove all comments that were already brought up (but apologies if I missed some).
1 | Page 6: Services
By default, ROS 2 service (client) calls are asynchronous, which I assume to be the recommended paradigm.
From relevant docs: https://docs.ros.org/en/humble/How-To-Guides/Sync-Vs-Async.html ("It is not recommended to implement a synchronous service client. They are susceptible to deadlock ...")
This description of services from docs might be more suitable: https://docs.ros.org/en/humble/Tutorials/Beginner-CLI-Tools/Understanding-ROS2-Services/Understanding-ROS2-Services.html ("Services are based on a call-and-response model")
2 | Page 7: Kobuki
A reader might not know Kobuki while reading this page. Although a reference is provided and it is explained more in the next chapter, a small description might be appreciated. Saying it is a mobile robot might be enough.
3 | Page 7: "probably"
The word "probably" sounds unsure here. If there is no reason for it, I would remove the word.
4 | Page 7:
/mobile_base/commands/velocity
used by all robotsNot sure, but all mobile robots might be more correct. Outside of MoveIt Servo, I don't think I encountered these Twist messages for controlling manipulators. It is also mentioned on page 51.
5 | Page 12:
/.bashrc
It should be
~/.bashrc
(with~
),"${HOME}/.bashrc"
or other alternatives (e.g.$HOME/.bashrc
).Otherwise, the path is incorrect.
6 | Page 26: typo - "Apart of ament_cmake, always needed by colcon, just rclcpp is especified."
7 | Page 32: typo - "To compile these program, the relevant..."
8 | Page 32: incorrect
add_executable(logger_class src/logger.cpp)
In
CMakeLists.txt
snippet:This first line should be
add_executable(logger src/logger.cpp)
. Otherwise,logger
executable does not exist andlogger_class
is added twice.9 | Page 36: typo - "Last ROS2 distros lets to create launchers written in Yaml and XML"
10 | Page 36: consistency of "Yaml" vs "YAML"
In footnote 1, "Yaml" is used. However, I think that most of the book uses "YAML"?
11 | Page 36: examples of Yaml/XML launchers
It might be nice to include examples of Yaml/XML launchers (same nodes/structure used by the already included Python launcher).
On a side note, this page mentions that Python launchers typically use the extension
_launch.py
(starting with _ underscore). However, there is a mixed-use with.launch.py
(starting with . dot) within the book.12 | Page 44: pre-configured RViz2 interface?
For beginners, it might be difficult to figure out how to add panels and configure some options in RViz (even though it is explained in depth within this section). To simplify things, using a pre-configured
.rviz
config and loading it withrviz2 -d ...
could be an alternative. This is just a thought, the current approach might work well.13 | Page 48: angles grow left vs counter-clockwise
I suggest replacing left with counter-clockwise.
14 | Page 56: typo - "going forward when deteting an obstacle"
src/bump go cpp/BumpGoNode.cpp
)15 | Pages 56/57: use of constants
Although using constants is a good practice for values like
OBSTACLE_DISTANCE
andSCAN_TIMEOUT
, I think it might be beneficial to use an exact value when it is used as an example snippet within chapters of books.For example, instead of using
SCAN_TIMEOUT
in the following snippet, I would suggest using the concrete value like1.0
because I think it might improve comprehension for readers and let them know what data typeSCAN_TIMEOUT
is while reading through the chapter. Currently,SCAN_TIMEOUT
is not defined anywhere within the chapter, so a reader would need to go to the code to see what data type these constants have.16 | Page 57: suggestion to rephrase explanation of
use_sim_time
Maybe it is just me, but I think the current explanation below could be misunderstood like there is always a
/clock
topic, which contains messages that are either published by the simulator or the computer.Therefore, here is a small rephrasing suggestion:
17 | Page 62: typo - "... first launch the simuladtor by typing ..."
18 | Pages 64/65: incorrect slashes before frame names
In this section, all frames (
/base_footprint
,/base_link
,/odom
in bullet points) are prefixed with a slash (/). However, I do not think that is correct. Shouldn't it be without the namespace-like leading slash?19 | Page 78: remove redundant "use"
usequery the TF subsystem with ..."20 | Page 83: missing "of"
21 | Page 85: typo - "This is the obstacle radious in which ..."
src/br2_vff_avoidance/AvoidanceNode.cpp
)22 | Page 86: use of an incorrect word "close" -> "further"
close.23 | Page 110: merge the sentence with the previous paragraph?
This sentence is the entire second-last paragraph, so I think it could be merged with its previous paragraph.
24 | Page 118: typo - "... they use the input of the blackborad whose key ..."
25 | Page 120: missing whitespace between words "timesbefore"
26 | Page 120: missing whitespace after "Sequence:"
27 | Page 136: remove redundant "one"
oneframes should not have two parents, ..."28 | Page 149: typos in comment "Get the state of the controlled node. Ot can fail, ..."