...
To begin, it is recommended that the relevant files be copied into Trebuchet’s executable directory, in a folder called Apps. To do this:
Create a folder called Apps in the trebuchet_debug folder:
Open the Apps folder and place the relevant applications that you wish to use via Trebuchet:
Open the the file appConfiguration.json:
and add a new entry to the TrebuchetApps list, in the following format:
Code Block "TrebuchetApps": [ <Current App list>, { "Name": "", "Description": "", "LaunchCommand": "", "ExePath": "", "ParameterGroups": [], "MutualExclusiveGroups": [], "ExecutionEnv": null } ]
...
In this example, add the read_azimuth_of_fft_data.py script to the launcher. This is placed in: Apps\Python\Python_radar_client\read_azimuth_of_fft_data.py. Set the name of the app to Read Single FFT Azimuth, and give an appropriate description. Since the “app” is a python script, we must provide a the python launch command. In this case, that command is python. Finally, set the ExePath field to Apps\\Python\\Python_radar_client\\read_azimuth_of_fft_data.py.
...
Code Block |
---|
{ "Name": "Read Single FFT Azimuth", "Description": "Connects to a radar and reads a single azimuth of data", "LaunchCommand": "python", "ExePath": "Apps\\Python\\Python_radar_client\\read_azimuth_of_fft_data.py", "ParameterGroups": [ { "GroupName": ""], "ParametersMutualExclusiveGroups": [ { "ShortForm": "i", ], "LongFormExecutionEnv": "ip_address", null "Required": false, "HasArguments": true, "DefaultValue": "192.168.0.1" }, { "ShortForm": "p", "LongForm": "port", "Required": false, "HasArguments": true, "DefaultValue": "6317" } ] } ], "MutualExclusiveGroups": [], "ExecutionEnv": null } |
When the app is next launched, there will be a corresponding entry in the Trebuchet Launcher, but with no arguments:
...
So, the final configuration entry for this app looks like this:
Code Block |
---|
{
"Name": "Read Single FFT Azimuth",
"Description": "Connects to a radar and reads a single azimuth of data",
"LaunchCommand": "python",
"ExePath": "Apps\\Python\\Python_radar_client\\read_azimuth_of_fft_data.py",
"ParameterGroups": [
{
"GroupName": "",
"Parameters": [
{
"ShortForm": "i",
"LongForm": "ip_address",
"Required": false,
"HasArguments": true,
"DefaultValue": "192.168.0.1"
},
{
"ShortForm": "p",
"LongForm": "port",
"Required": false,
"HasArguments": true,
"DefaultValue": "6317"
}
]
}
],
"MutualExclusiveGroups": [],
"ExecutionEnv": null
} |
Code Block |
---|
This creates an entry in the Trebuchet app:
...
As they are global fields, ip_address and port have been translated to Hostname IP Address and Port in the connection details pane. Their default values have also been ignored.
...
Code Block |
---|
{ "Name": "Radar Video Adjuster", "Description": "Relays incoming 16-bit FFT messages as 8-bit", "LaunchCommand": "", "ExePath": "Apps\\Radar Utilities\\video_adjuster.exe", "ParameterGroups": [], "MutualExclusiveGroups": [], "ExecutionEnv": null } |
Info |
---|
Note the “//\\” in the ExePath. This is so that Trebuchet’s config parser can correctly interpret the file path. |
...
Note that the radar ipaddress and port parameters have been recognised as radar connection parameters, and so have been linked to the Hostname IP Address and Port fields.
Info |
---|
When you click on an app tile you may notice that the IP Address and port change to reflect what is configured for the app. If the app doesn't have a port configured, then this will not change but the IP address will. There is an Use fixed address for all apps box above the IP Address field in the Connection Details. If this is ticked, when you click on an app tile, the IP Address and port will not change. This makes it easier to use an apps specific details, or override them globally. |
...
Related Information
Filter by label (Content by label) | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|
|