
Section 11: TSP command reference
Series 3700A System Switch/Multimeter Reference Manual
11-112
3700AS-901-01 Rev. D/June 2018
Example
MaxCount = dataqueue.CAPACITY
while dataqueue.count < MaxCount do
dataqueue.add(1)
end
print("There are " .. dataqueue.count
.. " items in the data queue")
This example fills the data queue until it is full
and prints the number of items in the queue.
Output:
There are 128 items in the data
queue
Also see
(on page 11-110)
(on page 11-112)
(on page 11-113)
(on page 11-114)
Using the data queue for real-time communication
(on page 10-61)
dataqueue.clear()
This function clears the data queue.
Type
TSP-Link accessible
Affected by
Where saved
Default value
Function
Yes
Usage
dataqueue.clear()
Details
This function forces all
dataqueue.add()
commands that are in progress to time out and deletes all
data from the data queue.
Example
MaxCount = dataqueue.CAPACITY
while dataqueue.count < MaxCount do
dataqueue.add(1)
end
print("There are " .. dataqueue.count
.. " items in the data queue")
dataqueue.clear()
print("There are " .. dataqueue.count
.. " items in the data queue")
This example fills the data queue and prints the
number of items in the queue. It then clears the
queue and prints the number of items again.
Output:
There are 128 items in the data
queue
There are 0 items in the data queue
Also see
(on page 11-110)
(on page 11-111)
(on page 11-113)
(on page 11-114)
Using the data queue for real-time communication
(on page 10-61)