1#ifndef DECONZ_ZDP_DESCRIPTORS_H
2#define DECONZ_ZDP_DESCRIPTORS_H
15#include <deconz/zcl.h>
18class zme :
public QObject
22 Q_ENUMS(NodeServerMask)
30 PrimaryTrustCenter = (1 << 0),
31 BackupTrustCenter = (1 << 1),
32 PrimaryBindingTableCache = (1 << 2),
33 BackupBindingTableCache = (1 << 3),
34 PrimaryDiscoveryCache = (1 << 4),
35 BackupDiscoveryCache = (1 << 5),
36 NetworkManager = (1 << 6),
39 Q_DECLARE_FLAGS(NodeServerFlags, NodeServerFlag)
42Q_DECLARE_OPERATORS_FOR_FLAGS(zme::NodeServerFlags)
63Q_DECLARE_OPERATORS_FOR_FLAGS(deCONZ::MacCapabilities)
80 PowerSourceUnknown = 0x00,
87Q_DECLARE_OPERATORS_FOR_FLAGS(PowerSources)
100class NodeDescriptorPrivate;
121 void readFromStream(QDataStream &stream);
127 uint16_t manufacturerCode()
const;
133 void setManufacturerCode(quint16 code);
139 MacCapabilities macCapabilities()
const;
141 void setMacCapabilities(MacCapabilities cap);
143 bool hasComplexDescriptor()
const;
145 void setHasComplexDescriptor(
bool hasComplex);
147 bool hasUserDescriptor()
const;
149 void setHasUserDescriptor(
bool hasUser);
155 const char *frequencyBandString()
const;
157 bool isAlternatePanCoordinator()
const;
159 void setIsAlternatePanCoordinator(
bool isAlt);
161 bool isFullFunctionDevice()
const;
163 void setIsFFD(
bool isFFD);
165 bool isMainsPowered()
const;
167 void setIsMainsPowered(
bool isMains);
169 bool receiverOnWhenIdle()
const;
171 void setRxOnWhenIdle(
bool on);
173 bool securitySupport()
const;
175 void setSecuritySupport(
bool supported);
177 bool allocateAddress()
const;
179 bool hasEndpointList()
const;
181 bool hasSimpleDescriptorList()
const;
183 const zme::NodeServerFlags serverMask()
const;
185 uint8_t maxBufferSize()
const;
187 uint16_t maxIncomingTransferSize()
const;
189 uint16_t maxOutgoingTransferSize()
const;
193 void setIsNull(
bool isNull);
195 QByteArray toByteArray()
const;
197 unsigned stackRevision()
const;
227 PowerSources availablePowerSources()
const;
233 bool isValid()
const;
235 QByteArray toByteArray()
const;
265 void readFromStream(QDataStream &stream, quint16 mfcode);
267 void writeToStream(QDataStream &stream)
const;
269 uint8_t endpoint()
const;
271 void setEndpoint(uint8_t endpoint);
273 uint16_t profileId()
const;
275 void setProfileId(uint16_t profileId);
277 uint16_t deviceId()
const;
279 void setDeviceId(uint16_t deviceId);
281 uint8_t deviceVersion()
const;
283 void setDeviceVersion(uint8_t version);
285 bool isValid()
const;
287 std::vector<ZclCluster> &inClusters();
289 const std::vector<ZclCluster> &inClusters()
const;
291 std::vector<ZclCluster> &outClusters();
293 const std::vector<ZclCluster> &outClusters()
const;
297 const std::vector<ZclCluster> &clusters(
ZclClusterSide side)
const;
A strong typed Zigbee manufacturer code.
Definition zcl.h:615
Definition zdp_descriptors.cpp:20
Represents a ZigBee node descriptor.
Definition zdp_descriptors.h:109
Definition zdp_descriptors.cpp:210
Represents a ZigBee power descriptor.
Definition zdp_descriptors.h:212
Definition zdp_descriptors.cpp:318
Represents a ZigBee simple descriptor.
Definition zdp_descriptors.h:254
Represents a ZigBee cluster (ZCL and non-ZCL).
Definition zcl.h:1173
FrequencyBand
ZigBee frequency band.
Definition types.h:415
The deCONZ namespace.
Definition aps.cpp:19
ZclClusterSide
ZCL cluster side where client is a out cluster and server is a in cluster.
Definition zcl.h:912
PowerSourceLevel
Current power source level in node power descriptor.
Definition zdp_descriptors.h:93
@ PowerLevelCritical
Critical.
Definition zdp_descriptors.h:94
@ PowerLevel33
33%
Definition zdp_descriptors.h:95
@ PowerLevel66
66%
Definition zdp_descriptors.h:96
@ PowerLevel100
100%
Definition zdp_descriptors.h:97
MacCapability
IEEE 802.15.4 MAC capabilities.
Definition zdp_descriptors.h:53
@ MacAlternatePanCoordinator
Can be a alternate pan coordinator.
Definition zdp_descriptors.h:54
@ MacDeviceIsFFD
Is a full function device.
Definition zdp_descriptors.h:55
@ MacSecuritySupport
Has (high) security support.
Definition zdp_descriptors.h:58
@ MacReceiverOnWhenIdle
Has receiver on when idle.
Definition zdp_descriptors.h:57
@ MacAllocateAddress
Allocates address.
Definition zdp_descriptors.h:59
@ MacIsMainsPowered
Is mains powered.
Definition zdp_descriptors.h:56
DeviceType
ZigBee device types.
Definition types.h:225
PowerSource
Available power sources in node power descriptor.
Definition zdp_descriptors.h:79
@ PowerSourceMains
Constant (mains) power.
Definition zdp_descriptors.h:81
@ PowerSourceRechargeable
Rechargeable battery.
Definition zdp_descriptors.h:82
@ PowerSourceDisposable
Disposable battery.
Definition zdp_descriptors.h:83
PowerMode
Current power mode in node power descriptor.
Definition zdp_descriptors.h:69
@ ModePeriodic
Receiver comes on periodically as defined by the node power descriptor.
Definition zdp_descriptors.h:71
@ ModeStimulated
Receiver comes on when stimulated, e.g.
Definition zdp_descriptors.h:72
@ ModeOnWhenIdle
Receiver synchronized with the receiver on when idle sub-field of the node descriptor.
Definition zdp_descriptors.h:70
Declaration of the most common deCONZ library types.