Skip to content

sigrok plugin

Plugin name sigrok
Type read
Callbacks config, init,shutdown
Status supported
Since 5.4
Copyright 2013 Bert Vermeulen
Configuration collectd.conf(5)

The sigrok plugin …

Description

The sigrok project aims at creating a portable, cross-platform, Free/Libre/Open-Source signal analysis software suite that supports various device types, such as logic analyzers, MSOs, oscilloscopes, multimeters, LCR meters, sound level meters, thermometers, hygrometers, anemometers, light meters, DAQs, dataloggers, function generators, spectrum analyzers, power supplies, GPIB interfaces, and more.

The sigrok plugin is a fully fledged libsigrok client, and can use any supported hardware to feed measurements to collectd. Only analog sources are supported.

Hardware supported by libsigrok generally provides samples at much higher than 1Hz. The default output plugin in collectd, RRDtool, cannot deal with updates more than once per second, so the MinimumInterval keyword is recommended in this case.

Synopsis

collectd configuration:

 <Plugin "sigrok">
    LogLevel 3
    <Device "Sound level">
        Driver "cem-dt-885x"
        Conn "/dev/ttyUSB3"
        MinimumInterval 1
    </Device>
    <Device "Temperature">
        Driver "uni-t-ut32x"
        conn "1a86.e008"
        MinimumInterval 1
    </Device>
 </Plugin>

Example graphs

Dependencies

Configuration

Configuration options · from collectd.conf(5)

See this section in the full configuration reference

The sigrok plugin uses libsigrok to retrieve measurements from any device supported by the sigrok project.

Synopsis

<Plugin sigrok>
  LogLevel 3
  <Device "AC Voltage">
     Driver "fluke-dmm"
     MinimumInterval 10
     Conn "/dev/ttyUSB2"
  </Device>
  <Device "Sound Level">
     Driver "cem-dt-885x"
     Conn "/dev/ttyUSB1"
  </Device>
</Plugin>
LogLevel 0-5
The sigrok logging level to pass on to the collectd log, as a number between 0 and 5 (inclusive). These levels correspond to None, Errors, Warnings, Informational, Debugand Spew, respectively. The default is 2 (Warnings). The sigrok log messages, regardless of their level, are always submitted to collectd at its INFO log level.
<Device Name>
A sigrok-supported device, uniquely identified by this section's options. The Name is passed to collectd as the plugin instance.
Driver DriverName
The sigrok driver to use for this device.
Conn ConnectionSpec
If the device cannot be auto-discovered, or more than one might be discovered by the driver, ConnectionSpec specifies the connection string to the device. It can be of the form of a device path (e.g. /dev/ttyUSB2), or, in case of a non-serial USB-connected device, the USB VendorID.ProductID separated by a period (e.g. 0403.6001). A USB device can also be specified as Bus.Address (e.g. 1.41).
SerialComm SerialSpec
For serial devices with non-standard port settings, this option can be used to specify them in a form understood by sigrok, e.g. 9600/8n1. This should not be necessary; drivers know how to communicate with devices they support.
MinimumInterval Seconds

Specifies the minimum time between measurement dispatches to collectd, in seconds. Since some sigrok supported devices can acquire measurements many times per second, it may be necessary to throttle these. For example, the RRD plugin cannot process writes more than once per second.

The default MinimumInterval is 0, meaning measurements received from the device are always dispatched to collectd. When throttled, unused measurements are discarded.