1
0
Fork 0
mirror of https://github.com/opentx/opentx.git synced 2025-07-16 21:05:26 +03:00

POC for review and discussion

This commit is contained in:
3djc 2018-02-28 11:34:32 +01:00
parent 4cccff934f
commit fdf4d4926f
5 changed files with 21 additions and 1 deletions

View file

@ -218,6 +218,11 @@ static void luaPushCells(lua_State* L, TelemetrySensor & telemetrySensor, Teleme
void luaGetValueAndPush(lua_State* L, int src)
{
if(IS_FAI_FORBIDDEN(src)) {
lua_pushinteger(L, 0);
return;
}
getvalue_t value = getValue(src); // ignored for GPS, DATETIME, and CELLS
if (src >= MIXSRC_FIRST_TELEM && src <= MIXSRC_LAST_TELEM) {
@ -587,6 +592,7 @@ or a name (string) of the source.
@retval value current source value (number). Zero is returned for:
* non-existing sources
* for all telemetry source when the telemetry stream is not received
* far all non allowed sensors while FAI MODE is active
@retval table GPS position is returned in a table:
* `lat` (number) latitude, positive is North