ERROR!
You must enable Java Script on your browser to navigate this site. |
||
Importing Data from a FileIn many cases it may be desirable to import data from an external file and use it as the parameters in a test operation. This can easily be accomplished using the First put together a text file that contains multiple lines of numerical data to represent the different voltage settings you wish to transmit to the Analog Output Module. Have each number on a separate line in the file so that it's easier to read and modify. Then write a Script that executes the following steps. Step 1: Use the "Read from File" function to read the very next line of data from the text file and send the data to a Step 2: Use the "Transmit Command" function to transmit a voltage setting to the Analog Output Module and use the Text Window as the numerical portion of the command string like this: AVA{TextWindow1} Step 3: Use the "Start a Script" function to restart this Script so that it runs in a continuous loop. To stop the Script use a Conditional statement as described below. The above Script can then be started using a Stopping the ScriptIf a Script is running in a continuous loop as in the case shown above, it will read each line of data from the text file until reaching the end, and then loop back around to the beginning and repeat the process. If wishing to stop the Script at the end of the file, or anywhere
|