This file describes the format for adding parameters in comments to drive the gui configuration of cajun. All parameters are set at the beginning of each driver file, just below the copyright notice, in a block that appears as...
#!!! Gui parameters (parameters appear here) #!!! Gui parameters
It's *very* important to keep the parameters in the comment block in sync with those used in the code; otherwise the user won't be able to set fields needed (or will be setting fields unused by the code). Each line contains one field. The contents of the fields are as below:
Input fields are key=value parameters to a driver, such as "port => /dev/ttyS0". Each field may have 0 or more parameters, that modify the display or operation of the input field on the screen when the user enters data into it. Here's what the line looks like:
#@ input:fieldname:desc:type:default:param1:param2...
where type (and params) can be:
| Type | Parameters |
|---|---|
| string | 'nonnull' (meaning at least length 1),an integer (length of field) |
| enum | 1 or more enumerations |
| number | An integer (length of field) |
| bool |
An example would be:
#@ input:port:The serial port for the device:string:/dev/ttyS0:20 #@ input:speed:Speed of serialport:enum:9600:1200:2400:4800:9600:19200 #@ input:shuffle:Shuffle when played?:bool:::
The action fields are only present in audio devices, and declare the actions that the device expects to process as input... any other actions will be ignored by the driver. All states where the action is valid must be listed.
#@ action:fieldname:desc:state:state:state...
Description fields are simply text strings that note what function a given module has. There should be only 1 (Only the first one is used). The more descriptive, the better.
#@ desc:The FMV4L module plays FM radio stations from the FM card.
This determines whether the device will be loaded and executed by cajun on bootup. Some devices (like the ATKeyboard) need to be loaded manually, since the user needs to choose a terminal to connect with. Normally, the server will load and execute the device; if the following field is present, the device won't load at bootup:
#@ dontload:
Display filters need to know all states and fields sent in a displayMap by an audio device. This field declares each state, and the fields sent in that state:
#@ displaymap:playing:artist:disc:title:clock #@ displaymap:stopped: