4 template<>
const SR_API std::map<const enum sr_loglevel, const LogLevel * const> EnumValue<LogLevel, enum sr_loglevel>::_values;
42 static const DataType *
const UINT64;
43 static const DataType *
const STRING;
46 static const DataType *
const RATIONAL_PERIOD;
47 static const DataType *
const RATIONAL_VOLT;
48 static const DataType *
const KEYVALUE;
49 static const DataType *
const UINT64_RANGE;
50 static const DataType *
const DOUBLE_RANGE;
53 static const DataType *
const UINT32;
62 static const DataType _RATIONAL_PERIOD;
63 static const DataType _RATIONAL_VOLT;
116 static const Quantity *
const VOLTAGE;
117 static const Quantity *
const CURRENT;
118 static const Quantity *
const RESISTANCE;
119 static const Quantity *
const CAPACITANCE;
120 static const Quantity *
const TEMPERATURE;
121 static const Quantity *
const FREQUENCY;
126 static const Quantity *
const PULSE_WIDTH;
127 static const Quantity *
const CONDUCTANCE;
194 static const Quantity _SOUND_PRESSURE_LEVEL;
195 static const Quantity _CARBON_MONOXIDE;
196 static const Quantity _RELATIVE_HUMIDITY;
200 static const Quantity _PARALLEL_INDUCTANCE;
201 static const Quantity _PARALLEL_CAPACITANCE;
202 static const Quantity _PARALLEL_RESISTANCE;
203 static const Quantity _SERIES_INDUCTANCE;
204 static const Quantity _SERIES_CAPACITANCE;
205 static const Quantity _SERIES_RESISTANCE;
206 static const Quantity _DISSIPATION_FACTOR;
207 static const Quantity _QUALITY_FACTOR;
211 static const Quantity _POWER_FACTOR;
212 static const Quantity _APPARENT_POWER;
214 static const Quantity _HARMONIC_RATIO;
216 static const Quantity _ELECTRIC_CHARGE;
308 Unit(
enum sr_unit
id,
const char name[]) :
EnumValue(id, name) {}
310 static const Unit _VOLT;
311 static const Unit _AMPERE;
312 static const Unit _OHM;
313 static const Unit _FARAD;
314 static const Unit _KELVIN;
315 static const Unit _CELSIUS;
316 static const Unit _FAHRENHEIT;
317 static const Unit _HERTZ;
318 static const Unit _PERCENTAGE;
319 static const Unit _BOOLEAN;
320 static const Unit _SECOND;
321 static const Unit _SIEMENS;
322 static const Unit _DECIBEL_MW;
323 static const Unit _DECIBEL_VOLT;
324 static const Unit _UNITLESS;
325 static const Unit _DECIBEL_SPL;
326 static const Unit _CONCENTRATION;
327 static const Unit _REVOLUTIONS_PER_MINUTE;
328 static const Unit _VOLT_AMPERE;
329 static const Unit _WATT;
330 static const Unit _WATT_HOUR;
331 static const Unit _METER_SECOND;
332 static const Unit _HECTOPASCAL;
333 static const Unit _HUMIDITY_293K;
334 static const Unit _DEGREE;
335 static const Unit _HENRY;
336 static const Unit _GRAM;
337 static const Unit _CARAT;
338 static const Unit _OUNCE;
339 static const Unit _TROY_OUNCE;
340 static const Unit _POUND;
341 static const Unit _PENNYWEIGHT;
342 static const Unit _GRAIN;
343 static const Unit _TAEL;
344 static const Unit _MOMME;
345 static const Unit _TOLA;
346 static const Unit _PIECE;
347 static const Unit _JOULE;
348 static const Unit _COULOMB;
349 static const Unit _AMPERE_HOUR;
404 static std::vector<const QuantityFlag *>
405 flags_from_mask(
unsigned int mask);
408 static unsigned int mask_from_flags(
409 std::vector<const QuantityFlag *> flags);
479 static const OutputFlag _INTERNAL_IO_HANDLING;
741 std::string identifier()
const;
743 std::string description()
const;
745 static const ConfigKey *get_by_identifier(std::string identifier);
747 static Glib::VariantBase parse_string(std::string value,
enum sr_datatype dt);
748 Glib::VariantBase parse_string(std::string value)
const;
767 static const ConfigKey _SIGNAL_GENERATOR;
783 static const ConfigKey _HORIZ_TRIGGERPOS;
795 static const ConfigKey _SPL_MEASUREMENT_RANGE;
798 static const ConfigKey _VOLTAGE_THRESHOLD;
801 static const ConfigKey _CENTER_FREQUENCY;
802 static const ConfigKey _NUM_LOGIC_CHANNELS;
803 static const ConfigKey _NUM_ANALOG_CHANNELS;
810 static const ConfigKey _OVER_VOLTAGE_PROTECTION_ENABLED;
811 static const ConfigKey _OVER_VOLTAGE_PROTECTION_ACTIVE;
812 static const ConfigKey _OVER_VOLTAGE_PROTECTION_THRESHOLD;
813 static const ConfigKey _OVER_CURRENT_PROTECTION_ENABLED;
814 static const ConfigKey _OVER_CURRENT_PROTECTION_ACTIVE;
815 static const ConfigKey _OVER_CURRENT_PROTECTION_THRESHOLD;
819 static const ConfigKey _OVER_TEMPERATURE_PROTECTION;
820 static const ConfigKey _OUTPUT_FREQUENCY;
821 static const ConfigKey _OUTPUT_FREQUENCY_TARGET;
822 static const ConfigKey _MEASURED_QUANTITY;
823 static const ConfigKey _EQUIV_CIRCUIT_MODEL;
824 static const ConfigKey _OVER_TEMPERATURE_PROTECTION_ACTIVE;
825 static const ConfigKey _UNDER_VOLTAGE_CONDITION;
826 static const ConfigKey _UNDER_VOLTAGE_CONDITION_ACTIVE;
828 static const ConfigKey _UNDER_VOLTAGE_CONDITION_THRESHOLD;
829 static const ConfigKey _EXTERNAL_CLOCK_SOURCE;
835 static const ConfigKey _LOGIC_THRESHOLD_CUSTOM;
842 static const ConfigKey _RESISTANCE_TARGET;
843 static const ConfigKey _OVER_CURRENT_PROTECTION_DELAY;
846 static const ConfigKey _CAPTURE_UNITSIZE;
850 static const ConfigKey _ADC_POWERLINE_CYCLES;
static const LogLevel *const SPEW
Output very noisy debug messages.
static const Unit *const DECIBEL_MW
An absolute measurement of power, in decibels, referenced to 1 milliwatt (dBm).
static const ConfigKey *const LOGIC_THRESHOLD
Logic threshold: predefined levels (TTL, ECL, CMOS, etc).
static const ConfigKey *const POWER_TARGET
Power target.
static const PacketType *const END
End of stream (no further data).
static const Unit *const GRAIN
Mass in grain [gr].
static const Unit *const UNITLESS
Measurements that intrinsically do not have units attached, such as ratios, gains, etc.
static const ConfigKey *const ENERGYMETER
The device can measure energy consumption.
static const ConfigKey *const OVER_CURRENT_PROTECTION_ENABLED
Over-current protection (OCP) feature.
static const ConfigKey *const SPL_WEIGHT_TIME
Sound pressure level time weighting.
static const ConfigKey *const EXTERNAL_CLOCK_SOURCE
Which external clock source to use if the device supports multiple external clock channels...
static const ConfigKey *const OVER_VOLTAGE_PROTECTION_THRESHOLD
Over-voltage protection (OVP) threshold.
static const PacketType *const HEADER
Payload is.
static const QuantityFlag *const SPL_TIME_WEIGHT_F
Sound pressure level measurement is F-weighted (125ms) in the time domain.
static const Unit *const TAEL
Mass in tael (variants: Hong Kong, Singapore/Malaysia, Taiwan)
static const ConfigKey *const TRIGGER_SLOPE
The device supports setting trigger slope.
static const ConfigKey *const SWAP
The device supports swapping channels.
static const ConfigKey *const SIGNAL_GENERATOR
The device can act as a function generator.
static const Capability *const SET
Value can be written.
static const ConfigKey *const DATALOG
The device has internal storage, into which data is logged.
static const Unit *const REVOLUTIONS_PER_MINUTE
Revolutions per minute.
static const ConfigKey *const OVER_CURRENT_PROTECTION_THRESHOLD
Over-current protection (OCP) threshold.
static const Quantity *const POWER_FACTOR
Power factor.
static const ConfigKey *const SPL_WEIGHT_FREQ
Sound pressure level frequency weighting.
static const ConfigKey *const PHASE
Phase of a source signal.
static const Unit *const DECIBEL_VOLT
Voltage in decibel, referenced to 1 volt (dBV).
static const ConfigKey *const OVER_VOLTAGE_PROTECTION_ACTIVE
Over-voltage protection (OVP) active.
static const ConfigKey *const MODBUSADDR
Modbus slave address specification.
Configuration capability.
static const QuantityFlag *const FOUR_WIRE
Measurement is four wire (e.g.
static const ConfigKey *const UNDER_VOLTAGE_CONDITION_ACTIVE
Under-voltage condition active.
static const PacketType *const FRAME_BEGIN
Beginning of frame.
static const ChannelType *const LOGIC
Channel type is logic channel.
static const PacketType *const META
Payload is struct.
static const ConfigKey *const AMPLITUDE
Amplitude of a source without strictly-defined MQ.
static const Unit *const MOMME
Mass in momme.
static const ConfigKey *const FORCE_DETECT
User specified forced driver attachment to unknown devices.
static const ConfigKey *const RANGE
The measurement range of a DMM or the output range of a power supply.
static const QuantityFlag *const SPL_FREQ_WEIGHT_C
Sound pressure level is C-weighted in the frequency domain, according to IEC 61672:2003.
static const ConfigKey *const TRIGGER_SOURCE
Trigger source.
static const ConfigKey *const DUTY_CYCLE
Duty cycle of a source signal.
static const QuantityFlag *const SPL_TIME_WEIGHT_S
Sound pressure level measurement is S-weighted (1s) in the time domain.
static const QuantityFlag *const MAX
Device is in "max" mode, only updating upon a new max value.
static const PacketType *const FRAME_END
End of frame.
static const ConfigKey *const HIGH_RESOLUTION
High resolution mode.
static const QuantityFlag *const SPL_FREQ_WEIGHT_Z
Sound pressure level is Z-weighted (i.e.
static const LogLevel *const INFO
Output informational messages.
static const ConfigKey *const DEMO_DEV
The device is a demo device.
static const ConfigKey *const LOGIC_THRESHOLD_CUSTOM
Logic threshold: custom numerical value.
static const ConfigKey *const ADC_POWERLINE_CYCLES
Number of powerline cycles for ADC integration time.
static const ConfigKey *const CONN
Specification on how to connect to a device.
static const Quantity *const ENERGY
Energy.
static const Unit *const PERCENTAGE
Percent value.
static const Unit *const CELSIUS
Degrees Celsius (temperature).
static const Unit *const HERTZ
Hertz (frequency, 1/s, [Hz]).
static const ConfigKey *const NUM_ANALOG_CHANNELS
The device supports setting the number of analog channels.
static const QuantityFlag *const DURATION
Time is duration (as opposed to epoch, ...).
static const QuantityFlag *const SPL_FREQ_WEIGHT_A
Sound pressure level is A-weighted in the frequency domain, according to IEC 61672:2003.
static const ConfigKey *const RLE
The device supports run-length encoding (RLE).
static const ConfigKey *const DATA_SOURCE
Data source for acquisition.
static const ConfigKey *const VOLTAGE
Current voltage.
static const Quantity *const CONTINUITY
Continuity test.
static const Unit *const FARAD
Farad (capacity).
static const Unit *const PENNYWEIGHT
Mass in pennyweight [dwt].
static const Quantity *const DISSIPATION_FACTOR
Dissipation factor.
static const ConfigKey *const HOLD_MAX
Max hold mode.
static const Quantity *const QUALITY_FACTOR
Quality factor.
static const Unit *const WATT
Real power [W].
static const ConfigKey *const CURRENT_LIMIT
Current limit.
static const ConfigKey *const HORIZ_TRIGGERPOS
Horizontal trigger position.
static const Unit *const TROY_OUNCE
Mass in troy ounce [oz t].
static const QuantityFlag *const AUTORANGE
Device is in autoranging mode.
static const ConfigKey *const FILTER
Filter.
static const ConfigKey *const POWER_OFF
Power off the device.
static const ConfigKey *const SAMPLERATE
The device supports setting its samplerate, in Hz.
static const Unit *const JOULE
Energy in joule.
static const QuantityFlag *const DIODE
Value is voltage drop across a diode, or NAN.
static const Quantity *const TIME
Time.
static const ConfigKey *const ENABLED
Enabling/disabling channel.
static const QuantityFlag *const HOLD
Device is in "hold" mode (repeating the last measurement).
static const ConfigKey *const MULTIMETER
The device can act as a multimeter.
static const Quantity *const HARMONIC_RATIO
Harmonic ratio.
static const QuantityFlag *const MIN
Device is in "min" mode, only updating upon a new min value.
static const Quantity *const MASS
Mass.
static const ConfigKey *const CONTINUOUS
The device supports continuous sampling.
static const ConfigKey *const TIMEBASE
Time base.
static const Quantity *const CARBON_MONOXIDE
Carbon monoxide level.
static const ConfigKey *const TRIGGER_PATTERN
The device supports setting a pattern for the logic trigger.
static const Quantity *const ELECTRIC_CHARGE
Electric charge.
static const Unit *const DECIBEL_SPL
Sound pressure level, in decibels, relative to 20 micropascals.
static const ConfigKey *const CAPTUREFILE
The device supports specifying a capturefile to inject.
static const OutputFlag *const INTERNAL_IO_HANDLING
If set, this output module writes the output itself.
static const ChannelType *const ANALOG
Channel type is analog channel.
static const Unit *const COULOMB
Electric charge in coulomb.
static const Quantity *const POWER
Electrical power, usually in W, or dBm.
static const Quantity *const SOUND_PRESSURE_LEVEL
Logarithmic representation of sound pressure relative to a reference value.
static const Quantity *const APPARENT_POWER
Apparent power.
static const ConfigKey *const TRIGGER_LEVEL
Trigger level.
static const ConfigKey *const HYGROMETER
The device can measure humidity.
static const Unit *const WATT_HOUR
Energy (consumption) in watt hour [Wh].
static const Unit *const BOOLEAN
Boolean value.
static const Unit *const HUMIDITY_293K
Relative humidity assuming air temperature of 293 Kelvin (rF).
static const ConfigKey *const POWER
Current power.
static const ConfigKey *const SCALE
The device can act as a scale.
static const QuantityFlag *const DC
Voltage measurement is direct current (DC).
static const PacketType *const TRIGGER
The trigger matched at this point in the data feed.
static const Capability *const LIST
Possible values can be enumerated.
static const Quantity *const PARALLEL_INDUCTANCE
Parallel inductance (LCR meter model).
static const Quantity *const SERIES_INDUCTANCE
Series inductance (LCR meter model).
static const PacketType *const ANALOG
Payload is struct.
static const QuantityFlag *const UNSTABLE
Unstable value (hasn't settled yet).
static const Quantity *const COUNT
Count.
static const ConfigKey *const OUTPUT_FREQUENCY_TARGET
Output frequency target in Hz.
static const ConfigKey *const DEVICE_MODE
Device mode for multi-function devices.
static const PacketType *const LOGIC
Payload is struct.
static const ConfigKey *const PROBE_FACTOR
The device supports setting a probe factor.
static const ConfigKey *const SPL_MEASUREMENT_RANGE
Sound pressure level measurement range.
static const ConfigKey *const POWER_SUPPLY
The device can act as a programmable power supply.
static const ConfigKey *const MEASURED_QUANTITY
Measured quantity.
static const ConfigKey *const NUM_VDIV
Number of vertical divisions, as related to SR_CONF_VDIV.
static const ConfigKey *const EQUIV_CIRCUIT_MODEL
Equivalent circuit model.
static const QuantityFlag *const SPL_LAT
Sound pressure level is time-averaged (LAT), also known as Equivalent Continuous A-weighted Sound Lev...
static const Quantity *const PARALLEL_RESISTANCE
Parallel resistance (LCR meter model).
static const ConfigKey *const LIMIT_FRAMES
The device supports setting a frame limit (how many frames should be acquired).
static const ConfigKey *const MULTIPLEXER
The device can switch between multiple sources, e.g.
static const Quantity *const PRESSURE
Pressure.
static const Capability *const GET
Value can be read.
static const ConfigKey *const OVER_VOLTAGE_PROTECTION_ENABLED
Over-voltage protection (OVP) feature.
static const Quantity *const RELATIVE_HUMIDITY
Humidity.
static const ConfigKey *const EXTERNAL_CLOCK
The device supports using an external clock.
static const ConfigKey *const DIGITS
The number of digits (e.g.
static const ConfigKey *const THERMOMETER
The device can measure temperature.
static const QuantityFlag *const SPL_FREQ_WEIGHT_FLAT
Sound pressure level is not weighted in the frequency domain, albeit without standards-defined low an...
static const ConfigKey *const CENTER_FREQUENCY
Center frequency.
static const ConfigKey *const ELECTRONIC_LOAD
The device can act as an electronic load.
static const ConfigKey *const TRIGGER_MATCH
Trigger matches.
static const ConfigKey *const POWERMETER
The device can measure power.
static const QuantityFlag *const AC
Voltage measurement is alternating current (AC).
static const ConfigKey *const LIMIT_MSEC
The device supports setting a sample time limit (how long the sample acquisition should run...
static const ConfigKey *const NUM_LOGIC_CHANNELS
The device supports setting the number of logic channels.
static const ConfigKey *const OVER_TEMPERATURE_PROTECTION
Over-temperature protection (OTP)
Flag applied to output modules.
static const QuantityFlag *const RMS
This is a true RMS measurement.
static const Unit *const POUND
Mass in pound [lb].
static const ConfigKey *const LCRMETER
The device can act as an LCR meter.
Base class for objects which wrap an enumeration value from libsigrok.
static const Quantity *const GAIN
Gain (a transistor's gain, or hFE, for example).
static const Unit *const KELVIN
Kelvin (temperature).
static const ConfigKey *const CAPTURE_RATIO
The device supports setting a pre/post-trigger capture ratio.
static const ConfigKey *const SESSIONFILE
Session filename.
static const Unit *const METER_SECOND
Wind speed in meters per second.
static const Unit *const DEGREE
Plane angle in 1/360th of a full circle.
static const ConfigKey *const OVER_CURRENT_PROTECTION_ACTIVE
Over-current protection (OCP) active.
static const ConfigKey *const OVER_CURRENT_PROTECTION_DELAY
Over-current protection (OCP) delay.
static const LogLevel *const ERR
Output error messages.
static const ConfigKey *const OVER_TEMPERATURE_PROTECTION_ACTIVE
Over-temperature protection (OTP) active.
static const ConfigKey *const RESISTANCE_TARGET
Resistance target.
static const ConfigKey *const COUPLING
Coupling.
static const Quantity *const PHASE_ANGLE
Phase angle.
static const ConfigKey *const VDIV
Volts/div.
static const Unit *const GRAM
Mass in gram [g].
static const Quantity *const SERIES_RESISTANCE
Series resistance (LCR meter model).
static const ConfigKey *const BUFFERSIZE
Buffer size.
static const ConfigKey *const CURRENT
Current current.
static const Unit *const SECOND
Time in seconds.
static const Unit *const CONCENTRATION
Normalized (0 to 1) concentration of a substance or compound with 0 representing a concentration of 0...
static const Unit *const VOLT
Volt.
static const Unit *const HENRY
Henry (inductance).
Flag applied to measured quantity.
static const LogLevel *const WARN
Output warnings.
static const LogLevel *const DBG
Output debug messages.
static const ConfigKey *const LOGIC_ANALYZER
The device can act as logic analyzer.
static const ConfigKey *const NUM_HDIV
Number of horizontal divisions, as related to SR_CONF_TIMEBASE.
static const ConfigKey *const AVG_SAMPLES
The device supports setting number of samples to be averaged over.
static const ConfigKey *const HOLD_MIN
Min hold mode.
static const ConfigKey *const SOUNDLEVELMETER
The device can act as a sound level meter.
static const Unit *const CARAT
Mass in carat [ct].
static const Quantity *const PARALLEL_CAPACITANCE
Parallel capacitance (LCR meter model).
static const ConfigKey *const OUTPUT_FREQUENCY
Output frequency in Hz.
static const ConfigKey *const OSCILLOSCOPE
The device can act as an oscilloscope.
static const Unit *const VOLT_AMPERE
Apparent power [VA].
static const Unit *const AMPERE_HOUR
Electric charge in ampere hour [Ah].
static const LogLevel *const NONE
Output no messages at all.
static const QuantityFlag *const REFERENCE
Reference value shown.
static const ConfigKey *const SERIALCOMM
Serial communication specification, in the form:
static const Unit *const OHM
Ohm (resistance).
static const ConfigKey *const SAMPLE_INTERVAL
The device supports setting its sample interval, in ms.
static const ConfigKey *const PROBE_NAMES
Override builtin probe names from user specs.
static const Unit *const FAHRENHEIT
Degrees Fahrenheit (temperature).
static const ConfigKey *const TEST_MODE
Self test mode.
static const Unit *const HECTOPASCAL
Pressure in hectopascal.
static const ConfigKey *const VOLTAGE_THRESHOLD
Logic low-high threshold range.
static const Unit *const AMPERE
Ampere (current).
static const Quantity *const DIFFERENCE
Difference from reference value.
static const Quantity *const SERIES_CAPACITANCE
Series capacitance (LCR meter model).
static const Quantity *const WIND_SPEED
Wind speed.
static const ConfigKey *const DEMODULATOR
The device can act as a signal demodulator.
static const Unit *const TOLA
Mass in tola.
static const ConfigKey *const CHANNEL_CONFIG
Channel configuration.
static const ConfigKey *const REGULATION
Channel regulation get: "CV", "CC" or "UR", denoting constant voltage, constant current or unregulate...
static const ConfigKey *const PATTERN_MODE
The device supports setting a pattern (pattern generator mode).
static const QuantityFlag *const AVG
Device is in "avg" mode, averaging upon each new value.
static const Unit *const SIEMENS
Unit of conductance, the inverse of resistance.
static const ConfigKey *const UNDER_VOLTAGE_CONDITION_THRESHOLD
Under-voltage condition threshold.
static const ConfigKey *const UNDER_VOLTAGE_CONDITION
Under-voltage condition.
static const Unit *const OUNCE
Mass in ounce [oz].
static const ConfigKey *const CLOCK_EDGE
Choice of clock edge for external clock ("r" or "f").
static const ConfigKey *const CAPTURE_UNITSIZE
The device supports specifying the capturefile unit size.
static const ConfigKey *const VOLTAGE_TARGET
Maximum target voltage.
static const QuantityFlag *const RELATIVE
Device is in relative mode.
static const Unit *const PIECE
Pieces (number of items).
static const ConfigKey *const PEAK_DETECTION
Peak detection.
static const QuantityFlag *const SPL_PCT_OVER_ALARM
Sound pressure level represented as a percentage of measurements that were over a preset alarm level...
static const Quantity *const DUTY_CYCLE
Duty cycle, e.g.
static const ConfigKey *const LIMIT_SAMPLES
The device supports setting a sample number limit (how many samples should be acquired).
static const ConfigKey *const AVERAGING
The device supports averaging.
static const ConfigKey *const OFFSET
Offset of a source without strictly-defined MQ.