Lookup

Lookups are very similar to enumerations - they translate one value into something more human-readable.

The major difference between the two is the number of different values they support. Enumerations are suited to smaller, simpler sets of values - for example, having less than 10 distinct types of output text.

Lookups are different. When you define a lookup, you upload a lookup table containing the lookup value and the translation. This can have hundreds or even thousands of values.

This makes them very useful for looking up fault-codes and statuses in systems that share a single, large lookup table to translate those codes into meaningful messages.

Table Format

The lookup table should be in tab-delimited or comma-separated format, with the lookup value first and the displayed value second. The table should not include a header.

0OK
1Starting
2Running
3Stopping
4Stopped
10No Air Pressure
11No Power
12Comms Lost

Performance Warning

Technical Section

Why does ARDI have both an enumeration and a lookup type? The simple answer is efficiency.

When dealing with small numbers of options, it's quite easy to send the complete lookup table out to ARDI clients. When there are only a half-dozen options to choose from, the complete list is trivial to transmit.

However, when the list is significantly larger, it's puts a lot of load on the client and the network. Lookup properties instead push some of this additional work off to the driver, rather than loading-down the server and the client.

Please use enumerations where possible, as a large number of small lookup properties will cause additional server load that will negatively impact performance.