Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

To create custom functionality, such as new sensors or functions on the robot, or a new type of data processing such witch custom object detection system, you will need to create your own component. This component can then be used in your SIC programs.

Creating a component requires the following steps

  1. Choosing component type for your application (See flowchart)

  2. Choosing inputs datatypes (See SIC standardized pre-defined messages)

  3. Creating a new file following the templates (See https://bitbucket.org/socialroboticshub/framework/src/master/sic_framework/services/templates/)

  4. Implement the appropriate methods.

  5. Start the component (python your_file.py)

At its core, any new component (exteding SICComponent) has to implement on_message and/or on_request. on_message allows the component to be linked to one another, and receive and send messages in a data stream. on_request allows it to handle requests and send an explicit reply to the device that requested it.

...

Use this flowchart to help you determine which type of component class your component should extend:

...

There

are Make sure to use predifined messages where possible to ensure interoperability between your component and others. See SIC standardized pre-defined messages, see X for an overview.