6-26 Keypad Programming MN1853Builtin VariablesSome variable names are predefined. They can be used in expressions, to setvoltages, to test conditions, or to display information to the keypad display or anexternal serial device.
Variable Name Description of Builtin Variable Type
(AI1) to (AI6) Analog Inputs 1 through 6 Read Only
(AROWREL) Current status of any of the four arrow keys Read Only
(CPOS1) Commanded position of axis 1 Read Only
(EPOS1) Encoder position of axis 1 Read Only
(VEL1) Commanded velocity of axis 1 Read Only
(POS1) Current Position of axis 1 Read Only
(#F1) thru (#F50) Nonvolatile, limited use, user system variables Read/Limited Write
(FKEY) Value of Function Key pressed Read Only
(LASTKEY) Value of last Function key pressed Read Only
(TERM) Sends variable out RS232 port Write Only
(1TW) Scans inputs 14 for BCD Digit Read Only
(2TW) Scans inputs 18 for BCD Digit Read Only
(TIME) Elapsed Time (ms) since power up or since reset Read Only
(CRCS) Value of the EEPROM setup checksum Read Only
(CRCP) Value of the EEPROM program checksum Read Only
(SA1) Integer value of the status of axis 1 (SeeRS232 command SA) Read Only
(SD1) Integer value of the drive status of axis 1 (See RS232 command SD) Read Only
(SS) Integer value of the system status (See RS232 command SS) Read Only
(INT98CTRL) Enables/disables (ARM INT98) trigger option Read and Write
(ARM INT98) Enables/disables INT98 input if (INT98CTRL) is enabled Read and Write
Examples of how to use Builtin Variables
(PIECES)=10 Assigns 10 to variable
(SPEED)=(AI12)*(VEL SCALE) Speed = analog input times a scalar
MS21,Enter Length IV32,(LENGTH) Prompts user and gets feed length
VE(SPEED) Sets velocity to value in variable
MS1,(POS1) Displays present position of axis 1 on keypad screen
(TERM)=(POS1) Sends the present position of axis 1 out the RS232 port
(TEMPERATURE)=(AI9) Reads in temperature from an analog input
(AO15)=4012 Sets the analog output to 4012
(#F1)=(PIECES) Stores the value of Pieces in FLASH memory variable #F1