SeekDAS S100M4X C++ SDK 0.2.0
seekdas.hpp: C++17 interface over the Rust SDK
Loading...
Searching...
No Matches
seekdas Namespace Reference

Classes

class  Error
struct  IoError
 socket or serial port I/O error More...
struct  TimeoutError
 no answer from the device in time; also: no data while waiting for a run More...
struct  ProtocolError
 received data does not follow the protocol More...
struct  AtError
 the device answered ERROR to an AT command More...
struct  ParseError
 an AT answer could not be parsed More...
struct  ArgumentError
 invalid argument More...
struct  DeviceError
 the device reports an error state (lost points, wrong ID, ...) More...
struct  InternalError
 internal error of the library More...
struct  BusyError
 an acquisition (trigger) is running: no new start and no configuration change until it is done or stopped More...
class  ChannelMask
 A set of inputs (bit i = input i). More...
class  View
 Read-only view of an array owned by the library (Capture, Packet); valid as long as its owner. More...
struct  DeviceInfo
struct  BoardStatus
struct  NetStatus
struct  AcqStatus
struct  StreamStats
struct  RunSummary
struct  WindowStats
struct  TriggerState
 State of the trigger (Device::trigger_state). More...
struct  KernelChoice
 What Config::bandwidth / Trigger::bandwidth choose for a signal bandwidth. More...
class  Config
 Configuration of a run: decimation and kernel, edge detectors, internal generator, the two groups, point count, packet size. More...
class  Trigger
 One trigger run: N points on each target channel, CONV edges from one to four analogue inputs. More...
class  Capture
 Result of a run. Points per group; a trigger run uses group 0. Move-only. More...
struct  Packet
 One point packet from Device::recv. The views are valid until the next call on the same Device. More...
struct  RawCapture
 1024 raw samples of all inputs (Device::raw_capture). More...
struct  DeviceOptions
class  Device
class  RangeTarget
 Target of At::set_range: one input, one slot, or all inputs. More...
struct  AtVersion
struct  AtStatus
struct  SelftestResult
struct  ConvSource
 A CONV source as the management program lists it (AT+CONV?). More...
class  At

Enumerations

enum class  Channel : int {
  S0A , S0B , S0C , S0D ,
  S1A , S1B , S1C , S1D ,
  S2A , S2B , S2C , S2D
}
 Analogue inputs, left to right: slot 0..2, input A..D. Index = 4 * slot + input. More...
enum class  Range : int { V10 = 10 , V5 = 5 , V2 = 2 }
 Input range of the analogue front end. More...
enum class  Edge : int { Rising = SEEKDAS_EDGE_RISING , Falling = SEEKDAS_EDGE_FALLING , Both = SEEKDAS_EDGE_BOTH }
 Edge of a CONV input that produces an event. More...
enum class  Window : int { Ms1 = SEEKDAS_WINDOW_1MS , Ms100 = SEEKDAS_WINDOW_100MS , S1 = SEEKDAS_WINDOW_1S }
 Statistics windows of the bypass statistics. More...
enum class  RunState { Idle = SEEKDAS_RUN_IDLE , Running = SEEKDAS_RUN_RUNNING , Done = SEEKDAS_RUN_DONE }

Functions

std::string library_version ()
 Version of the underlying library, e.g. "0.2.0".
constexpr int index (Channel c) noexcept
Channel channel (int index)
Channel channel (int slot, int input)
std::string to_string (Channel c)
Channel parse_channel (const std::string &s)
 "S0A" .. "S2D" (case-insensitive)
ChannelMask operator| (Channel a, Channel b) noexcept
double code_to_volts (Range r, double code)
 ADC code -> volts with the typical sensitivity of the range (not calibrated per input; offset not corrected).
constexpr std::uint32_t source_detector (int d) noexcept
 Source mask of a group (Config::group): edge detector d, or the internal generator.
const char * to_string (RunState s)
KernelChoice kernel_for_bandwidth (double bandwidth_hz)

Variables

constexpr int kChannels = SEEKDAS_CHANNELS
 12 inputs
constexpr int kRawSamples = SEEKDAS_RAW_SAMPLES
 samples per input of Device::raw_capture
constexpr std::uint32_t kSourceGenerator = SEEKDAS_SRC_GENERATOR

Enumeration Type Documentation

◆ Channel

enum class seekdas::Channel : int
strong

Analogue inputs, left to right: slot 0..2, input A..D. Index = 4 * slot + input.

Enumerator
S0A 
S0B 
S0C 
S0D 
S1A 
S1B 
S1C 
S1D 
S2A 
S2B 
S2C 
S2D 

Definition at line 112 of file seekdas.hpp.

◆ Range

enum class seekdas::Range : int
strong

Input range of the analogue front end.

Enumerator
V10 
V5 
V2 

Definition at line 174 of file seekdas.hpp.

◆ Edge

enum class seekdas::Edge : int
strong

Edge of a CONV input that produces an event.

Enumerator
Rising 
Falling 
Both 

Definition at line 179 of file seekdas.hpp.

◆ Window

enum class seekdas::Window : int
strong

Statistics windows of the bypass statistics.

Enumerator
Ms1 
Ms100 
S1 

Definition at line 182 of file seekdas.hpp.

◆ RunState

enum class seekdas::RunState
strong
Enumerator
Idle 
Running 
Done 

Definition at line 256 of file seekdas.hpp.

Function Documentation

◆ library_version()

std::string seekdas::library_version ( )
inline

Version of the underlying library, e.g. "0.2.0".

Definition at line 104 of file seekdas.hpp.

◆ index()

int seekdas::index ( Channel c)
constexprnoexcept

Definition at line 114 of file seekdas.hpp.

◆ channel() [1/2]

Channel seekdas::channel ( int index)
inline

Definition at line 115 of file seekdas.hpp.

◆ channel() [2/2]

Channel seekdas::channel ( int slot,
int input )
inline

Definition at line 119 of file seekdas.hpp.

◆ to_string() [1/2]

std::string seekdas::to_string ( Channel c)
inline

Definition at line 123 of file seekdas.hpp.

◆ parse_channel()

Channel seekdas::parse_channel ( const std::string & s)
inline

"S0A" .. "S2D" (case-insensitive)

Definition at line 128 of file seekdas.hpp.

◆ operator|()

ChannelMask seekdas::operator| ( Channel a,
Channel b )
inlinenoexcept

Definition at line 171 of file seekdas.hpp.

◆ code_to_volts()

double seekdas::code_to_volts ( Range r,
double code )
inline

ADC code -> volts with the typical sensitivity of the range (not calibrated per input; offset not corrected).

Definition at line 176 of file seekdas.hpp.

◆ source_detector()

std::uint32_t seekdas::source_detector ( int d)
constexprnoexcept

Source mask of a group (Config::group): edge detector d, or the internal generator.

Definition at line 185 of file seekdas.hpp.

◆ to_string() [2/2]

const char * seekdas::to_string ( RunState s)
inline

Definition at line 258 of file seekdas.hpp.

◆ kernel_for_bandwidth()

KernelChoice seekdas::kernel_for_bandwidth ( double bandwidth_hz)
inline

Definition at line 305 of file seekdas.hpp.

Variable Documentation

◆ kChannels

int seekdas::kChannels = SEEKDAS_CHANNELS
constexpr

12 inputs

Definition at line 108 of file seekdas.hpp.

◆ kRawSamples

int seekdas::kRawSamples = SEEKDAS_RAW_SAMPLES
constexpr

samples per input of Device::raw_capture

Definition at line 109 of file seekdas.hpp.

◆ kSourceGenerator

std::uint32_t seekdas::kSourceGenerator = SEEKDAS_SRC_GENERATOR
constexpr

Definition at line 186 of file seekdas.hpp.