mirror of
https://github.com/opentx/opentx.git
synced 2025-07-15 12:25:12 +03:00
Minor fixes to lua dua
This commit is contained in:
parent
cd23fedb56
commit
2ae0472f76
3 changed files with 10 additions and 5 deletions
|
@ -367,7 +367,7 @@ PACK(struct FlightModeData {
|
||||||
PACK(struct CurveData {
|
PACK(struct CurveData {
|
||||||
uint8_t type:1;
|
uint8_t type:1;
|
||||||
uint8_t smooth:1;
|
uint8_t smooth:1;
|
||||||
int8_t points:6; // TODO conversion (?!) (describes number of points - 5)
|
int8_t points:6; // describes number of points - 5
|
||||||
NOBACKUP(char name[LEN_CURVE_NAME]);
|
NOBACKUP(char name[LEN_CURVE_NAME]);
|
||||||
});
|
});
|
||||||
#else
|
#else
|
||||||
|
|
|
@ -56,11 +56,11 @@ Return OpenTX version
|
||||||
|
|
||||||
@retval multiple (available since 2.1.7) returns 5 values:
|
@retval multiple (available since 2.1.7) returns 5 values:
|
||||||
* (string) OpenTX version (ie "2.1.5")
|
* (string) OpenTX version (ie "2.1.5")
|
||||||
* (string) radio version: `taranisx9e`, `taranisplus` or `taranis`.
|
* (string) radio version: `x9e`, `x9d+` or `x9d`.
|
||||||
If running in simulator the "-simu" is added
|
If running in simulator the "-simu" is added
|
||||||
* (number) major version (ie 2 if version 2.1.5)
|
* (number) major version (ie 2 if version 2.1.5)
|
||||||
* (number) minor version (ie 1 if version 2.1.5)
|
* (number) minor version (ie 1 if version 2.1.5)
|
||||||
* (number) revison number (ie 5 if version 2.1.5)
|
* (number) revision number (ie 5 if version 2.1.5)
|
||||||
|
|
||||||
@status current Introduced in 2.0.0, expanded in 2.1.7
|
@status current Introduced in 2.0.0, expanded in 2.1.7
|
||||||
|
|
||||||
|
@ -108,6 +108,9 @@ Return the time since the radio was started in multiple of 10ms
|
||||||
@retval number Number of 10ms ticks since the radio was started Example:
|
@retval number Number of 10ms ticks since the radio was started Example:
|
||||||
run time: 12.54 seconds, return value: 1254
|
run time: 12.54 seconds, return value: 1254
|
||||||
|
|
||||||
|
The timer internally uses a 32-bit counter which is enough for 30year so
|
||||||
|
overflows will not happen.
|
||||||
|
|
||||||
@status current Introduced in 2.0.0
|
@status current Introduced in 2.0.0
|
||||||
*/
|
*/
|
||||||
static int luaGetTime(lua_State * L)
|
static int luaGetTime(lua_State * L)
|
||||||
|
@ -304,7 +307,9 @@ bool luaFindFieldByName(const char * name, LuaField & field, unsigned int flags)
|
||||||
/*luadoc
|
/*luadoc
|
||||||
@function sportTelemetryPop()
|
@function sportTelemetryPop()
|
||||||
|
|
||||||
Pops a received SPORT packet from the queue. Please note that only packets using a data ID within 0x5000 to 0x52FF (frame ID == 0x10), as well as packets with a frame ID equal 0x32 (regardless of the data ID) will be passed to the LUA telemetry receive queue.
|
Pops a received SPORT packet from the queue. Please note that only packets using a data ID within 0x5000 to 0x52FF
|
||||||
|
(frame ID == 0x10), as well as packets with a frame ID equal 0x32 (regardless of the data ID) will be passed to
|
||||||
|
the LUA telemetry receive queue.
|
||||||
|
|
||||||
@retval SPORT paket as a quadruple:
|
@retval SPORT paket as a quadruple:
|
||||||
* sensor ID (number)
|
* sensor ID (number)
|
||||||
|
|
|
@ -874,7 +874,7 @@ The first and last x value must 0 and 100 and x values must be monotonically inc
|
||||||
7 - extra values for y are set
|
7 - extra values for y are set
|
||||||
8 - extra values for x are set
|
8 - extra values for x are set
|
||||||
|
|
||||||
@status current Introduced in 2.2.1
|
@status current Introduced in 2.2.0
|
||||||
|
|
||||||
Example setting a 4-point custom curve:
|
Example setting a 4-point custom curve:
|
||||||
```lua
|
```lua
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue