InWord

(Engine-Level Function)

Deprecated. This function relies on the VTSIO driver, which is no longer included in new installations. Will continue to function in legacy installations but should not be used in new code.

Description: Read I/O Word. This function reads a 16 bit unsigned word from an I/O port.
Returns: Word
Usage: Script or steady state.
Function Groups: Memory I/O
Related to: In | Out | OutWord
Format: InWord(Port)
Parameters:  
Port   
Required. Any numeric expression that gives the I/O address. Port must be in the range 0 to 65535.
Comments: This function requires that the VTSIO driver be installed.
This is a high priority function. If InWord is used in a state, it will be evaluated at a very fast rate. InWord should be used sparingly to avoid reducing system performance.

Examples:

reg = InWord(0x300);

This reads reg as a 16 bit unsigned word from input port 300 hex. If this statement appears in a script, it is executed when the script is executed (when the action is triggered). If it appears in a state, it will be updated rapidly as a high priority function.