Skip to content

Source

Source is an object type. You don't create it directly: you get one from another call, then call its methods with a colon, e.g. source:name().

Obtained from

Methods

Function Description Since
name() Return the source name (and modify it on Vars and Sensors) 1.5.5
rawValue() Return the source raw value. 1.1.0
maximum() Return the source maximum (and modify it on Vars and Sensors) 1.5.0
minimum() Return the source minimum (and modify it on Vars and Sensors) 1.5.0
value() Return the source value / Set the source value on Lua sources / Vars / Telemetry sensors. 1.1.0
state() Return the source state. 1.1.0
reset() Reset the source (Flight / Timer / Telemetry) 1.1.0
age() Get the last value age (only for Telemetry sources) 1.6.2
unit() Return the source unit (and modify it on Vars and Sensors) 1.1.0
protocolUnit() Get / Set the sensor internal unit. 1.5.10
stringUnit() Return the source unit. 1.1.0
decimals() Return the source decimals (and modify it on Vars and Sensors) 1.5.5
protocolDecimals() Get / Set sensor internal decimals. 1.5.10
stringValue() Return the source value as a string. 1.1.0
member() Return the source member. 1.1.2
category() Return the source category. 1.1.2
options() Return the source options. 1.1.4
band() Get or set the band of the source if it is a FrSky Sensor. 1.5.5
appId() Get or set the appId of the source if is a FrSky sensor. 1.5.5
physId() Get or set the physId of the source if it is a FrSky sensor. 1.5.5
crsfId() Get or set the crsfId of the source if it is a CRSF sensor. 1.6.2
subId() Get or set the subId of the source if it is a CRSF or a FrSky sensor. 1.6.2
drop() Drop a telemetry sensor. 1.5.10