Configuring with the command-line interface

The command-line interface is a simple way to access all of the functions available in the anemometer, starting with important information about how you save changes to the anemometer configuration.

Applying configuration changes

Each time the LI-560 TriSonica Sphere is powered up, it gets a copy of configuration parameters from non-volatile memory (Flash) and places it in temporary volatile memory (RAM) for operational access.

When you make changes to parameters using the serial menu or command-line, the changed parameters are updated in the temporary volatile memory, but they are not updated in the non-volatile memory. This means these changes are lost when the unit restarts, because the LI-560 replaces the parameters in the volatile memory with a fresh copy of the parameters saved in the non-volatile memory.

If you do not want the changes to be lost, copy the parameter changes saved in volatile memory to the non-volatile memory using the nvwrite command. The changes will then be remembered during a restart.

Restoring default settings

If, after making changes to non-volatile memory, you want to restore the permanently saved parameters to their original default values, this can be done by using the command factoryrestore YES in the expert menu mode.

Basic mode commands

After connecting with either a terminal program or the TriSonica application (select the Terminal tab), press Ctrl + C to enter command-line interface (CLI) mode. The LI-560 will stop sampling and provide a prompt: >. If no input is given within one minute, the LI-560 returns to sampling mode and changes are not saved in non-volatile memory.

Details of all available commands and their parameters are accessed within the command-line interface by typing help at the prompt.

Note: The LI-560 command-line interface is self-documented. The detailed help for each command may differ from what appears in the following sections. You can download the current firmware release notes at licor.com/env/support/LI-560/software.html.

help

Displays a list of command-line interface commands. The command help followed by the name of another command displays detailed help for that command (e.g., help baudrate).

Table 6‑1. The help command.
Command Description
help Displays commands available in the command-line interface.
command e.g., help baudrate

exit

Type exit to leave the command-line interface and return to sampling mode.

Command Description
exit Leaves the command-line interface and returns to sampling mode.

baudrate

Shows or sets the current baud rate. Type the word baudrate followed by the desired rate (must be a valid baud rate of 9600, 19200, 38400, 57600, 115200, 230400) and press return. Add the word now to change the baud rate immediately. Otherwise, the baud rate is placed in memory to be written to non-volatile memory using the nvwrite command and used on the next reset.

Note: In order for the LI-550 or LI-560 to communicate with the terminal program, the baud rate (and parity) for both needs to match. Changing the baud rate (or the parity) in the anemometer memory (whether volatile or non-volatile) does not change the baud rate (or parity) in the terminal program. If you choose to change the baud rate (or parity) in the LI-550 or LI-560, be sure to make a matching change in the Terminal Program's settings.

calibrate

To calibrate the precise length of the acoustic path between pairs of transducers. This length is a defining component in the detection and calculation of wind speed and direction. Actual air temperature is included in the calculation of the acoustic path length. The subcommand allows you to input a specific value for this variable.

You can calibrate the LI-560 to local conditions or test conditions using the calibrate command by following steps in User calibration.

Command Description
calibrate When sent with a parameter, initiates the calibration.
temp Temperature in Celsius inside the calibration chamber.

decimals

Set the number of decimals places of a display parameter or a group of parameters. Enter decimals to view a list of the current settings and parameters that can be changed. Enter decimals followed by the parameter and the number of digits after the decimal. You can use the name of a single parameter or a group as listed by the decimals or display command. The parameter is case sensitive. For example, to set wind speed to three decimals, send decimals S 3.

diagnostic

Type diagnostic to for a report on problems found with the anemometer. Type diagnostic details for a more detailed diagnostic output. Enter diagnostic clear to clear the error counts displayed in the details parameter.

display

Shows the current display mode settings. The display command shows a table indicating the name and description of each parameter available, whether it is tagged or not, what the tag value is, how many decimals are displayed, whether the signal is enabled to be added to the serial output string, and the units for each measurement. See Table 4‑1 for a full list of parameters, tags, and units.

Figure 6‑1. Display command output module.

expert

Type expert enable to access advanced menus, as described in Expert mode commands. Type expert disable to return to normal mode.

hide

Similar to the show, tag, untag, and decimals commands, the hide command is to view a list of display parameters or groups available to be hidden. It also provides a list of all values currently being displayed. When used with a parameter, the hide command removes that parameter from the list of displayed variables.

The parameter can be the name of a single parameter or a group as listed by the show or display command. The parameter is case sensitive.

  • Example: hide IDTag
  • Reply: None; removes the IDTag from the data stream.

levelcalibrate

To calibrate the level while on a known level surface. Place the anemometer upright on a level horizontal surface. Enter levelcalibrate YES to execute the command. Do not disturb the unit during calibration. If the device detects that it is too far from level, it will automatically cancel the calibration. See Level calibration for more details.

nvwrite

Writes parameter data to non-volatile memory. Writes to flash memory to preserve the configuration during power down. See Applying configuration changes for more details.

outputrate

Type outputrate to view the current setting. Enter outputrate followed by the desired rate to set the parameter. For example outputrate 5 will set the rate to 5 Hz.

parity

Show or set the current parity setting. Parity can be applied immediately or written to flash for the next reset. Options include odd, even, and none. Append the command with now to apply the change immediately. Otherwise, the setting is placed in memory to be written to non-volatile memory using the nvwrite command and used on the next reset.

Note: In order for the LI-550 or LI-560 to communicate with the terminal program, the baud rate (and parity) for both needs to match. Changing the baud rate (or the parity) in the anemometer memory (whether volatile or non-volatile) does not change the baud rate (or parity) in the terminal program. If you choose to change the baud rate (or parity) in the LI-550 or LI-560, be sure to make a matching change in the Terminal Program's settings.

programupdate

Puts the LI-560 into update mode. In update mode, you can update the program, using a serial terminal emulation program such as Tera Term, using the YModem protocol. See Firmware updates.

show

Similar to the hide, tag, untag, and decimals commands, the show command is to view a list of display parameters or groups available to be shown. When used with a parameter, the show command adds that parameter to the list of displayed variables. The parameter can be the name of a single parameter or a group as listed by the show or display command. The parameter is case sensitive.

  • Example: show IDTag
  • Reply: None; adds the IDTag to the data stream.

systemreset

Enter systemreset followed by return to immediately reset the device.

tag

Similar to the hide, show, untag, and decimals commands, the tag command is to view and set the ID tags applied to a parameter or group of parameters. When used with a parameter, the tag command adds that parameter to the list of displayed variables. The parameter can be the name of a single parameter or a group as listed by the show or display command. The parameter is case sensitive.

triggertype

Set or get the sampling trigger type.

trisonicaid

Enter trisonicaid to view the current ID setting. Enter trisonicaid 001 to set the ID to 001, for example. Enter trisonicaid clear to remove the ID. The trisonicaid may be up to 40 characters in length to accommodate a UUID.

units

The command sets or displays the units value for all adjustable parameters. Enter units to view the units for measurements. The units menu displays variable names, descriptions, and the units that are currently in use. See Table 4‑1 for a full list of parameters and units available.

To apply international (si) units, enter units si. To change units for a parameter, enter units followed by the name, followed by the new units. Units can be set for a single parameter or a family of units. The parameters are case sensitive.

Command Description
units Displays and configures the units
si Set all parameters to default metric units (m/s, C, hPa, kg/m^3)
sae Set all parameters to the sae units (mph, F, psi, lb/ft^3)
velocity Units for velocity (mps, kph, mph, fps, or kts)
temperature Units for temperature (C and F)

untag

Similar to the hide, show, untag, and decimals commands, the untag command is to view a list of display parameters or groups that can be untagged. Enter untag to view a list of all available parameters that can have the tag removed from the display output. Enter untag followed by a parameter to remove the tag from a display parameter or a group of parameters.

The parameter can be the name of a single parameter or a group as listed by the show or display command. The parameter is case sensitive.

version

Type version to see the firmware version, serial number, and other details.

wd540

Type wd540 to view the current settings. Type wd540 enable to apply the 540° mode; Type wd540 disable to return to normal 0 - 360° mode.

The LI-560 default horizontal wind direction parameter reports wind direction as 0 to 360 degrees. If you want to display horizontal wind direction data on a time-series graph, horizontal wind that is approaching the anemometer from near north (0/360) appear as large directional changes rather than gradual changes.

To avoid this display issue, apply the wind direction scale command (wd540) parameter. This prevents the graph from showing large directional shifts when crossing 359° to 0°. When the wd540 parameter is applied, the firmware recognizes two representations of 360 degrees: a 0-to-360-mode, and a 180-to-540-mode. The anemometer begins in the 0-to-360-mode. When the wind direction crosses 360 or 0 degrees, the firmware shifts to 180-to-540 mode. The anemometer stays in the 180-to-540 mode until the wind direction again crosses either 180 or 540, which causes the anemometer to return to 0-to-360-mode.

Expert mode commands

When expert mode is enabled, additional commands are present in the help menu. These commands enable more advanced settings and configurations that may be outside of the normal operating settings. We recommended that you understand the effects of these commands before use. Changes made in expert mode are stored as described in Applying configuration changes.

averagesize

Set or show the size of the average of samples.

This command specifies the number of internal samples to average before generating an output. When combined with the samplerate command, it affects the output data rate. For simplicity, it is better to use the outputrate command in the basic menu.

  • Example: averagesize 8
  • Reply: None. Set the number of samples to be avereaged to 8.

distance

Set or show the distance between transducers. This is one of the settings that is changed during a calibration. We do not recommend altering this setting. If you enter a value as a single number, it will be applied to all four distances. If you enter four values, they will be applied respectively to the four distance values. The designed mechanical distance between transducers on an LI-560 is 0.060 meters. See User calibration for more information.

  • Example: distance
  • Reply: Distances for four paths.

The offset is also set during factory calibration. All four should be close to zero. Similar to distance, if you enter one number, it is applied to all four paths. If you enter four numbers, they will be applied separately to each path.

factoryrestore

Returns the instrument to the factory default settings. Enter factoryrestore YES and press return to apply the changes immediately.

offset

Set or show the offset values for all paths. These are calibration factors set during the calibration cycle. If you enter the value as a single number, it will be applied to all four distances. If you enter four values, they will be applied respectively to the four distance values. The offset value compensates for variations in manufacturing.

orientuv

Set or view the UV wind vector output coordinate system. Options are std, ati, otsm.

Note: There are different possible definitions for the meanings of the U and V axes. The std setting defines positive U as being from the west, and positive V as being from the south. This is the default output coordinate system. The ati setting defines the positive U as being from the north, and positive V as being from the west. The otsm setting matches the original TriSonica Mini output definition of positive U as being from the north, and positive V as being from the east.

paramdelim

Gets or sets the parameter delimiter for all display parameters. The measurement delimiter is a single character displayed immediately after the parameter value is displayed. This value is controlled by the paramdelim command. The default delimiter is a space character.

protocol

Show or set the current serial protocol setting. This is the software command to select between EIA232 and EIA422 modes. The now parameter makes the change immediately, otherwise the setting is placed in memory to be written to non-volatile memory using the nvwrite command and used on the next reset.

samplerate

Set or get the internal sample frequency. This command changes the internal sampling rate. When combined with the averagesize command, it affects the output data rate. For simplicity, it is better to use the outputrate command in the basic menu.

shadowcorrect

Enable or disable the shadow correction calculations of the LI-560. 1 = enable, 0 = disable. We recommend that you keep the correction enabled. It is enabled by default.

tagdelim

Gets or sets the tag delimiter for all display parameters. The tag delimiter is a single character displayed immediately after the parameter tag and is controlled by the tagdelim command. The default delimiter is a space character.

tagid

Set the tag id to id in the specified parameter param. The new id for the display value of the parameter. The id can be a maximum of 8 characters.

triggertype

Triggering can be internal or external and can be adjusted to trigger on the rising or falling edge of the external signal. Use the triggertype command and the parameters posedge and negedge to make this selection. Three trigger modes are available.

Trigger Description
Internal Trigger The LI-560 uses its own internal timer for sample triggering and runs asynchronous to other instruments.
External Trigger When an external trigger is received, the LI-560 takes the number of samples specified in the averagesize command at the configured samplerate. When this sampling is complete, the output is generated and transferred over the serial port. The LI-560 then waits until the next trigger before sampling again. If the trigger is too fast to complete all the samples, the LI-560 will shorten the number of samples taken to maintain the external trigger rate.
Sync The sync trigger mode adjusts the internal trigger sampling to align with the sync trigger, otherwise the LI-560 operates on its internal trigger. For instance, this is useful for aligning samples to a GPS pulse-per-second clock so multiple instruments can trigger simultaneously without being connected to the same trigger. Sync pulses can have a very long time between pulses.

Application programming interface

The LI-560 provides an Application Programming Interface (API), which is a method to simplify computer command automation. It is a variation on the command-line interface and uses the same commands as the command-line interface. The API commands are sent to the LI-560 during sampling mode. The command is enclosed in curly braces { and } without a carriage return or line feed character. One command per set of curly braces is allowed. The open curly brace { instructs the LI-560 that a API command is starting, and the close curly brace } indicates the end of the command. When the close curly brace } is received, the command is executed and the results returned within the curly braces.

Note: This is not compatible with the JSON protocol.