unplugged-system/packages/services/Car/tools/telemetry/lua-interpreter
2025-10-06 13:59:42 +00:00
..
data Initial commit: AOSP 14 with modifications for Unplugged OS 2025-10-06 13:59:42 +00:00
static Initial commit: AOSP 14 with modifications for Unplugged OS 2025-10-06 13:59:42 +00:00
templates Initial commit: AOSP 14 with modifications for Unplugged OS 2025-10-06 13:59:42 +00:00
tests Initial commit: AOSP 14 with modifications for Unplugged OS 2025-10-06 13:59:42 +00:00
app.py Initial commit: AOSP 14 with modifications for Unplugged OS 2025-10-06 13:59:42 +00:00
BUILD Initial commit: AOSP 14 with modifications for Unplugged OS 2025-10-06 13:59:42 +00:00
json.lua Initial commit: AOSP 14 with modifications for Unplugged OS 2025-10-06 13:59:42 +00:00
lua_engine.cc Initial commit: AOSP 14 with modifications for Unplugged OS 2025-10-06 13:59:42 +00:00
lua_engine.h Initial commit: AOSP 14 with modifications for Unplugged OS 2025-10-06 13:59:42 +00:00
lua.BUILD Initial commit: AOSP 14 with modifications for Unplugged OS 2025-10-06 13:59:42 +00:00
package-lock.json Initial commit: AOSP 14 with modifications for Unplugged OS 2025-10-06 13:59:42 +00:00
package.json Initial commit: AOSP 14 with modifications for Unplugged OS 2025-10-06 13:59:42 +00:00
README.md Initial commit: AOSP 14 with modifications for Unplugged OS 2025-10-06 13:59:42 +00:00
requirements.txt Initial commit: AOSP 14 with modifications for Unplugged OS 2025-10-06 13:59:42 +00:00
rollup.config.js Initial commit: AOSP 14 with modifications for Unplugged OS 2025-10-06 13:59:42 +00:00
WORKSPACE Initial commit: AOSP 14 with modifications for Unplugged OS 2025-10-06 13:59:42 +00:00

Lua Interpreter

The Lua Interpreter is a web-based IDE tool that can run Lua scripts with the specific Android Auto telemetry callbacks.

Prerequisites


Install the required node dependencies using npm with

sudo apt install nodejs
npm install

Install Bazel with

sudo apt install bazel

Change the LUA_SRC inside the WORKSPACE file to point to the directory containing the headers of the Lua C API which should be in $ANDROID_BUILD_TOP/external/lua/src.

Running


Run the following commands on the command line to start the server:

npm run build; bazel run server

Open the link provided from starting the server to access the tool (the link is accessible from the terminal window).

Testing


The following commands assume you are at the root directory.

To test everything, run:

bazel test --test_output=all //tests:lua_interpreter_tests

To test the server, run:

bazel test --test_output=all //tests:app_test

To test the Lua Engine, run:

bazel test --test_output=all //tests:lua_engine_test