Update doc strings

This commit is contained in:
Triston Armstrong 2021-09-21 10:27:39 -05:00
parent 6cd1e8506f
commit a595f61602
28 changed files with 310 additions and 177 deletions

View File

@ -1,14 +1,20 @@
class CircuitBreakerInterface():
""" This class provides a common interface to a circuit breaker on an Extron product (extronlib.device). The user can instantiate the class directly or create a subclass to add, remove, or alter behavior for different types of devices.
---
Arguments:
- Host (object) - handle to Extron device class that instantiated this interface class
- Port (string) - port name (e.g. 'CBR1')
---
Parameters:
- Host - Returns (extronlib.device) - handle to Extron device class that instantiated this interface class
- Port - Returns (string) - port name
- State - Returns (string) - current state of the circuit breaker ('Closed', 'Tripped')
---
Events:
- Offline - (Event) Triggers when the device goes offline. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('Offline').

View File

@ -7,6 +7,8 @@ class ClientObject():
Note:
- This class cannot be instantiated by the programmer. It is only created by the `EthernetServerInterfaceEx` object.
---
Parameters:
- Hostname - Returns (string) - Hostname DNS name of the connection. Can be the IP Address
- IPAddress - Returns (string) - the IP Address of the connected device

View File

@ -1,14 +1,20 @@
class ContactInterface():
""" This class will provide a common interface for controlling and collecting data from Contact Input ports on Extron devices (extronlib.device). The user can instantiate the class directly or create a subclass to add, remove, or alter behavior for different types of devices.
---
Arguments:
- Host (extronlib.device) - handle to Extron device class that instantiated this interface class
- Port (string) - port name (e.g. 'CII1')
---
Parameters:
- Host - Returns (extronlib.device) - handle to Extron device class that instantiated this interface class
- Port - Returns (string) - port name
- State - Returns (string) - current state of IO port ('On', 'Off')
---
Events:
- Offline - (Event) Triggers when port goes offline. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('Offline').

View File

@ -1,23 +1,29 @@
class DigitalIOInterface():
""" This class will provide a common interface for controlling and collecting data from Digital IO ports on Extron devices (extronlib.device). The user can instantiate the class directly or create a subclass to add, remove, or alter behavior for different types of devices.
---
Arguments:
Host (extronlib.device) - handle to Extron device class that instantiated this interface class
Port (string) - port name (e.g. 'DIO1')
(optional) Mode (string) - Possible modes are: 'DigitalInput' (default), and 'DigitalOutput'
(optional) Pullup (bool) - pull-up state on the port
- Host (extronlib.device) - handle to Extron device class that instantiated this interface class
- Port (string) - port name (e.g. 'DIO1')
- (optional) Mode (string) - Possible modes are: 'DigitalInput' (default), and 'DigitalOutput'
- (optional) Pullup (bool) - pull-up state on the port
---
Parameters:
Host - Returns (extronlib.device) - handle to Extron device class that instantiated this interface class
Mode - Returns (string) - mode of the Digital IO port ('DigitalInput', 'DigitalOutput')
Port - Returns (string) - port name
Pullup - Returns (bool) - indicates if the Input port is being pulled up or not
State - Returns (string) - current state of Input port ('On', 'Off')
- Host - Returns (extronlib.device) - handle to Extron device class that instantiated this interface class
- Mode - Returns (string) - mode of the Digital IO port ('DigitalInput', 'DigitalOutput')
- Port - Returns (string) - port name
- Pullup - Returns (bool) - indicates if the Input port is being pulled up or not
- State - Returns (string) - current state of Input port ('On', 'Off')
---
Events:
Offline - (Event) Triggers when port goes offline. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('Offline').
Online - (Event) Triggers when port goes online. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('Online').
StateChanged - (Event) Triggers when the input state changes. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('On' or 'Off').
- Offline - (Event) Triggers when port goes offline. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('Offline').
- Online - (Event) Triggers when port goes online. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('Online').
- StateChanged - (Event) Triggers when the input state changes. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('On' or 'Off').
"""
Host = None
Port = ''

View File

@ -1,16 +1,22 @@
class DigitalInputInterface():
""" This class will provide a common interface for collecting data from Digital Input ports on Extron devices (extronlib.device). he user can instantiate the class directly or create a subclass to add, remove, or alter behavior for different types of devices.
---
Arguments:
- Host (extronlib.device) - handle to Extron device class that instantiated this interface class
- Port (string) - port name (e.g. 'DII1')
- (optional) Pullup (bool) - pull-up state on the port
---
Parameters:
- Host - Returns (extronlib.device) - handle to Extron device class that instantiated this interface class
- Port - Returns (string) - port name
- Pullup - Returns (bool) - indicates if the Input port is being pulled up or not
- State - Returns (string) - current state of Input port ('On', 'Off')
---
Events:
- Offline - (Event) Triggers when port goes offline. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('Offline').

View File

@ -4,31 +4,30 @@ class EthernetClientInterface():
Note: In synchronous mode, the user will use SendAndWait to wait for the response. In asynchronous mode, the user will assign a handler function to ReceiveData event handler. Then responses and unsolicited messages will be sent to the users receive data handler.
Arguments:
Hostname (string) - DNS Name of the connection. Can be IP Address
IPPort (int) - IP port number of the connection
(optional) Protocol (string) - Value for either 'TCP', 'UDP', or 'SSH'
(optional) ServicePort (int) - Sets the port on which to listen for response data, UDP only, zero means listen on port OS assigns
(optional) Credentials (tuple) - Username and password for SSH connection.
- Hostname (string) - DNS Name of the connection. Can be IP Address
- IPPort (int) - IP port number of the connection
- (optional) Protocol (string) - Value for either 'TCP', 'UDP', or 'SSH'
- (optional) ServicePort (int) - Sets the port on which to listen for response data, UDP only, zero means listen on port OS assigns
- (optional) Credentials (tuple) - Username and password for SSH connection.
Parameters:
Credentials - Returns (tuple, bool) - Username and password for SSH connection.
>Note:
> returns tuple: ('username', 'password') if provided otherwise None.
> only applies when protocol 'SSH' is used.
Hostname - Returns (string) - server Host name
IPAddress - Returns (string) - server IP Address
IPPort - Returns (int) - IP port number of the connection
Protocol - Returns (string) - Value for either TCP, UDP, 'SSH' connection.
ServicePort - Returns (int) - the port on which the socket is listening for response data
- Credentials - Returns (tuple, bool) - Username and password for SSH connection.
- Note:
- returns tuple: ('username', 'password') if provided otherwise None.
- only applies when protocol 'SSH' is used.
- Hostname - Returns (string) - server Host name
- IPAddress - Returns (string) - server IP Address
- IPPort - Returns (int) - IP port number of the connection
- Protocol - Returns (string) - Value for either TCP, UDP, 'SSH' connection.
- ServicePort - Returns (int) - the port on which the socket is listening for response data
Events:
Connected - (Event) Triggers when socket connection is established.
Disconnected - (Event) Triggers when the socket connection is broken
ReceiveData - (Event) Receive Data event handler used for asynchronous transactions. The callback takes two arguments. The first one is the EthernetClientInterface instance triggering the event and the second one is a bytes string.
>Note:
> The maximum amount of data per ReceiveData event that will be passed into the handler is 1024 bytes. For payloads greater than 1024 bytes, multiple events will be triggered.
> When UDP protocol is used, the data will be truncated to 1024 bytes.
- Connected - (Event) Triggers when socket connection is established.
- Disconnected - (Event) Triggers when the socket connection is broken
- ReceiveData - (Event) Receive Data event handler used for asynchronous transactions. The callback takes two arguments. The first one is the EthernetClientInterface instance triggering the event and the second one is a bytes string.
- Note:
- The maximum amount of data per ReceiveData event that will be passed into the handler is 1024 bytes. For payloads greater than 1024 bytes, multiple events will be triggered.
- When UDP protocol is used, the data will be truncated to 1024 bytes.
"""
Hostname = ''
IPAddress = ''

View File

@ -3,26 +3,32 @@ class EthernetServerInterface():
:Warning:: This class is no longer supported. For any new development, EthernetServerInterfaceEx should be used.
---
Arguments:
IPPort (int) - IP port number of the listening service.
(optional) Protocol (string) - Value for either 'TCP' or 'UDP'
(optional) Interface (string) - Defines the network interface on which to listen ('Any', 'LAN' of 'AVLAN')
(optional) ServicePort (int) - sets the port from which the client will send data. Zero means any service port is valid.
- IPPort (int) - IP port number of the listening service.
- (optional) Protocol (string) - Value for either 'TCP' or 'UDP'
- (optional) Interface (string) - Defines the network interface on which to listen ('Any', 'LAN' of 'AVLAN')
- (optional) ServicePort (int) - sets the port from which the client will send data. Zero means any service port is valid.
Note: ServicePort is only applicable to 'UDP' protocol type.
---
Parameters:
Hostname - Returns (string) - Hostname DNS name of the connection. Can be the IP Address
IPAddress - Returns (string) - the IP Address of the connected device
IPPort - Returns (int) - IP Port number of the listening service
Interface - Returns (string) - name of interface on which the server is listening
Protocol - Returns (string) - Value for either TCP, UDP connection.
ServicePort - Returns (int) - ServicePort port on which the client will listen for data
- Hostname - Returns (string) - Hostname DNS name of the connection. Can be the IP Address
- IPAddress - Returns (string) - the IP Address of the connected device
- IPPort - Returns (int) - IP Port number of the listening service
- Interface - Returns (string) - name of interface on which the server is listening
- Protocol - Returns (string) - Value for either TCP, UDP connection.
- ServicePort - Returns (int) - ServicePort port on which the client will listen for data
---
Events:
Connected - (Event) Triggers when socket connection is established.
Disconnected - (Event) Triggers when the socket connection is broken
ReceiveData - (Event) Receive Data event handler used for asynchronous transactions. The callback takes two arguments. The first one is the EthernetServerInterface instance triggering the event and the second one is a bytes string.
- Connected - (Event) Triggers when socket connection is established.
- Disconnected - (Event) Triggers when the socket connection is broken
- ReceiveData - (Event) Receive Data event handler used for asynchronous transactions. The callback takes two arguments. The first one is the EthernetServerInterface instance triggering the event and the second one is a bytes string.
"""
IPPort = 0

View File

@ -1,23 +1,29 @@
class EthernetServerInterfaceEx():
""" This class provides an interface to an Ethernet server that allows a user-defined amount of client connections. After instantiation, the server is started by calling StartListen(). This class allows the user to send data over the Ethernet port in an asynchronous manner using Send() and ReceiveData after a client has connected.
---
Arguments:
IPPort (int) - IP port number of the listening service.
(optional) Protocol (string) - Value for either 'TCP' or 'UDP'
(optional) Interface (string) - Defines the network interface on which to listen ('Any', 'LAN' of 'AVLAN')
(optional) MaxClients (int) - maximum number of client connections to allow (None == Unlimited, 0 == Invalid)
- IPPort (int) - IP port number of the listening service.
- (optional) Protocol (string) - Value for either 'TCP' or 'UDP'
- (optional) Interface (string) - Defines the network interface on which to listen ('Any', 'LAN' of 'AVLAN')
- (optional) MaxClients (int) - maximum number of client connections to allow (None == Unlimited, 0 == Invalid)
---
Parameters:
Clients - Returns (list of ClientObject) - List of connected clients.
IPPort - Returns (int) - IP Port number of the listening service
Interface - Returns (string) - name of interface on which the server is listening ('Any', 'LAN' of 'AVLAN')
MaxClients - Returns (int or None) - maximum number of client connections to allow (None == Unlimited, 0 == Invalid)
Protocol - Returns (string) - socket protocol ('TCP', 'UDP')
- Clients - Returns (list of ClientObject) - List of connected clients.
- IPPort - Returns (int) - IP Port number of the listening service
- Interface - Returns (string) - name of interface on which the server is listening ('Any', 'LAN' of 'AVLAN')
- MaxClients - Returns (int or None) - maximum number of client connections to allow (None == Unlimited, 0 == Invalid)
- Protocol - Returns (string) - socket protocol ('TCP', 'UDP')
---
Events:
Connected - (Event) Triggers when socket connection is established. The callback takes two arguments. The first one is the ClientObject instance triggering the event and the second one is a string ('Connected').
Disconnected - (Event) Triggers when the socket connection is broken. The callback takes two arguments. The first one is the ClientObject instance triggering the event and the second one is a string ('Disconnected').
ReceiveData - (Event) Receive Data event handler used for asynchronous transactions. The callback takes two arguments. The first one is the ClientObject instance triggering the event and the second one is a bytes string.
- Connected - (Event) Triggers when socket connection is established. The callback takes two arguments. The first one is the ClientObject instance triggering the event and the second one is a string ('Connected').
- Disconnected - (Event) Triggers when the socket connection is broken. The callback takes two arguments. The first one is the ClientObject instance triggering the event and the second one is a string ('Disconnected').
- ReceiveData - (Event) Receive Data event handler used for asynchronous transactions. The callback takes two arguments. The first one is the ClientObject instance triggering the event and the second one is a bytes string.
"""
IPPort = 0

View File

@ -1,33 +1,35 @@
class FlexIOInterface():
""" This class will provide a common interface for controlling and collecting data from Flex IO ports on Extron devices (extronlib.device). The user can instantiate the class directly or create a subclass to add, remove, or alter behavior for different types of devices.
---
Arguments:
Host (extronlib.device) - handle to Extron device class that instantiated this interface class
Port (string) - port name (e.g. 'FIO1')
(optional) Mode (string) - Possible modes are: 'AnalogInput', 'DigitalInput' (default), and 'DigitalOutput'.
(optional) Pullup (bool) - pull-up state on the port
(optional) Upper (float) - upper threshold in volts
(optional) Lower (float) - lower threshold in volts
- Host (extronlib.device) - handle to Extron device class that instantiated this interface class
- Port (string) - port name (e.g. 'FIO1')
- (optional) Mode (string) - Possible modes are: 'AnalogInput', 'DigitalInput' (default), and 'DigitalOutput'.
- (optional) Pullup (bool) - pull-up state on the port
- (optional) Upper (float) - upper threshold in volts
- (optional) Lower (float) - lower threshold in volts
---
Parameters:
AnalogVoltage - Returns (float) - current voltage of analog input port
Host - Returns (extronlib.device) - handle to Extron device class that instantiated this interface class
Lower - Returns (float) - lower threshold for digital input in volts
>Note: Only applicable when Flex IO is in 'DigitalInput' mode.
Mode - Returns (string) - mode of the Flex IO port ('AnalogInput', 'DigitalInput', 'DigitalOutput').
Port - Returns (string) - port name
Pullup - Returns (bool) - indicates if the input port is being pulled up or not
State - Returns (string) - current state of IO port ('On', 'Off')
Upper - Returns (float) - upper threshold for digital input in volts
>Note: Only applicable when Flex IO is in 'DigitalInput' mode.
- AnalogVoltage - Returns (float) - current voltage of analog input port
- Host - Returns (extronlib.device) - handle to Extron device class that instantiated this interface class
- Lower - Returns (float) - lower threshold for digital input in volts > Note: Only applicable when Flex IO is in 'DigitalInput' mode.
- Mode - Returns (string) - mode of the Flex IO port ('AnalogInput', 'DigitalInput', 'DigitalOutput').
- Port - Returns (string) - port name
- Pullup - Returns (bool) - indicates if the input port is being pulled up or not
- State - Returns (string) - current state of IO port ('On', 'Off')
- Upper - Returns (float) - upper threshold for digital input in volts > Note: Only applicable when Flex IO is in 'DigitalInput' mode.
---
Events:
AnalogVoltageChanged - (Event) triggers when the input voltage changes. The callback takes two arguments. The first one is the extronlib.interface.FlexIOInterface instance triggering the event and the second one is the voltage.
>Note: Minimum voltage change required to trigger event is 0.05V.
Offline - (Event) Triggers when port goes offline. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('Offline').
Online - (Event) Triggers when port goes offline. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('Online').
StateChanged - (Event) Triggers when the input state changes. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('On' or 'Off').
>Note: Only triggers for ports in Input mode.
- AnalogVoltageChanged - (Event) triggers when the input voltage changes. The callback takes two arguments. The first one is the extronlib.interface.FlexIOInterface instance triggering the event and the second one is the voltage. > Note: Minimum voltage change required to trigger event is 0.05V.
- Offline - (Event) Triggers when port goes offline. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('Offline').
- Online - (Event) Triggers when port goes offline. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('Online').
- StateChanged - (Event) Triggers when the input state changes. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('On' or 'Off'). > Note: Only triggers for ports in Input mode.
"""
Host = None

View File

@ -2,20 +2,26 @@ class IRInterface():
""" This class provides an interface to an IR port. This class allows the user to transmit IR data through an IR or IR/Serial port.
Note: If an IR/Serial port is passed in and it has already been instantiated as an SerialInterface, an exception will be raised.
---
Arguments:
Host (extronlib.device) - handle to Extron device class that instantiated this interface class
Port (string) - port name (e.g., 'IRS1')
File (string) - IR file name (e.g. 'someDevice.eir')
- Host (extronlib.device) - handle to Extron device class that instantiated this interface class
- Port (string) - port name (e.g., 'IRS1')
- File (string) - IR file name (e.g. 'someDevice.eir')
---
Parameters:
File - Returns (string) - file name
Host - Returns (extronlib.device) - handle to Extron device class that instantiated this interface class
Port - Returns (string) - port name
- File - Returns (string) - file name
- Host - Returns (extronlib.device) - handle to Extron device class that instantiated this interface class
- Port - Returns (string) - port name
---
Events:
Offline - (Event) Triggers when port goes offline. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('Offline').
Online - (Event) Triggers when port goes offline. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('Online').
- Offline - (Event) Triggers when port goes offline. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('Offline').
- Online - (Event) Triggers when port goes offline. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('Online').
"""
Host = None

View File

@ -1,21 +1,27 @@
class PoEInterface():
""" This is the interface class for the Power over Ethernet ports on Extron devices (extronlib.device). The user can instantiate the class directly or create a subclass to add, remove, or alter behavior for different types of devices.
---
Arguments:
Host (extronlib.device) - handle to Extron device class that instantiated this interface class
Port (string) - port name (e.g., 'POE1')
- Host (extronlib.device) - handle to Extron device class that instantiated this interface class
- Port (string) - port name (e.g., 'POE1')
---
Parameters:
CurrentLoad - Returns (float) - the current load of PoE port in watts
Host - Returns (extronlib.device) - handle to Extron device class that instantiated this interface class
Port - Returns (string) - port name
PowerStatus - Returns (string) - State of power transmission on the port ('Active', 'Inactive'). 'Active' if there is a device being powered by the port.
State - Returns (string) - current state of IO port ('On', 'Off')
- CurrentLoad - Returns (float) - the current load of PoE port in watts
- Host - Returns (extronlib.device) - handle to Extron device class that instantiated this interface class
- Port - Returns (string) - port name
- PowerStatus - Returns (string) - State of power transmission on the port ('Active', 'Inactive'). 'Active' if there is a device being powered by the port.
- State - Returns (string) - current state of IO port ('On', 'Off')
---
Events:
Offline - (Event) Triggers when port goes offline. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('Offline').
Online - (Event) Triggers when port goes offline. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('Online').
PowerStatusChanged - (Event) Triggers when the state of power transmission on the port changes (e.g. a PoE device is plugged into the port). The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('Active' or 'Inactive').
- Offline - (Event) Triggers when port goes offline. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('Offline').
- Online - (Event) Triggers when port goes offline. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('Online').
- PowerStatusChanged - (Event) Triggers when the state of power transmission on the port changes (e.g. a PoE device is plugged into the port). The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('Active' or 'Inactive').
"""
Host = None
@ -46,6 +52,5 @@ class PoEInterface():
pass
def Toggle(self, State):
""" Changes the state to the logical opposite of the current state.
"""
""" Changes the state to the logical opposite of the current state. """
pass

View File

@ -1,18 +1,24 @@
class RelayInterface():
""" This class provides a common interface for controlling relays on Extron devices (extronlib.device). The user can instantiate the class directly or create a subclass to add, remove, or alter behavior for different types of devices.
---
Arguments:
Host (extronlib.device) - handle to Extron device class that instantiated this interface class
Port (string) - port name (e.g. 'RLY1')
- Host (extronlib.device) - handle to Extron device class that instantiated this interface class
- Port (string) - port name (e.g. 'RLY1')
---
Parameters:
Host - Returns (extronlib.device) - handle to Extron device class that instantiated this interface class
Port - Returns (string) - port name
State - Returns (string) - current state of Relay port ('Close', 'Open')
- Host - Returns (extronlib.device) - handle to Extron device class that instantiated this interface class
- Port - Returns (string) - port name
- State - Returns (string) - current state of Relay port ('Close', 'Open')
---
Events:
Offline - (Event) Triggers when port goes offline. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('Offline').
Online - (Event) Triggers when port goes offline. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('Online').
- Offline - (Event) Triggers when port goes offline. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('Offline').
- Online - (Event) Triggers when port goes offline. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('Online').
"""
Host = None
Port = ''

View File

@ -1,20 +1,26 @@
class SWACReceptacleInterface():
""" This class provides a common interface to a switched AC power receptacle on an Extron product (extronlib.device). The user can instantiate the class directly or create a subclass to add, remove, or alter behavior for different types of devices.
---
Arguments:
Host (extronlib.device) - handle to Extron device class that instantiated this interface class
Port (string) - port name (e.g. 'SAC1')
- Host (extronlib.device) - handle to Extron device class that instantiated this interface class
- Port (string) - port name (e.g. 'SAC1')
---
Parameters:
CurrentChanged - Returns (float) - instantaneous current draw in Amperes
Host - Returns (extronlib.device) - handle to Extron device class that instantiated this interface class
Port - Returns (string) - port name
State - Returns (string) - current state of receptacle ('On', 'Off')
- CurrentChanged - Returns (float) - instantaneous current draw in Amperes
- Host - Returns (extronlib.device) - handle to Extron device class that instantiated this interface class
- Port - Returns (string) - port name
- State - Returns (string) - current state of receptacle ('On', 'Off')
---
Events:
CurrentChanged - (Event) triggers when the current draw changes. The callback takes two arguments. The first one is the SWACReceptacleInterface instance triggering the event, and the second is the current.
Offline - (Event) Triggers when port goes offline. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('Offline').
Online - (Event) Triggers when port goes offline. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('Online').
- CurrentChanged - (Event) triggers when the current draw changes. The callback takes two arguments. The first one is the SWACReceptacleInterface instance triggering the event, and the second is the current.
- Offline - (Event) Triggers when port goes offline. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('Offline').
- Online - (Event) Triggers when port goes offline. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('Online').
"""
Current = 0.0

View File

@ -1,18 +1,24 @@
class SWPowerInterface():
""" This is the interface class for the Switched Power ports on Extron devices (extronlib.device). The user can instantiate the class directly or create a subclass to add, remove, or alter behavior for different types of devices.
---
Arguments:
Host (extronlib.device) - handle to Extron device class that instantiated this interface class
Port (string) - port name (e.g. 'SPI1')
- Host (extronlib.device) - handle to Extron device class that instantiated this interface class
- Port (string) - port name (e.g. 'SPI1')
---
Parameters:
Host - Returns (extronlib.device) - handle to Extron device class that instantiated this interface class
Port - Returns (string) - port name
State - Returns (string) - current state of IO port ('On', 'Off')
- Host - Returns (extronlib.device) - handle to Extron device class that instantiated this interface class
- Port - Returns (string) - port name
- State - Returns (string) - current state of IO port ('On', 'Off')
---
Events:
Offline - (Event) Triggers when port goes offline. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('Offline').
Online - (Event) Triggers when port goes offline. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('Online').
- Offline - (Event) Triggers when port goes offline. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('Offline').
- Online - (Event) Triggers when port goes offline. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('Online').
"""
Host = None

View File

@ -1,37 +1,43 @@
class SerialInterface():
""" This class provides an interface to a serial port. This class allows the user to send data over the serial port in a synchronous or asynchronous manner. This class is used for all ports capable of serial communication (e.g., Serial Ports, IR Serial Ports).
>Note:
> In synchronous mode, the user will use SendAndWait() to wait for the response.
> In asynchronous mode, the user will assign a handler function to ReceiveData to handle responses.
> If an IR/Serial port is passed in and it has already been instantiated as an IRInterface, an exception will be raised.
Note:
- In synchronous mode, the user will use SendAndWait() to wait for the response.
- In asynchronous mode, the user will assign a handler function to ReceiveData to handle responses.
- If an IR/Serial port is passed in and it has already been instantiated as an IRInterface, an exception will be raised.
---
Arguments:
Host (extronlib.device) - handle to Extron device class that instantiated this interface class
Port (string) - port name (e.g. 'COM1', 'IRS1')
(optional) Baud (int) - baudrate
(optional) Data (int) - number of data bits
(optional) Parity (string) - 'None', 'Odd' or 'Even'
(optional) Stop (int) - number of stop bits
(optional) FlowControl (string) - 'HW', 'SW', or 'Off'
(optional) CharDelay (float) - time between each character sent to the connected device
(optional) Mode (string) - mode of the port, 'RS232', 'RS422' or 'RS485'
- Host (extronlib.device) - handle to Extron device class that instantiated this interface class
- Port (string) - port name (e.g. 'COM1', 'IRS1')
- (optional) Baud (int) - baudrate
- (optional) Data (int) - number of data bits
- (optional) Parity (string) - 'None', 'Odd' or 'Even'
- (optional) Stop (int) - number of stop bits
- (optional) FlowControl (string) - 'HW', 'SW', or 'Off'
- (optional) CharDelay (float) - time between each character sent to the connected device
- (optional) Mode (string) - mode of the port, 'RS232', 'RS422' or 'RS485'
---
Parameters:
Baud - Returns (int) - the baud rate
CharDelay - Returns (float) - inter-character delay
Data - Returns (int) - the number of data bits
FlowControl - Returns (string) - flow control
Host - Returns (extronlib.device) - the host device
Mode - Returns (string) - the current Mode
Parity - Returns (string) - parity
Port - Returns (string) - the port name this interface is attached to
Stop - Returns (int) - number of stop bits
- Baud - Returns (int) - the baud rate
- CharDelay - Returns (float) - inter-character delay
- Data - Returns (int) - the number of data bits
- FlowControl - Returns (string) - flow control
- Host - Returns (extronlib.device) - the host device
- Mode - Returns (string) - the current Mode
- Parity - Returns (string) - parity
- Port - Returns (string) - the port name this interface is attached to
- Stop - Returns (int) - number of stop bits
---
Events:
Offline - (Event) Triggers when port goes offline. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('Offline').
Online - (Event) Triggers when port goes offline. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('Online').
ReceiveData - (Event) Receive Data event handler used for asynchronous transactions. The callback takes two arguments. The first one is the SerialInterface instance triggering the event and the second one is a bytes string.
- Offline - (Event) Triggers when port goes offline. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('Offline').
- Online - (Event) Triggers when port goes offline. The callback takes two arguments. The first one is the extronlib.interface instance triggering the event and the second one is a string ('Online').
- ReceiveData - (Event) Receive Data event handler used for asynchronous transactions. The callback takes two arguments. The first one is the SerialInterface instance triggering the event and the second one is a bytes string.
"""
Host = None
Port = ''

View File

@ -1,17 +1,22 @@
class VolumeInterface():
""" This class will provide a common interface for controlling and collecting data from Volume Ports on Extron devices (extronlib.device). The user can instantiate the class directly or create a subclass to add, remove, or alter behavior for different types of devices.
Arguments:
Host (extronlib.device) - handle to Extron device class that instantiated this interface class
Port (string) - port name (e.g. 'VOL1')
---
Host - Returns (extronlib.device) - the host device
Level - Returns (int) - Current volume level (percentage).
Max - Returns (float) - Maximum level (0.0 V < Max <= 10.0 V).
Min - Returns (float) - Minimum level (0.0 V <= Min < 10.0 V).
Mute - Returns (string) - Current state of volume port mute. ('On', 'Off')
Port - Returns (string) - the port name this interface is attached to
SoftStart - Returns (string) - Current state of Soft Start. ('Enabled', 'Disabled')
Arguments:
- Host (extronlib.device) - handle to Extron device class that instantiated this interface class
- Port (string) - port name (e.g. 'VOL1')
---
Parameters:
- Host - Returns (extronlib.device) - the host device
- Level - Returns (int) - Current volume level (percentage).
- Max - Returns (float) - Maximum level (0.0 V < Max <= 10.0 V).
- Min - Returns (float) - Minimum level (0.0 V <= Min < 10.0 V).
- Mute - Returns (string) - Current state of volume port mute. ('On', 'Off')
- Port - Returns (string) - the port name this interface is attached to
- SoftStart - Returns (string) - Current state of Soft Start. ('Enabled', 'Disabled')
"""
Host = None
Port = ''

View File

@ -7,18 +7,24 @@ class SummitConnect():
Note:
- System limits 15 SummitConnect clients per system.
---
Arguments:
- Hostname (string) - Hostname of the host computer. Can be IP Address.
- IPPort (int) - IP Port the software is listening on (default is 5000)
Note:
- Only one object can be instantiated for a given Hostname or IP Address.
---
Parameters:
- Hostname - Returns (string) - Hostname of the host computer `Note: If unavailable, returns the IP Address.`
- IPAddress - Returns (string) - IP Address of the host computer
- IPPort - Returns (int) - IP Port the software is listening on (default is 5000)
- ListeningPort - Returns (int) - IP Port this SummitConnect instance is listening on for received data
---
Events:
- Connected (Event) Triggers when communication is established. The callback takes two arguments. The first one is the SummitConnect instance triggering the event and the second one is a string ('Connected').

View File

@ -7,11 +7,15 @@ class Clock():
Note:
- When DST causes the clock to spring forward one hour, events scheduled within the skipped hour do not fire.
- When DST causes the clock to fall back an hour, events scheduled within the repeated hour fire twice.
---
Arguments:
- Times (list of strings) - list of times (e.g. 'HH:MM:SS') of day to call Function
- Days (list of strings) - list of weekdays to set alarm. If Days is omitted, the alarm is set for every weekday
- Function (function) - function to execute when alarm time is up
---
Parameters:
- Days - Returns (list of strings) - list of days to execute

View File

@ -6,6 +6,8 @@ class Email():
Note: default sender will be login username@unit-name or hostname@unit-name if there is no authentication. To override, call Sender()
---
Arguments:
- smtpServer (string) - ip address or hostname of SMTP server
- port (int) - port number

View File

@ -5,6 +5,8 @@ class File():
""" Access to files located in user area. These files are stored in a location that can be accessed using 3rd party SFTP clients.
Note: File class accesses user area with admin privileges.
---
Arguments:
- Filename (string) - Name of file to open
@ -17,6 +19,8 @@ class File():
- ChangeDir(), DeleteDir(), DeleteFile(), Exists(), GetCurrentDir(), ListDir(), MakeDir(), and RenameFile() are all classmethods.
Note: For restricted file access, substitute File with RFile in the examples above and below.
---
Parameters:
- Filename - Returns (string) - name of file

View File

@ -4,6 +4,8 @@ from typing import Union
class MESet():
""" The Mutually Exclusive set allows for the grouping of objects to allow easy selection of related items. For instance, a group of buttons could be grouped so that selecting one button deselects the others in the group.
---
Compatible extronlib classes:
- IOInterface (and any children):
- extronlib.interface.RelayInterface
@ -11,15 +13,19 @@ class MESet():
- extronlib.interface.DigitalIOInterface (Output only)
- extronlib.interface.SWPowerInterface
- Button:
---
Arguments:
- Objects (list) - list of compatible objects
Note:
- Each object must have a method SetState.
- SetState must take an integer argument.
- Any object with a SetState function that takes an integer object is compatible with this class.
- A programmer can create their own class and use it with MESet.
---
Parameters:
- Objects - Returns (list) - the list of objects to track

View File

@ -4,6 +4,8 @@ from typing import Union
class RFile():
""" Access to restricted files. These files can only be created and accessed within the program. Files can be uploaded to provide initial values via the Global Scripter® project.
---
Arguments:
- Filename (string) - Name of file to open
- mode (string) - the mode in which the files is opened.
@ -15,6 +17,8 @@ class RFile():
- ChangeDir(), DeleteDir(), DeleteFile(), Exists(), GetCurrentDir(), ListDir(), MakeDir(), and RenameFile() are all classmethods.
Note: For restricted file access, substitute File with RFile in the examples above and below.
---
Parameters:
- Filename - Returns (string) - name of file

View File

@ -7,15 +7,21 @@ class Timer():
In addition to being used as a decorator, Timer can be named and modified.
---
Arguments:
- Interval (float) - How often to call the handler in seconds (minimum interval is 0.1s).
- Function (function) - Handler function to execute each Interval.
---
Parameters:
- Count - Returns (int) - Number of events triggered by this timer.
- Function - Returns (function) - Handler function to execute each Interval. Function must accept exactly two parameters, which are the Timer that called it and the Count.
- Interval - Returns (float) - How often to call the handler in seconds.
- State - Returns (string) - Current state of Timer ('Running', 'Paused', 'Stopped')
---
Events:
- StateChanged - (Event) Triggers when the timer state changes. The callback takes two arguments. The first is the Timer instance triggering the event and the second is a string ('Running', 'Paused', 'Stopped').

View File

@ -2,10 +2,14 @@ class Wait():
""" The wait class allows the user to execute programmed actions after a desired delay without blocking other processor activity.
In addition to being used as a one-shot (decorator), Wait can be named and reusable.
---
Arguments:
- Time (float) - Expiration time of the wait in seconds
- Function (function) - Code to execute when Time expires
---
Parameters:
- Function - Returns (function) - Code to execute when Time expires.

View File

@ -7,32 +7,36 @@ class Button():
A button may trigger several events depending on the configuration; however, Touch Panels only issue Pressed and Released messages to the controller. Other events (e.g., Held, Repeated) are timer driven within the Button instance.
---
Arguments:
UIHost (extronlib.device.UIDevice) - Device object hosting this UIObject
ID (int,string) - ID or Name of the UIObject
(optional) holdTime (float) - Time for Held event. Held event is triggered only once if the button is pressed and held beyond this time. If holdTime is given, it must be a floating point number specifying period of time in seconds of button being pressed and held to trigger Held event.
(optional) repeatTime (float) - Time for Repeated event. After holdTime expires, the Repeated event is triggered for every additional repeatTime of button being held. If repeatTime is given, it must be a floating point number specifying time in seconds of button being held.
- `UIHost` (extronlib.device.UIDevice) - Device object hosting this UIObject
- `ID` (int,string) - ID or Name of the UIObject
- (optional) `holdTime` (float) - Time for Held event. Held event is triggered only once if the button is pressed and held beyond this time. If holdTime is given, it must be a floating point number specifying period of time in seconds of button being pressed and held to trigger Held event.
- (optional) `repeatTime` (float) - Time for Repeated event. After holdTime expires, the Repeated event is triggered for every additional repeatTime of button being held. If repeatTime is given, it must be a floating point number specifying time in seconds of button being held.
Note: If button is released before holdTime expires, a Tapped event is triggered instead of a Released event. If the button is released after holdTime expires, there will be no Tapped event.
---
Parameters:
BlinkState - Returns (string) - the current blink state ('Not blinking' or 'Blinking')
Enabled - Returns (bool) - True if the control object is enabled else False
Host - Returns (extronlib.device.UIDevice) - UIDevice object that hosts this control object
ID - Returns (int) - the object ID
Name - Returns (string) - the object Name
PressedState - Returns (bool) - True if the button is pressed, else False
State - Returns (int) - the current visual state number
> Note: It does not return the current state if the button is blinking.
Visible - Returns (bool) - True if the control object is visible else False
- `BlinkState` - Returns (string) - the current blink state ('Not blinking' or 'Blinking')
- `Enabled` - Returns (bool) - True if the control object is enabled else False
- `Host` - Returns (extronlib.device.UIDevice) - UIDevice object that hosts this control object
- `ID` - Returns (int) - the object ID
- `Name` - Returns (string) - the object Name
- `PressedState` - Returns (bool) - True if the button is pressed, else False
- `State` - Returns (int) - the current visual state number > Note: It does not return the current state if the button is blinking.
- `Visible` - Returns (bool) - True if the control object is visible else False
---
Events:
Held - (Event) Get/Set the callback when hold expire event is triggered. The callback function must accept exactly two parameters, which are the Button that triggers the event and the state (e.g. Held).
Pressed - (Event) Get/Set the callback when the button is pressed. The callback function must accept exactly two parameters, which are the Button that triggers the event and the state (e.g. Pressed).
Released - (Event) Get/Set the callback when the button is released. The callback function must accept exactly two parameters, which are the Button that triggers the event and the state (e.g. Held).
Repeated - (Event) Get/Set the callback when repeat event is triggered. The callback function must accept exactly two parameters, which are the Button that triggers the event and the state (e.g. Repeated).
Tapped - (Event) Get/Set the callback when tap event is triggered. The callback function must accept exactly two parameters, which are the Button that triggers the event and the state (e.g. Tapped).
- `Held` - (Event) Get/Set the callback when hold expire event is triggered. The callback function must accept exactly two parameters, which are the Button that triggers the event and the state (e.g. Held).
- `Pressed` - (Event) Get/Set the callback when the button is pressed. The callback function must accept exactly two parameters, which are the Button that triggers the event and the state (e.g. Pressed).
- `Released` - (Event) Get/Set the callback when the button is released. The callback function must accept exactly two parameters, which are the Button that triggers the event and the state (e.g. Held).
- `Repeated` - (Event) Get/Set the callback when repeat event is triggered. The callback function must accept exactly two parameters, which are the Button that triggers the event and the state (e.g. Repeated).
- `Tapped` - (Event) Get/Set the callback when tap event is triggered. The callback function must accept exactly two parameters, which are the Button that triggers the event and the state (e.g. Tapped).
"""
UIHost = None
ID = 0

View File

@ -1,14 +1,20 @@
class Knob():
""" Knob is a rotary control that has 36 steps for a full revolution
---
Arguments:
- UIHost (extronlib.device.UIDevice) - Device object hosting this UIObject
- ID (int) - ID of the UIObject
---
Parameters:
- Host - Returns (extronlib.device.UIDevice) - UIDevice object that hosts this control object
- ID - Returns (int) - the object ID
---
Events:
- Turned - (Event) Get/Set callback when knob is turned. The callback takes two parameters. The first one is the Knob itself and the second one is a signed integer indicating steps that was turned. Positive values indicate clockwise rotation.
"""

View File

@ -3,11 +3,15 @@ import device
class Label():
""" Label object displays text string on the screen
---
Arguments:
- UIHost (extronlib.device.UIDevice) - Device object hosting this UIObject
- ID (int,string) - ID or Name of the UIObject
---
Parameters:
- Host - Returns (extronlib.device.UIDevice) - UIDevice object that hosts this control object
- ID - Returns (int) - the object ID

View File

@ -5,9 +5,13 @@ import device
class Level():
""" This module defines interfaces of Level UI.
---
Arguments:
- UIHost (extronlib.device.UIDevice) - Device object hosting this UIObject
- ID (int) - ID of the UIObject
---
Parameters:
- Host - Returns (extronlib.device.UIDevice) - UIDevice object that hosts this control object