Controller Plugin
Controller Plugin Structure
The Controller Plugin package mainly contains three files: Plugin.so, Plugin.lic, and Plugin.json. Taking a Plugin package that contains only one Controller Plugin as an example:
Plugin Package.zip
└──controller.zip
└──example
├──example.lic
├──example.so
└──example.json
controller.zip can contain multiple Controller Plugins. Each Controller Plugin must have consistent file names for json, lic, and so files. The so file and json file are generated by the user, and the lic file is generated by Rokae. The so file's dynamic library is a product generated by the user based on the provided API and compilation environment. The json file is filled out by the user, with the following field meanings:
{
"controller_plugin":{// Describes a Controller Plugin
"example":{// Plugin name
"name": "example",// Plugin name, must be consistent
"depend":["plugin1","plugin2"],// Dependent Plugins
"enable":true,// Whether to enable, not loaded if disabled
"min_controller_version":"3.0.2",// Minimum Controller version required for this Plugin to run
"must_controller_version":[],// This Plugin only runs on these Controller versions, overrides minimum version
"version": "1.0.0",// User-defined Plugin version number, recommended to include Plugin Usage API version
"author": "rokae",// Plugin author name
"description": "description info"// Plugin description information
}
}
}
When loading a Controller Plugin, the package format is first validated. Packages that do not conform to the above rules will not be loaded.
Compilation and Runtime Environment
Programming Language: C++11 Rokae provides a virtual machine development environment where the Controller can be downloaded and run from the official website. Contact Rokae to obtain the virtual machine usage process.