Contents:
Device class for controlling a MBW 973 SF6 Analyzer over a serial connection.
The MBW 973 is a gas analyzer designed for gas insulated switchgear and measures humidity, SF6 purity and SO2 contamination in one go. Manufacturer homepage: https://www.mbw.ch/products/sf6-gas-analysis/973-sf6-analyzer/
MBW973
Bases: hvl_ccb.dev.base.SingleCommDevice
hvl_ccb.dev.base.SingleCommDevice
MBW 973 dew point mirror device class.
config_cls
Return the default configdataclass class.
a reference to the default configdataclass class
default_com_cls
Get the class for the default communication protocol used with this device.
the type of the standard communication protocol for this device
is_done
Poll status of the dew point mirror and return True, if all measurements are done.
True, if all measurements are done; False otherwise.
SerialCommunicationIOError – when communication port is not opened
read
Read value from self.com and cast to cast_type. Raises ValueError if read text (str) is not convertible to cast_type, e.g. to float or to int.
Read value of cast_type type.
read_float
Convenience wrapper for self.read(), with typing hint for return value.
Read float value.
read_int
Read int value.
read_measurements
Read out measurement values and return them as a dictionary.
Dictionary with values.
set_measuring_options
Send measuring options to the dew point mirror.
humidity – Perform humidity test or not?
sf6_purity – Perform SF6 purity test or not?
start
Start this device. Opens the communication protocol and retrieves the set measurement options from the device.
SerialCommunicationIOError – when communication port cannot be opened.
start_control
Start dew point control to acquire a new value set.
stop
Stop the device. Closes also the communication protocol.
write
Send value to self.com.
value – Value to send, converted to str.
MBW973Config
Bases: object
object
Device configuration dataclass for MBW973.
clean_values
force_value
Forces a value to a dataclass field despite the class being frozen.
NOTE: you can define post_force_value method with same signature as this method to do extra processing after value has been forced on fieldname.
fieldname – name of the field
value – value to assign
is_configdataclass
keys
Returns a list of all configdataclass fields key-names.
a list of strings containing all keys.
optional_defaults
Returns a list of all configdataclass fields, that have a default value assigned and may be optionally specified on instantiation.
a list of strings containing all optional keys.
polling_interval
Polling period for is_done status queries [in seconds].
required_keys
Returns a list of all configdataclass fields, that have no default value assigned and need to be specified on instantiation.
a list of strings containing all required keys.
MBW973ControlRunningException
Bases: hvl_ccb.dev.mbw973.MBW973Error
hvl_ccb.dev.mbw973.MBW973Error
Error indicating there is still a measurement running, and a new one cannot be started.
MBW973Error
Bases: Exception
Exception
General error with the MBW973 dew point mirror device.
MBW973PumpRunningException
Error indicating the pump of the dew point mirror is still recovering gas, unable to start a new measurement.
MBW973SerialCommunication
Bases: hvl_ccb.comm.serial.SerialCommunication
hvl_ccb.comm.serial.SerialCommunication
Specific communication protocol implementation for the MBW973 dew point mirror. Already predefines device-specific protocol parameters in config.
MBW973SerialCommunicationConfig
Bases: hvl_ccb.comm.serial.SerialCommunicationConfig
hvl_ccb.comm.serial.SerialCommunicationConfig
baudrate
Baudrate for MBW973 is 9600 baud
bytesize
One byte is eight bits long
parity
MBW973 does not use parity
stopbits
MBW973 does use one stop bit
terminator
The terminator is only CR
timeout
use 3 seconds timeout as default