RTC
®
5 PC Interface Board
Rev. 1.9 e
10 Commands And Functions
346
Ctrl Command load_varpolydelay
Function loads a table with data points from an ASCII text file for the scaling function of the variable
polygon delay (see page 106).
Call
NoOfDataPoints = load_varpolydelay( Name, No )
Parameters
Name
name of the text file as a pointer to a null-terminated ANSI string
(the text file may contain one or more tables).
No
This parameter (an unsigned 32-bit value) specifies which table in the text file
shall be loaded (the parameter corresponds to the extension
<No>
of the
instruction
[VarPolyTable<No>]
at the beginning of the desired table).
Result signed 32-bit value (a positive error code in case of an error, the negative number of found
data points in case of success):
Value Description
– 1 to – 50 Success.
The absolute value of the return value is equal to the number of valid data points found in the table.
Invalid entries are ignored (see page 106).
–1024 for
Name
= 0: the table initialized according to 1–cos() was internally loaded (as with program
start; see figure 34 on page 104).
1 No valid data points found (though Table
No
found).
3 File not found.
4 DSP memory error
5 BUSY error, board is BUSY or INTERNAL-BUSY, no download (get_last_error return code
RTC5_BUSY
).
8 Board is locked by another application (get_last_error return code
RTC5_ACCESS_DENIED
).
11 PCI error (get_last_error return code
RTC5_SEND_ERROR
),
verify error (get_last_error return code
RTC5_VERIFY_ERROR
)
13 The specified table number was not found in the file.
Comments • The format requirements for text file’s table entries with data points for the customized
variable polygon delay are described in "Customizing the Variable Polygon Delay" on
page 106. When loading the table, the RTC
®
5 determines suitable values for the entire
range of angles by linear interpolation.
• The command load_varpolydelay overwrites any previously loaded table for the
variable polygon delay.
•For
Name
= 0 (as during initialization via load_program_file), the internal (default)
table for the variable polygon delay (1–cos(), see figure 34 on page 104) is loaded.
• The command will not be executed (get_last_error return code:
RTC5_BUSY
) if the
board’s BUSY status is currently set (list is being processed or has been halted via
pause_list) or the board’s INTERNAL-BUSY status is currently set. In contrast, the
command is executed when a list has been paused via set_wait (PAUSED status set).
• During execution of load_varpolydelay, external starts will be suppressed.
• Before loading a table, load_varpolydelay performs a DSP memory check. In case of an
error, error code 4 is returned.
RTC
®
4
RTC
®
5 essentially unchanged functionality, however:
• To return to the internal standard polygon delay table, a reset or renewed program
loading via load_program_file is no longer necessary (unlike with the RTC
®
4; see
Name
= 0 above).
• The ASCII text file can have any filename extension (i.e. not only
*.STB
as with the
RTC
®
4).
References load_program_file, set_delay_mode