Introduction
A Smart Component is a RobotStudio object with behavior implemented by some custom code and/or by the aggregation of other components, that may or not be more Smart Components.
A Smart Component is represented by the class Smart
There are three different ways to create a Smart Component.
- By using the Smart Component Editor, available in RobotStudio.
- By using the Library Compiler together with a Library XML file.
- By using the RobotStudio API to programmatically create the component in memory. It can then be saved to a file.
Smart Component Terms
Term | Description |
---|---|
Code Behind | A .NET class associated with a Smart Component that can implement custom behavior by reacting to certain events; for example, simulation time steps and changes in property values. The class is typically located in an assembly that is embedded as an Asset. The class must inherit Smart |
Dynamic Property | A property object contained by the Smart Component, that has value, type and certain other characteristics. The property value is used by code behind to control the behavior of the Smart Component. The Dynamic Property is represented by the class Dynamic |
Property Binding | Connects the value of one property to the value of another property. The Property Binding is represented by the class Property |
Property Attributes | Key-value pairs that contain additional information about a dynamic property, for example value constraints, and hints for visualizing the property in the RobotStudio user interface. The attributes can be accessed from the Attributes. |
I/O Signal | A signal object contained by a Smart Component that has a value, type and direction (input/output), analogous to I/O signals on a robot controller. The signal value is used by code behind to control the behavior of the Smart Component. |
I/O Connection | Connects the value of a signal of one component to the a signal of another component. The I/O connection is represented by the IOConnection. |
Aggregated Smart Components | Smart Components that contain child Smart Components that are connected with each other using bindings and/or connections to implement a more complex behavior. |
Asset | Binary data object contained by a Smart Component. There are some predfined types of Assets such as code behind assemblies and localized resources. The predefined asset types have a specaial meaning for RobotStudio, and must follow certain naming and content convetions. It is possible to embedd any kind of file as an asset, which can be access from code-behind. For example a CAD file. An asset is represented by the class Asset. |
Digital(authenticode) signing | A Smart Component contains executable code. For users to trust the Smart Component, any embedded code-behind assembly must be digitally signed using Microsoft’s Authenticode technology. For more details, see Digital signing of Smart Components. |