User's Guide

Command Scripts
Lists of commands can be entered into a script file and stored in the VFS for execution (in the
/store/scripts directory). These are called ‘command scripts’ and are simple sequential lists of
OVMS commands. A command script can be executed with:
OVMS# . <script>
OVMS# script run <script>
Command scripts can also be stored in the /store/events/<eventname> directory structure.
Whenever events are triggered, all the scripts in the corresponding /store/events/<eventname>
directory are executed.
Note that the developer building firmware can optionally set the
OVMS_DEV_SDCARDSCRIPTS build flag. If that is set, then the system will also check
/sd/scripts and /sd/events for scripts.
In addition to command scripts, more sophisticated scripting capabilities may be enabled if the
JavaScript environment is enabled in the build. This is discussed in the next section of this
guide.
OVMS v3 User Guide Page 46 / 86