A security channel is provided for communication with an eight-bit,
register-based, virtual machine. The virtual machine is placed into a
direct mode, and then individual script instructions are sent to the
virtual machine across the security channel for immediate interpreting by
the virtual machine. The instructions are interpreted one by one as they
are received. This feature can be used in debugging. This feature is
usable in applications in which resident code is not required, but rather
incoming script instructions are adequate to control device operation. A
large memory is not required to store scripts, thereby reducing virtual
machine system cost. Script instructions usable in the direct mode
include instructions for loading a script API or machine code API onto
the virtual machine from an external system, for loading a script, and
for causing the virtual machine to output the contents of memory and/or
internal registers to the external system.