state = port:getState()
Returns the current state of the port as a constant from the asi table.
State |
Description |
---|---|
asi.DISCONNECTED |
Port is disconnected. |
asi.CONNECTING |
Port is connecting. |
asi.CONNECTED |
Port is connected. |
asi.DISCONNECTING |
Port is disconnecting. |
asi.INVALID |
Port is invalid or no longer present in the system. |
Introduced in platform.apiLevel = '2.7'.