EasyManuals Logo

Tektronix Keithley 2601B-PULSE Reference Manual

Tektronix Keithley 2601B-PULSE
849 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #396 background imageLoading...
Page #396 background image
Section 11: TSP command reference Model 2601B-PULSE System SourceMeter Instrument Reference Manual
11-38 2601B-PULSE-901-01A April 2020
dataqueue.add()
This function adds an entry to the data queue.
Type
TSP-Link accessible
Affected by
Where saved
Default value
Function
Yes
Usage
result = dataqueue.add(value)
result = dataqueue.add(value, timeout)
result
The resulting value of true or false based on the success of the function
value
The data item to add; value can be of any type
timeout
The maximum number of seconds to wait for space in the data queue
Details
You cannot use the timeout value when accessing the data queue from a remote node (you can
only use the timeout value while adding data to the local data queue).
The timeout value is ignored if the data queue is not full.
The dataqueue.add() function returns false:
â–ª If the timeout expires before space is available in the data queue
â–ª If the data queue is full and a timeout value is not specified
If the value is a table, a duplicate of the table and any subtables is made. The duplicate table does
not contain any references to the original table or to any subtables.
Example
dataqueue.clear()
dataqueue.add(10)
dataqueue.add(11, 2)
result = dataqueue.add(12, 3)
if result == false then
print("Failed to add 12 to the dataqueue")
end
print("The dataqueue contains:")
while dataqueue.count > 0 do
print(dataqueue.next())
end
Clear the data queue.
Each line adds one item to the data queue.
Output:
The dataqueue contains:
10
11
12
Also see
dataqueue.CAPACITY (on page 11-39)
dataqueue.clear() (on page 11-39)
dataqueue.count (on page 11-40)
dataqueue.next() (on page 11-41)
Using the data queue for real-time communication (on page 10-56)

Table of Contents

Other manuals for Tektronix Keithley 2601B-PULSE

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Tektronix Keithley 2601B-PULSE and is the answer not in the manual?

Tektronix Keithley 2601B-PULSE Specifications

General IconGeneral
BrandTektronix
ModelKeithley 2601B-PULSE
CategoryMeasuring Instruments
LanguageEnglish

Related product manuals