RTC
®
5 PC Interface Board
Rev. 1.9 e
10 Commands And Functions
294
Ctrl Command get_waveform
Function transfers to the PC the data that was measured and stored onto the RTC
®
5 via set_trigger
or set_trigger4
Call
get_waveform( Channel, Number, Ptr )
Parameters
Channel
measurement channel [1 or 2; if recordings started via set_trigger4, then also
3 or 4]; specified as an unsigned 32-bit value
Number
number [1…2
20
for set_trigger, 1…2
19
for set_trigger4] of measured values
to transfer; specified as an unsigned 32-bit value. Values of measurement
positions 0 to (
Number
–1) will be transferred.
Ptr
pointer (in C and C++ data type ULONG_PTR, i.e. an unsigned 32-bit or 64-bit
value) to a location in the PC’s memory to where the measured values should
be transferred
Comments • In the following cases, no data is transferred (get_last_error return code
RTC5_PARAM_ERROR
):
–if
Number
= 0
–if
Number
> 2
20
–if
Number
> 2
19
when
Channel
= 3 or 4 was selected or if a file was loaded as cor-
rection table
No
=3 or
No
=4 with load_correction_file
–if
Ptr
= NULL
• PCI transmission errors will generate the get_last_error return code
RTC5_SEND_ERROR
.
• Before calling get_waveform, you can check via measurement_status whether a
measurement session is currently running that was started with set_trigger or
set_trigger4. We recommend not reading any data when data recording is currently
active. The number
Pos
for the last (or current) data pair of the measurement session
can be queried via measurement_status. No more than
Pos
+1 data elements should
be read. Any further elements are from earlier recordings or the initialization.
RTC
®
4
RTC
®
5 Essentially unchanged functionality, however:
Even in RTC
®
4 compatibility mode, all values are in the RTC
®
5’s 20-bit range, but get
transferred to the PC as 32-bit data. Therefore, you must evaluate the values accordingly
(see comments for get_value).
Version info Last change with version DLL 536, OUT 536:
Channel
= 3 and 4
References set_trigger, set_trigger4, get_value, get_values