2. Command Reference
Advent Instruments Inc.
In order to properly use the get and set data commands, it is important to understand the
purpose of each of the AI-7280's registers. A summary of all HAL properties is listed in
Appendix B: Property Listing by Index, while section 3. HAL Properties provides
detailed information for each property.
2.3 Program Control Commands
An important feature of the AI-7280 is its ability to execute simple programs. These
programs can be used to off load low level tasks from the PC or other controlling device.
Up to six independent program execution units (PEU) can be operating at any one time.
Each PEU can run a separate program, or a program can be constructed from multiple
processes, which each PEU running a process.
The following commands are used to control the PEUs. If the AI-7280 correctly
interprets the command, it returns the characters 'OK' in response. However, if an error is
detected it returns the character string 'ERR=x', where 'x' represents an error code. See
Appendix C: Error Codes for a listing of the possible error codes and their meaning.
Clear Program Memory: PC
This command clears the RAM program memory. Programs may be stored and executed
out of the internal non-volatile flash memory, or the RAM. If using the RAM to load and
execute programs, send the 'PC' command before loading a program with the 'PL'
command.
Example:
PC
OK
Load Program: PL"(program text)"
Loads a program into the AI-7280's RAM. All programs generated by the TRsSim
compiler are composed of printable ASCII characters, which must be enclosed in
quotation marks when using this command. As the maximum length of any command
must not exceed 128 characters, programs exceeding 123 characters should be broken up
into multiple text strings. Each text string can be loaded in succession by using the 'PL'
command. The maximum program size that can be loaded into the RAM is 16384
characters.
Example: this program enables the ringing generator for 2 seconds.
PL"TIN1HN111WIN2000TIN0HN111"
OK
Note: If the program text contains quotation marks, they must be duplicated before using
the PL command.
Example: load the program: TIS"hello"GS1
10
AI-7280 Programmers Guide - Direct Control