Getting Started with Lua
To quickly start the Lua interpreter, connect to any port of the OEM7 receiver and send the command LUA PROMPT. This will do two things:
-
Change the Interface Mode of the port that received the command to LUA. In the example below, that's COM1.
-
Start the Lua interpreter
Interface mode LUA establishes a connection between the COM port and the Lua interpreter's stdin, stdout and stderr. This connection allows commands to be typed directly to the Lua interpreter (stdin) and the output from print statements is sent to the COM port. For more information, see Loading and Running the Application.
From there, Lua commands can be entered as shown below.
lua prompt
<OK
[COM1]Lua 5.3.4 Copyright (C) 1994-2017 Lua.org, PUC-Rio
>
>
> print("Hello World")
Hello World
>
> Var1 = 1
> Var2 = 2
> print(Var1+Var2)
3
>
NovAtel Connect's Console Window cannot be used for this purpose because it depends on the port remaining in the NOVATEL Interface Mode. The terminal emulators TeraTerm or Hyperterm can be used:
https://ttssh2.osdn.jp/index.html.en
https://hyperterminal-private-edition-htpe.en.softonic.com/download
For details on the Lua language, reference manuals can be found at www.lua.org. The OEM7 receiver uses Lua version 5.3.4.