Difference between revisions of "SDK Concepts"

Jump to: navigation , search
Line 69: Line 69:
  
 
</div>
 
</div>
 
<div class="content-block">
 

Revision as of 21:18, 17 November 2016

This page contains a list of Concepts summarizing the basic functionality of the SDK on Intera

Development Environment

Throughout the Wiki, Tutorials, and SDK, we refer to the "SDK Shell" and your "ROS Workspace" or "Environment". These are simple environment concepts and configurations that are useful to have a basic understanding of when using the Baxter SDK and ROS.

  • ROS Workspace
    Your "ROS Workspace" (also called a "Catkin Workspace" in the ROS world), is the ~/ros_ws/ directory you setup in the Getting Started Tutorials. Inside the src/ sub-directory, you can create or checkout source code as ROS Packages (such as the baxter sdk packages), which you can then compile and link against via the devel/ or install/ sub-directories.
  • SDK Shell
    The SDK Shell is a term we use to refer to a session in a shell, or Terminal, with the ROS Environment Variables properly configured to point to your ROS Workspace, the Baxter Robot, and your computer's ROS ID.
    The baxter.sh file is the script you setup to take care of configuring all that for you.

    You need to be in a proper RSDK Shell before you use most of the ROS tools or run any of the SDK examples or programs. Therefore you should run the ./baxter.sh script at the start of each Terminal session. All the script does is start a convenient "sub-shell" that fills in the necessary Environment Variables as you configured.
  • Environment Variables
    The ROS Environment Variables have three important functions:
    1. Identifying your Baxter and Workstation on the ROS Network, based on your Network Configuration.
    2. Pointing to the path of the ROS Packages, tools, and programs, when you use rosrun (execute programs).
    3. Linking to the libraries and workspaces when compiling source code.


If you are new to the ROS world, it is highly recommended you take the time to go through the Beginner Level Core ROS Tutorials. My personal recommendation is to at least do:

  • The first few Configure through 'Understanding ROS' tutorials - (Remember: we use ~/ros_ws/ instead of ~/catkin_ws/ but they are exactly the same).
  • Also, the 'Writing a Simple Publisher and Subscriber' tutorials can be pretty useful when it comes to writing your first ROS program for the ROS newbie.

Writing Programs

At the core of the SDK are the interfaces provided to control and access all of the Baxter Research Robot's motors and sensors. These sections describe the hardware components of the robot and the foundation API layers upon which the SDK - and your programs - are built. These sections describe the Components of the Robot, and the Interfaces to control them.

SDK Foundations (Interfaces)

The SDK provides interfaces that control the robot hardware layer via the Robot Operating System (ROS) to any other computers on the robot's network. By using the ROS network layer API, any client library or program that can "speak ROS" can control the robot directly. For a deeper understanding of the SDK System architecture see:

By using the foundation ROS interface layer, the robot can be controlled and programmed in any Programming Language that supports ROS. This has led to a number of user-created interface libraries in different languages. In addition, the Python Baxter Interface provides a Python Class-based interface library, which wraps many of the ROS interfaces in Python Classes.

ROS Interface

The ROS Interface is the foundation upon which all interaction with the Baxter Research Robot passes through and all other interface layers are built upon. The ROS layer is accessible over the network via any of the standard ROS Client Libraries such as rospy (Python) or roscpp (C++).

  • ROS API Reference
    The ROS API describes the base interface layer for direct access from the command line or any language.

Python Interface

The Baxter SDK also offers a Python API via the baxter_interface module. This module wraps the ROS Interfaces in component-based Python Classes. The SDK Examples are written using this library in order to demonstrate how to use the robot interfaces.

  • Robot Interface Overview
    Gives a basic introduction to each class and component in the Python interface library 'baxter_interface'.
  • Code API
    View the generated Python Code API docs for the baxter_interface module.

Robot Hardware Foundations

To learn more about what sensors and motors are on the robot and how to use them, see:

When you have run through the Installation procedures and you've established communication with your robot, it is time to start getting familiar with the SDK interface. This page will walk you through the basics of using the SDK.