digi.xbee.models.mode module¶
-
class
digi.xbee.models.mode.OperatingMode(value)[source]¶ Bases:
enum.EnumThis class represents all operating modes available.
Inherited properties:name (String): the name (id) of this OperatingMode.value (String): the value of this OperatingMode.Values:OperatingMode.AT_MODE = (0, ‘AT mode’)OperatingMode.API_MODE = (1, ‘API mode’)OperatingMode.ESCAPED_API_MODE = (2, ‘API mode with escaped characters’)OperatingMode.MICROPYTHON_MODE = (4, ‘MicroPython REPL’)OperatingMode.BYPASS_MODE = (5, ‘Bypass mode’)OperatingMode.UNKNOWN = (99, ‘Unknown’)-
property
code¶ Returns the code of the OperatingMode element.
- Returns
the code of the OperatingMode element.
- Return type
String
-
property
description¶ Returns the description of the OperatingMode element.
- Returns
the description of the OperatingMode element.
- Return type
String
-
property
-
class
digi.xbee.models.mode.APIOutputMode(value)[source]¶ Bases:
enum.EnumEnumerates the different API output modes. The API output mode establishes the way data will be output through the serial interface of an XBee device.
Inherited properties:name (String): the name (id) of this OperatingMode.value (String): the value of this OperatingMode.Values:APIOutputMode.NATIVE = (0, ‘Native’)APIOutputMode.EXPLICIT = (1, ‘Explicit’)APIOutputMode.EXPLICIT_ZDO_PASSTHRU = (3, ‘Explicit with ZDO Passthru’)-
property
code¶ Returns the code of the APIOutputMode element.
- Returns
the code of the APIOutputMode element.
- Return type
String
-
property
description¶ Returns the description of the APIOutputMode element.
- Returns
the description of the APIOutputMode element.
- Return type
String
-
property
-
class
digi.xbee.models.mode.APIOutputModeBit(value)[source]¶ Bases:
enum.EnumEnumerates the different API output mode bit options. The API output mode establishes the way data will be output through the serial interface of an XBee.
Inherited properties:name (String): the name (id) of this APIOutputModeBit.value (String): the value of this APIOutputModeBit.Values:APIOutputModeBit.EXPLICIT = (1, ‘Output in Native/Explicit API format’)APIOutputModeBit.SUPPORTED_ZDO_PASSTHRU = (2, ‘Zigbee: Supported ZDO request pass-throughn802.15.4/DigiMesh: Legacy API Indicator’)APIOutputModeBit.UNSUPPORTED_ZDO_PASSTHRU = (4, ‘Unsupported ZDO request pass-through. Only Zigbee’)APIOutputModeBit.BINDING_PASSTHRU = (8, ‘Binding request pass-through. Only Zigbee’)APIOutputModeBit.ECHO_RCV_SUPPORTED_ZDO = (16, ‘Echo received supported ZDO requests out the serial port. Only Zigbee’)APIOutputModeBit.SUPPRESS_ALL_ZDO_MSG = (32, ‘Suppress all ZDO messages from being sent out the serial port and disable pass-through. Only Zigbee’)-
property
code¶ Returns the code of the APIOutputModeBit element.
- Returns
the code of the APIOutputModeBit element.
- Return type
Integer
-
property
description¶ Returns the description of the APIOutputModeBit element.
- Returns
the description of the APIOutputModeBit element.
- Return type
String
-
classmethod
get(code)[source]¶ Returns the APIOutputModeBit for the given code.
- Parameters
code (Integer) – the code corresponding to the API output mode to get.
- Returns
- the APIOutputModeBit with the given code,
None if not found.
- Return type
-
classmethod
calculate_api_output_mode_value(protocol, options)[source]¶ Calculates the total value of a combination of several option bits for the given protocol.
- Parameters
protocol (
digi.xbee.models.protocol.XBeeProtocol) – The XBeeProtocol to calculate the value of all the given API output options.options – Collection of option bits to get the final value.
- Returns
- The value to be configured in the module depending on the
given collection of option bits and the protocol.
- Return type
Integer
-
property
-
class
digi.xbee.models.mode.IPAddressingMode(value)[source]¶ Bases:
enum.EnumEnumerates the different IP addressing modes.
Values:IPAddressingMode.DHCP = (0, ‘DHCP’)IPAddressingMode.STATIC = (1, ‘Static’)-
property
code¶ Returns the code of the IPAddressingMode element.
- Returns
the code of the IPAddressingMode element.
- Return type
String
-
property
description¶ Returns the description of the IPAddressingMode element.
- Returns
the description of the IPAddressingMode element.
- Return type
String
-
property
-
class
digi.xbee.models.mode.NeighborDiscoveryMode(value)[source]¶ Bases:
enum.EnumEnumerates the different neighbor discovery modes. This mode establishes the way the network discovery process is performed.
Inherited properties:name (String): the name (id) of this OperatingMode.value (String): the value of this OperatingMode.Values:NeighborDiscoveryMode.CASCADE = (0, ‘Cascade’)NeighborDiscoveryMode.FLOOD = (1, ‘Flood’)-
CASCADE= (0, 'Cascade')¶ The discovery of a node neighbors is requested once the previous request finishes. This means that just one discovery process is running at the same time.
This mode is recommended for large networks, it might be a slower method but it generates less traffic than ‘Flood’.
-
FLOOD= (1, 'Flood')¶ The discovery of a node neighbors is requested when the node is found in the network. This means that several discovery processes might be running at the same time.
-
property
code¶ Returns the code of the NeighborDiscoveryMode element.
- Returns
the code of the NeighborDiscoveryMode element.
- Return type
String
-
property
description¶ Returns the description of the NeighborDiscoveryMode element.
- Returns
the description of the NeighborDiscoveryMode element.
- Return type
String
-