dmi_range_switching_type
Synopsis
#include <opendmi/entity/power-supply.h>
typedef enum dmi_range_switching_type {
DMI_RANGE_SWITCHING_TYPE_UNSPEC = 0x00,
DMI_RANGE_SWITCHING_TYPE_OTHER = 0x01,
DMI_RANGE_SWITCHING_TYPE_UNKNOWN = 0x02,
DMI_RANGE_SWITCHING_TYPE_MANUAL = 0x03,
DMI_RANGE_SWITCHING_TYPE_AUTO = 0x04,
DMI_RANGE_SWITCHING_TYPE_WIDE = 0x05,
DMI_RANGE_SWITCHING_TYPE_NOT_APPLICABLE = 0x06,
} dmi_range_switching_type_t;
const char *dmi_range_switching_type_name(dmi_range_switching_type_t value);
Description
The dmi_range_switching_type_t enumeration tells how a power supply selects
the range of its input voltage, and is the type of the range_switching field
of dmi_power_supply_t. The field is four bits wide; the values from 0x07 to
0x0F are reserved by the specification.
The dmi_range_switching_type_name function returns the name of a value, as
the command line tool shows it. The name is translated to the locale set with
dmi_set_locale if the library is built with ICU4C support and the locale has
a translation of it, and is in English otherwise.
Values
DMI_RANGE_SWITCHING_TYPE_UNSPEC-
Unspecified. The specification defines no value of zero.
DMI_RANGE_SWITCHING_TYPE_OTHER-
Other way, which none of the values below names.
DMI_RANGE_SWITCHING_TYPE_UNKNOWN-
Unknown.
DMI_RANGE_SWITCHING_TYPE_MANUAL-
The range is selected by hand.
DMI_RANGE_SWITCHING_TYPE_AUTO-
The range is selected automatically.
DMI_RANGE_SWITCHING_TYPE_WIDE-
The supply accepts a wide range of input voltages, with no switching.
DMI_RANGE_SWITCHING_TYPE_NOT_APPLICABLE-
Range switching does not apply to the supply.
Return value
dmi_range_switching_type_name returns the name of the value, or nullptr if
the value has no name, e.g. a value the specification reserves. The string
belongs to the library and must not be modified or freed; a translated name may
become invalid once the locale is changed.