IE-482-582 / fall2021

5 stars 4 forks source link

Notebook Questions #8

Open TonyCostanzo opened 3 years ago

TonyCostanzo commented 3 years ago

Open thread for all of us to post questions we've recorded in our student_workbook.md files.

TonyCostanzo commented 3 years ago

Chapter 1 -- Introduction

1) I guess I don't fully understand what ROS is phsyically. Is it a database stored somewhere with heaps of code similar to a 'Stack Overflow, is it some massive synthesizer that utilizes a series of different compilers to allow code from a multitude of different languages? Simply put, what does "a framework" mean physically in regard to ROS?

Chapter 2 -- Preliminaries

1) Is the running 'roscore' unique to the machine it was started on?

2) How does the 'listener' node know to listen to 'talker' or is 'listener' just a generic listening node that would receive input from anything chatting?

Chapter 3 -- Topics

1) (Pg. 33) What does it mean we have to add a dependency to the package.xml file? Is this done concurrently with writing this example node? If so where does this dependdency tag go?

2) What does: "Usage: rosrun [--prefix cmd] [--debug] PACKAGE EXECUTABLE [ARGS] rosrun will locate PACKAGE and try to find an executable named EXECUTABLE in the PACKAGE tree. If it finds it, it will run it with ARGS." mean in plain English?

Danealor commented 3 years ago

Ah yes, I will post some of my own questions here as well. In the meantime, I think I can answer a few of @TonyCostanzo's questions with the knowledge I have so far.

Chapter 1

  1. From what I understand, ROS as a robotics framework acts in a similar manner as Unity or Unreal Engine do as game development frameworks. It is a set of code, present on your machine I believe in /opt/ros/noetic as it were installed. This code and programs are responsible for mediating the registrations of the nodes within the network, tying different modules together and generally providing an incredibly extensive boilerplate base that allows us to build up our robot code almost like lego pieces. I believe you are correct about the compilation part, I think that's catkin's job mostly.

Chapter 2

  1. The 'listener' node registers for a message type (topic) called "chatter" with a data type of String. The 'talker' node publishes a topic called "chatter". Like fate-bound lovers they find each other (through roscore giving each of them the others' address) and start talking to each other.

In listener.py:

rospy.Subscriber("chatter", String, callback)
jhulburt commented 3 years ago

Textbook Chapters

Chapter 1 -- Introduction

Chapter 2 -- Preliminaries


Chapter 3 -- Topics

Chapter 4 -- Services


TonyCostanzo commented 3 years ago

Chapter 4 -- Services

Q 4.1) On page 55, the callback function evidently takes type WordCountRequest, but the script only has request in the parameters of the count_words function call. How do these two types relate?