digi.xbee.models.accesspoint module¶
-
class
digi.xbee.models.accesspoint.AccessPoint(ssid, encryption_type, channel=0, signal_quality=0)[source]¶ Bases:
objectThis class represents an Access Point for the Wi-Fi protocol. It contains SSID, the encryption type and the link quality between the Wi-Fi module and the access point.
This class is used within the library to list the access points and connect to a specific one in the Wi-Fi protocol.
See also
Class constructor. Instantiates a new
AccessPointobject with the provided parameters.- Parameters
ssid (String) – the SSID of the access point.
encryption_type (
WiFiEncryptionType) – the encryption type configured in the access point.channel (Integer, optional) – operating channel of the access point. Optional.
signal_quality (Integer, optional) – signal quality with the access point in %. Optional.
- Raises
ValueError – if length of
ssidis 0.ValueError – if
channelis less than 0.ValueError – if
signal_qualityis less than 0 or greater than 100.
See also
-
property
ssid¶ String. SSID of the access point.
-
property
encryption_type¶ WiFiEncryptionType. Encryption type of the access point.
-
property
channel¶ String. Channel of the access point.
-
property
signal_quality¶ String. The signal quality with the access point in %.
-
class
digi.xbee.models.accesspoint.WiFiEncryptionType(value)[source]¶ Bases:
enum.EnumEnumerates the different Wi-Fi encryption types.
Values:WiFiEncryptionType.NONE = (0, ‘No security’)WiFiEncryptionType.WPA = (1, ‘WPA (TKIP) security’)WiFiEncryptionType.WPA2 = (2, ‘WPA2 (AES) security’)WiFiEncryptionType.WEP = (3, ‘WEP security’)-
classmethod
get(code)[source]¶ Returns the Wi-Fi encryption type for the given code.
- Parameters
code (Integer) – the code of the Wi-Fi encryption type to get.
- Returns
- the WiFiEncryptionType with the given code,
Noneif there is not any Wi-Fi encryption type with the provided code.
- the WiFiEncryptionType with the given code,
- Return type
-
property
code¶ Integer. The Wi-Fi encryption type code.
-
property
description¶ String. The Wi-Fi encryption type description.
-
classmethod