IDS Peak comfortSDK, genericSDK, IPL, and AFL developer manuals are external documents. Please contact us if you need them.
Reads or writes the current value of the selected counter.
Writing to CounterValue is typically used to set the start value. |
Name |
CounterValue[CounterSelector] |
Category |
|
Interface |
Integer |
Access |
Read/Write |
Unit |
- |
Visibility |
Expert |
Values |
0 ... 16777215 |
Standard |
SFNC |
Availability uEye+ |
|
Availability uEye |
- |
Code example
C++
// Before accessing CounterValue, make sure CounterSelector is set correctly
// Set CounterSelector to "Counter0"
nodeMapRemoteDevice->FindNode<peak::core::nodes::EnumerationNode>("CounterSelector")->SetCurrentEntry("Counter0");
// Determine the current CounterValue
int64_t value = nodeMapRemoteDevice->FindNode<peak::core::nodes::IntegerNode>("CounterValue")->Value();
// Set CounterValue to 0
nodeMapRemoteDevice->FindNode<peak::core::nodes::IntegerNode>("CounterValue")->SetValue(0);
C#
// Before accessing CounterValue, make sure CounterSelector is set correctly
// Set CounterSelector to "Counter0"
nodeMapRemoteDevice.FindNode<peak.core.nodes.EnumerationNode>("CounterSelector").SetCurrentEntry("Counter0");
// Determine the current CounterValue
long value = nodeMapRemoteDevice.FindNode<peak.core.nodes.IntegerNode>("CounterValue").Value();
// Set CounterValue to 0
nodeMapRemoteDevice.FindNode<peak.core.nodes.IntegerNode>("CounterValue").SetValue(0);
Python
# Before accessing CounterValue, make sure CounterSelector is set correctly
# Set CounterSelector to "Counter0" (str)
nodeMapRemoteDevice.FindNode("CounterSelector").SetCurrentEntry("Counter0")
# Determine the current CounterValue (int)
value = nodeMapRemoteDevice.FindNode("CounterValue").Value()
# Set CounterValue to 0 (int)
nodeMapRemoteDevice.FindNode("CounterValue").SetValue(0)