XBee C# library API reference

Show / Hide Table of Contents

Class DigiPointDevice

This class represents a local Poit-to-multipoint device.

Inheritance
System.Object
AbstractXBeeDevice
XBeeDevice
DigiPointDevice
Inherited Members
XBeeDevice.PacketReceived
XBeeDevice.DataReceived
XBeeDevice.IOSampleReceived
XBeeDevice.ModemStatusReceived
XBeeDevice.UserDataRelayReceived
XBeeDevice.BluetoothDataReceived
XBeeDevice.MicroPythonDataReceived
XBeeDevice.OperatingMode
XBeeDevice.IsOpen
XBeeDevice.IsRemote
XBeeDevice.ReceiveTimeout
XBeeDevice.Close()
XBeeDevice.GetNextFrameID()
XBeeDevice.GetDestinationAddress()
XBeeDevice.SetDestinationAddress(XBee64BitAddress)
XBeeDevice.GetPANID()
XBeeDevice.SetPANID(Byte[])
XBeeDevice.GetDIOChangeDetection()
XBeeDevice.SetDIOChangeDetection(ISet<IOLine>)
XBeeDevice.GetIOSamplingRate()
XBeeDevice.SetIOSamplingRate(Int32)
XBeeDevice.GetPowerLevel()
XBeeDevice.SetPowerLevel(PowerLevel)
XBeeDevice.SendDataAsync(RemoteXBeeDevice, Byte[])
XBeeDevice.SendData(RemoteXBeeDevice, Byte[])
XBeeDevice.SendBroadcastData(Byte[])
XBeeDevice.SendUserDataRelay(XBeeLocalInterface, Byte[])
XBeeDevice.SendBluetoothData(Byte[])
XBeeDevice.SendMicroPythonData(Byte[])
XBeeDevice.SendPacket(XBeePacket, EventHandler<PacketReceivedEventArgs>)
XBeeDevice.SendPacketAsync(XBeePacket)
XBeeDevice.SendPacket(XBeePacket)
XBeeDevice.Reset()
XBeeDevice.ReadData()
XBeeDevice.ReadData(Int32)
XBeeDevice.ReadDataFrom(RemoteXBeeDevice)
XBeeDevice.ReadDataFrom(RemoteXBeeDevice, Int32)
XBeeDevice.ReadUserDataRelay()
XBeeDevice.ReadUserDataRelay(Int32)
AbstractXBeeDevice.DEFAULT_RECEIVE_TIMETOUT
AbstractXBeeDevice.TIMEOUT_BEFORE_COMMAND_MODE
AbstractXBeeDevice.TIMEOUT_ENTER_COMMAND_MODE
AbstractXBeeDevice.PARAMETER_NODE_ID
AbstractXBeeDevice.TIMEOUT_READ_PACKET
AbstractXBeeDevice.dataReader
AbstractXBeeDevice.currentFrameID
AbstractXBeeDevice.receiveTimeout
AbstractXBeeDevice.localXBeeDevice
AbstractXBeeDevice.logger
AbstractXBeeDevice.bluetoothPassword
AbstractXBeeDevice.network
AbstractXBeeDevice.SerialDataReceived
AbstractXBeeDevice.SMSReceived
AbstractXBeeDevice.IPDataReceived
AbstractXBeeDevice.FirmwareVersion
AbstractXBeeDevice.HardwareVersion
AbstractXBeeDevice.HardwareVersionString
AbstractXBeeDevice.XBee16BitAddr
AbstractXBeeDevice.XBee64BitAddr
AbstractXBeeDevice.SignalStrength
AbstractXBeeDevice.ApplyConfigurationChangesEnabled
AbstractXBeeDevice.NodeID
AbstractXBeeDevice.IsInitialized
AbstractXBeeDevice.ConnectionInterface
AbstractXBeeDevice.ReadDeviceInfo()
AbstractXBeeDevice.SetIOConfiguration(IOLine, IOMode)
AbstractXBeeDevice.GetIOConfiguration(IOLine)
AbstractXBeeDevice.SetDIOValue(IOLine, IOValue)
AbstractXBeeDevice.GetDIOValue(IOLine)
AbstractXBeeDevice.SetPWMDutyCycle(IOLine, Double)
AbstractXBeeDevice.GetPWMDutyCycle(IOLine)
AbstractXBeeDevice.GetADCValue(IOLine)
AbstractXBeeDevice.ApplyChanges()
AbstractXBeeDevice.ReadIOSample()
AbstractXBeeDevice.SetParameter(String, Byte[])
AbstractXBeeDevice.GetParameter(String)
AbstractXBeeDevice.ExecuteParameter(String)
AbstractXBeeDevice.SoftwareReset()
AbstractXBeeDevice.ToString()
AbstractXBeeDevice.SetNodeID(String)
AbstractXBeeDevice.WriteChanges()
AbstractXBeeDevice.EnableBluetooth()
AbstractXBeeDevice.DisableBluetooth()
AbstractXBeeDevice.GetBluetoothMacAddress()
AbstractXBeeDevice.UpdateBluetoothPassword(String)
AbstractXBeeDevice.GetAddressString()
AbstractXBeeDevice.SendATCommand(ATCommand)
AbstractXBeeDevice.SendXBeePacketAsync(XBeePacket)
AbstractXBeeDevice.SendXBeePacket(XBeePacket, EventHandler<PacketReceivedEventArgs>)
AbstractXBeeDevice.SendXBeePacket(XBeePacket)
AbstractXBeeDevice.SendAndCheckXBeePacket(XBeePacket, Boolean)
AbstractXBeeDevice.CheckATCommandResponseIsValid(ATCommandResponse)
AbstractXBeeDevice.GetAssociationIndicationStatus()
AbstractXBeeDevice.ForceDisassociate()
AbstractXBeeDevice.SendSerialData(Byte[])
AbstractXBeeDevice.DetermineOperatingMode()
AbstractXBeeDevice.SendExplicitDataAsync(XBee64BitAddress, XBee16BitAddress, Byte, Byte, Byte[], Byte[], Byte[])
AbstractXBeeDevice.SendExplicitData(XBee64BitAddress, XBee16BitAddress, Byte, Byte, Byte[], Byte[], Byte[])
AbstractXBeeDevice.SendData(XBee64BitAddress, Byte[])
AbstractXBeeDevice.SendData(XBee64BitAddress, XBee16BitAddress, Byte[])
AbstractXBeeDevice.SendDataAsync(XBee64BitAddress, Byte[])
AbstractXBeeDevice.SendDataAsync(XBee64BitAddress, XBee16BitAddress, Byte[])
AbstractXBeeDevice.SetBluetoothPassword(String)
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
Namespace: XBeeLibrary.Core
Assembly: XBeeLibrary.Core.dll
Syntax
public class DigiPointDevice : XBeeDevice

Constructors

DigiPointDevice(IConnectionInterface)

Class constructor. Instantiates a new DigiPointDevice object with the given connection interface.

Declaration
public DigiPointDevice(IConnectionInterface connectionInterface)
Parameters
Type Name Description
IConnectionInterface connectionInterface

The connection interface with the physical point-to-multipoint device.

Exceptions
Type Condition
System.ArgumentNullException

If connectionInterface == null.

See Also
XBeeDevice(IConnectionInterface)
IConnectionInterface

Properties

APIOutputMode

The API output mode of the XBee device.

Declaration
public APIOutputMode APIOutputMode { get; set; }
Property Value
Type Description
APIOutputMode
Remarks

The API output mode determines the format that the received data is output through the serial interface of the XBee device.

Exceptions
Type Condition
ATCommandEmptyException

If the returned value of the API Output Mode command is null or empty.

See Also
APIOutputMode

XBeeProtocol

The protocol of the XBee device.

Declaration
public override XBeeProtocol XBeeProtocol { get; }
Property Value
Type Description
XBeeProtocol
Overrides
AbstractXBeeDevice.XBeeProtocol
See Also
DIGI_POINT

Methods

GetNetwork()

Returns the network associated with this XBee device.

Declaration
public override XBeeNetwork GetNetwork()
Returns
Type Description
XBeeNetwork

The XBee network of the device.

Overrides
XBeeDevice.GetNetwork()
Exceptions
Type Condition
InterfaceNotOpenException

If this device connection is not open.

See Also
XBeeNetwork
DigiPointNetwork

Open()

Opens the connection interface associated with this XBee device.

Declaration
public override void Open()
Overrides
XBeeDevice.Open()
Remarks

When opening the device an information reading process is automatically performed. This includes:

Exceptions
Type Condition
InterfaceAlreadyOpenException

If this device connection is already open.

InvalidOperatingModeException

If the operating mode of the device is UNKNOWN or AT

BluetoothAuthenticationException

If the BLE authentication process fails.

TimeoutException

If the timeout to read settings when initializing the device elapses without response.

XBeeException

If there is any problem opening this device connection.

See Also
IsOpen
Close()

ReadExplicitData()

Reads new explicit data received by this XBee device during the configured receive timeout.

Declaration
public ExplicitXBeeMessage ReadExplicitData()
Returns
Type Description
ExplicitXBeeMessage

An ExplicitXBeeMessage object containing the explicit data, the source address of the remote node that sent the data and other values related to the transmission. null if this did not receive new explicit data during the configured receive timeout.

Remarks

This method blocks until new explicit data is received or the configured receive timeout expires.

For non-blocking operations, register an event handler to ExplicitDataReceived.

Exceptions
Type Condition
InterfaceNotOpenException

If the interface is not open.

See Also
ExplicitXBeeMessage
ReadExplicitData()

ReadExplicitData(Int32)

Reads new explicit data received by this XBee device during the configured receive timeout.

Declaration
public ExplicitXBeeMessage ReadExplicitData(int timeout)
Parameters
Type Name Description
System.Int32 timeout

The time to wait for new explicit data in milliseconds.

Returns
Type Description
ExplicitXBeeMessage

An ExplicitXBeeMessage object containing the explicit data, the source address of the remote node that sent the data and other values related to the transmission. null if this did not receive new explicit data during the configured receive timeout.

Remarks

This method blocks until new explicit data is received or the configured receive timeout expires.

For non-blocking operations, register an event handler to ExplicitDataReceived.

Exceptions
Type Condition
System.ArgumentException

If timeout < 0.

InterfaceNotOpenException

If the interface is not open.

See Also
ExplicitXBeeMessage
ReadExplicitData(System.Int32)

ReadExplicitDataFrom(RemoteXBeeDevice)

Reads new explicit data received from the given remote XBee device during the configured receive timeout.

Declaration
public ExplicitXBeeMessage ReadExplicitDataFrom(RemoteXBeeDevice remoteXBeeDevice)
Parameters
Type Name Description
RemoteXBeeDevice remoteXBeeDevice

The remote device to read explicit data from.

Returns
Type Description
ExplicitXBeeMessage

An ExplicitXBeeMessage object containing the explicit data, the source address of the remote node that sent the data and other values related to the transmission. null if this device did not receive new explicit data from the provided remote XBee device during the configured receive timeout.

Remarks

This method blocks until new explicit data from the provided remote XBee device is received or the configured receive timeout expires.

For non-blocking operations, register an event handler to ExplicitDataReceived.

Exceptions
Type Condition
System.ArgumentNullException

If remoteXBeeDevice == null.

InterfaceNotOpenException

If the interface is not open.

See Also
ExplicitXBeeMessage
RemoteXBeeDevice
ReadExplicitDataFrom(RemoteXBeeDevice)

ReadExplicitDataFrom(RemoteXBeeDevice, Int32)

Reads new explicit data received from the given remote XBee device during the provided timeout.

Declaration
public ExplicitXBeeMessage ReadExplicitDataFrom(RemoteXBeeDevice remoteXBeeDevice, int timeout)
Parameters
Type Name Description
RemoteXBeeDevice remoteXBeeDevice

The remote device to read explicit data from.

System.Int32 timeout

The time to wait for new explicit data in milliseconds.

Returns
Type Description
ExplicitXBeeMessage

An ExplicitXBeeMessage object containing the explicit data, the source address of the remote node that sent the data and other values related to the transmission. null if this device did not receive new data from the provided remote XBee device during timeout milliseconds.

Remarks

This method blocks until new explicit data from the provided remote XBee device is received or the given timeout expires.

For non-blocking operations, register an event handler to ExplicitDataReceived.

Exceptions
Type Condition
System.ArgumentException

If timeout < 0.

System.ArgumentNullException

If remoteXBeeDevice == null.

InterfaceNotOpenException

If the interface is not open.

See Also
ExplicitXBeeMessage
RemoteXBeeDevice
ReadExplicitDataFrom(RemoteXBeeDevice, System.Int32)

SendBroadcastExplicitData(Byte, Byte, Byte[], Byte[], Byte[])

Sends the provided data to all the XBee nodes of the network (broadcast) in application layer mode. Application layer mode means that you need to specify the application layer fields to be sent with the data.

Declaration
public void SendBroadcastExplicitData(byte sourceEndpoint, byte destEndpoint, byte[] clusterID, byte[] profileID, byte[] data)
Parameters
Type Name Description
System.Byte sourceEndpoint

Source endpoint for the transmission.

System.Byte destEndpoint

Destination endpoint for the transmission.

System.Byte[] clusterID

Cluster ID used in the transmission.

System.Byte[] profileID

Profile ID used in the transmission.

System.Byte[] data

Byte array containing the data to be sent.

Remarks

This method blocks till a success or error response arrives or the configured receive timeout expires.

Exceptions
Type Condition
System.ArgumentNullException

If data == null.

System.ArgumentException

If clusterID.Length != 2 or if profileID.Length != 2.

InterfaceNotOpenException

If the interface is not open.

TimeoutException

If there is a timeout sending the given packet synchronously.

TransmitException

If the transmit status generated when sending the packet is not an instance of TransmitStatusPacket or if it is not an instance of TXStatusPacket or if when it is correct, its status is different from SUCCESS.

XBeeException

If there is any other XBee related error.

See Also
SendBroadcastExplicitData(System.Byte, System.Byte, System.Byte[], System.Byte[], System.Byte[])

SendExplicitData(XBee64BitAddress, Byte, Byte, Byte[], Byte[], Byte[])

Sends the provided data in application layer mode to the XBee device of the network corresponding to the given 64-bit address. Application layer mode means that you need to specify the application layer fields to be sent with the data.

Declaration
public void SendExplicitData(XBee64BitAddress address, byte sourceEndpoint, byte destEndpoint, byte[] clusterID, byte[] profileID, byte[] data)
Parameters
Type Name Description
XBee64BitAddress address

The 64-bit address of the XBee that will receive the data.

System.Byte sourceEndpoint

Source endpoint for the transmission.

System.Byte destEndpoint

Destination endpoint for the transmission.

System.Byte[] clusterID

Cluster ID used in the transmission.

System.Byte[] profileID

Profile ID used in the transmission.

System.Byte[] data

Byte array containing the data to be sent.

Remarks

This method blocks till a success or error response arrives or the configured receive timeout expires.

Exceptions
Type Condition
System.ArgumentNullException

If address == null or if data == null.

System.ArgumentException

If clusterID.Length != 2 or if profileID.Length != 2.

InterfaceNotOpenException

If the interface is not open.

OperationNotSupportedException

If the sender device is remote.

TimeoutException

If there is a timeout sending the given packet synchronously.

TransmitException

If the transmit status generated when sending the packet is not an instance of TransmitStatusPacket or if it is not an instance of TXStatusPacket or if when it is correct, its status is different from SUCCESS.

XBeeException

If there is any other XBee related error.

See Also
XBee64BitAddress
SendExplicitData(XBee64BitAddress, System.Byte, System.Byte, System.Byte[], System.Byte[], System.Byte[])

SendExplicitData(RemoteXBeeDevice, Byte, Byte, Byte[], Byte[], Byte[])

Sends the provided data in application layer mode to the provided XBee device choosing the optimal send method depending on the protocol of the local XBee device. Application layer mode means that you need to specify the application layer fields to be sent with the data.

Declaration
public void SendExplicitData(RemoteXBeeDevice remoteXBeeDevice, byte sourceEndpoint, byte destEndpoint, byte[] clusterID, byte[] profileID, byte[] data)
Parameters
Type Name Description
RemoteXBeeDevice remoteXBeeDevice

The XBee device of the network that will receive the data.

System.Byte sourceEndpoint

Source endpoint for the transmission.

System.Byte destEndpoint

Destination endpoint for the transmission.

System.Byte[] clusterID

Cluster ID used in the transmission.

System.Byte[] profileID

Profile ID used in the transmission.

System.Byte[] data

Byte array containing the data to be sent.

Remarks

This method blocks till a success or error response arrives or the configured receive timeout expires.

Exceptions
Type Condition
System.ArgumentNullException

If remoteXBeeDevice == null or if data == null.

System.ArgumentException

If clusterID.Length != 2 or if profileID.Length != 2.

InterfaceNotOpenException

If the interface is not open.

TimeoutException

If there is a timeout sending the given packet synchronously.

TransmitException

If the transmit status generated when sending the packet is not an instance of TransmitStatusPacket or if it is not an instance of TXStatusPacket or if when it is correct, its status is different from SUCCESS.

XBeeException

If there is any other XBee related error.

See Also
RemoteXBeeDevice
SendExplicitData(RemoteXBeeDevice, System.Byte, System.Byte, System.Byte[], System.Byte[], System.Byte[])

SendExplicitDataAsync(XBee64BitAddress, Byte, Byte, Byte[], Byte[], Byte[])

Sends asynchronously the provided data in application layer mode to the XBee device of the network corresponding to the given 64-bit address. Application layer mode means that you need to specify the application layer fields to be sent with the data.

Declaration
public void SendExplicitDataAsync(XBee64BitAddress address, byte sourceEndpoint, byte destEndpoint, byte[] clusterID, byte[] profileID, byte[] data)
Parameters
Type Name Description
XBee64BitAddress address

The 64-bit address of the XBee that will receive the data.

System.Byte sourceEndpoint

Source endpoint for the transmission.

System.Byte destEndpoint

Destination endpoint for the transmission.

System.Byte[] clusterID

Cluster ID used in the transmission.

System.Byte[] profileID

Profile ID used in the transmission.

System.Byte[] data

Byte array containing the data to be sent.

Remarks

Asynchronous transmissions do not wait for answer from the remote device or for transmit status packet.

Exceptions
Type Condition
System.ArgumentNullException

If address == null or if data == null.

System.ArgumentException

If clusterID.Length != 2 or if profileID.Length != 2.

InterfaceNotOpenException

If the interface is not open.

OperationNotSupportedException

If the sender device is remote.

See Also
XBee64BitAddress
SendExplicitDataAsync(XBee64BitAddress, System.Byte, System.Byte, System.Byte[], System.Byte[], System.Byte[])

SendExplicitDataAsync(RemoteXBeeDevice, Byte, Byte, Byte[], Byte[], Byte[])

Sends asynchronously the provided data in application layer mode to the provided XBee device choosing the optimal send method depending on the protocol of the local XBee device. Application layer mode means that you need to specify the application layer fields to be sent with the data.

Declaration
public void SendExplicitDataAsync(RemoteXBeeDevice remoteXBeeDevice, byte sourceEndpoint, byte destEndpoint, byte[] clusterID, byte[] profileID, byte[] data)
Parameters
Type Name Description
RemoteXBeeDevice remoteXBeeDevice

The XBee device of the network that will receive the data.

System.Byte sourceEndpoint

Source endpoint for the transmission.

System.Byte destEndpoint

Destination endpoint for the transmission.

System.Byte[] clusterID

Cluster ID used in the transmission.

System.Byte[] profileID

Profile ID used in the transmission.

System.Byte[] data

Byte array containing the data to be sent.

Remarks

Asynchronous transmissions do not wait for answer from the remote device or for transmit status packet.

Exceptions
Type Condition
System.ArgumentNullException

If remoteXBeeDevice == null or if data == null.

System.ArgumentException

If clusterID.Length != 2 or if profileID.Length != 2.

InterfaceNotOpenException

If the interface is not open.

OperationNotSupportedException

If the sender device is remote.

See Also
RemoteXBeeDevice
SendExplicitDataAsync(RemoteXBeeDevice, System.Byte, System.Byte, System.Byte[], System.Byte[], System.Byte[])

Events

ExplicitDataReceived

Represents the method that will handle the explicit data received event.

Declaration
public event EventHandler<ExplicitDataReceivedEventArgs> ExplicitDataReceived
Event Type
Type Description
System.EventHandler<ExplicitDataReceivedEventArgs>
Exceptions
Type Condition
System.ArgumentNullException

If the event handler is null.

See Also
ExplicitDataReceivedEventArgs

See Also

CellularDevice
DigiMeshDevice
Raw802Device
XBeeDevice
ZigBeeDevice
Product page More documentation Official site About Digi Contact us Support
©2019 Digi International Inc. All rights reserved.
Digi International Inc.