The QKnxPsuMode class is a datapoint type for storing the bus power supply unit mode. 更多...
头: | #include <QKnxPsuMode> |
qmake: | QT += knx |
继承: | QKnx1Byte |
enum class | Mode { Disabled, Enabled, Automatic, Invalid } |
QKnxPsuMode (QKnxPsuMode::Mode mode ) | |
QKnxPsuMode () | |
QKnxPsuMode::Mode | mode () const |
bool | setMode (QKnxPsuMode::Mode mode ) |
A bus power supply unit is required for bus communications. It can be either a decentral (distributed) bus power supply unit, DPSU, or a central bus power supply unit, PSU.
The DPSU or PSU can be activated or deactivated also by mechanical means, such as using a jumper or a switch. The supported range is product specific. For example, disabled/enabled only or disabled/auto only.
The range for the
Mode
value is from
Disabled, 0
to
Automatic, 2
.
This is a fixed size datapoint type with the length of 1 byte.
另请参阅 QKnxDatapointType , QKnx1Byte ,和 Qt KNX Datapoint Type Classes .
This enum holds the bus power supply unit mode stored in the datapoint type.
常量 | 值 | 描述 |
---|---|---|
QKnxPsuMode::Mode::Disabled
|
0x00
|
The PSU or DPSU in the device is switched off. |
QKnxPsuMode::Mode::Enabled
|
0x01
|
The PSU or DPSU in the device is switched on. |
QKnxPsuMode::Mode::Automatic
|
0x02
|
The PSU or DPSU in the device was turned on or off automatically. For example, by sending a message on the bus. |
QKnxPsuMode::Mode::Invalid
|
0xff
|
The mode is invalid. |
Creates a fixed size datapoint type with the mode set to mode .
Creates a fixed size datapoint type with the mode set to
Disabled
.
Returns the mode stored in the datapoint type.
另请参阅 setMode ().
Sets the mode stored in the datapoint type to mode .
返回
true
if the byte was set; otherwise returns
false
.
另请参阅 mode ().