Below are several miscellaneous commands.


echo

Syntax: echo message1 <message2>

This command echos a "message" to the screen and log file. If more than one parameter is specified, each is output with a space in between. The output of the echo command is not suppressed when the quieton command is active.

quieton

Syntax: quieton

This command turns off the logging of status information to the screen and the quiet log file, except for error messages which always begin with “!!!” and output from the echo command. Note that status information continues to be written to the log files.

quietoff

Syntax: quietoff

This command turns on the logging of status information to the screen and the quiet log file.

logon

Syntax: logon

This command turns on the logging of status information to the log files.

logoff

Syntax: logoff

This command turns off the logging of status information to the log files, but not the screen, except for error messages which always begin with “!!!”.

wait

Syntax: wait seconds

This command causes the execution of a script to wait for the specified number of seconds or fractions of seconds (up to 86400 seconds – this is one day). The specified delay is rounded to the nearest 0.1 seconds.

waitevenminute

Syntax: waitevenminute <minutes>

This command causes the execution of a script to wait until the next even minute if no parameter is specified or until the passage of "minutes" even minutes (up to 60 integer minutes).

waittime

Syntax: waittime hours minutes seconds

This command causes the execution of a script to wait until the specified time of day, given in local 24-hour time as "hours", "minutes", and "seconds".\

waitdate

Syntax: waittdate year month date

This command causes the execution of a script to wait until the specified local date, given as "year", "month", and "date".

hide

Syntax: hide

This command causes the ARAP program window to be placed in the system tray (usually those bank of icons at lower right of the screen).

show

Syntax: show

This command causes the ARAP program window to be restored from the system tray (usually those bank of icons at lower right of the screen). It can also be restored by double-clicking on ARAP's tray icon.

secureon

Syntax: secureon

This command secures the ARAP user interface by making the menus and tool bar invisible.

secureoff

Syntax: secureoff

This command unsecures the ARAP user interface by making the menus and tool bar visible.

servo

Syntax: servo comport command txbytes rxbytes <txbyte1> <txbyte2> <txbyte3>d

This command controls the Pololu Micro Maestro Servo Controller series, which supports (depending on the model) up to 24 inexpensive "standard" RC servos. These servos were originally developed for radio-controlled planes, but are now used commonly in small scale robotics. You need to read and understand the controller's manual and software protocol in order to be able to use this command. An example ARAP script can be provided on request. The parameters are as follows:

  • comport - com port number (1-32)
  • command - servo command code (0-255)
  • txbytes - the number of binary bytes to send to the controller in addition to the command code (0-4)
  • rxbytes - the number of binary bytes expected to be received back from the controller (0-2)
  • <txbyte1 ... txbyteX> - each of the bytes to be sent (0-255) to the controller, if any

When the command completes, the variable SERVORX contains the received bytes as a single 16 bit integer with the first byte received as the low byte byte and the second byte received as the high byte. If an error occurs, the variable PORTERROR is set to "true".

As an example, the sample script fragment below sends servo # 4 to position 800 (servo controller is on com port 12):

       TEMP= 800 mod 128                ; get low 7-bits of position

       TEMP3= 800 div 128                ; get high 7-bits of position

       servo 12 132 3 0  $TEMP $TEMP3

       iftrue $COMPORTERROR jump SERVOERROR