UsbPort class
UsbPort handles the communication with the USB Serial port.
Properties
- baudRate → int
-
no setter
- dataBits → int
-
no setter
- hashCode → int
-
The hash code for this object.
no setteroverride
-
inputStream
→ Stream<
Uint8List> ? -
returns the asynchronous input stream.
no setter
- parity → int
-
no setter
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- stopBits → int
-
no setter
Methods
-
close(
) → Future< bool> - Closes the com port.
-
dataBitToString(
) → String - return string name of databits
-
flowControlToString(
) → String - return string name of flowcontrol
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
open(
) → Future< bool> - Opens the uart communication channel.
-
parityToString(
) → String - return string name of parity
-
setDTR(
bool dtr) → Future< void> -
Sets or clears the DTR port to value
dtr
. -
setFlowControl(
int flowControl) → Future< void> - Sets the flow control parameter.
-
setPortParameters(
int baudRate, int dataBits, int stopBits, int parity) → Future< void> - Sets the port parameters to the requested values.
-
setRTS(
bool rts) → Future< void> -
Sets or clears the RTS port to value
rts
. -
stopBitsToString(
) → String - return string name of stop bits
-
toString(
) → String -
A string representation of this object.
override
-
write(
Uint8List data) → Future< void> -
Asynchronously writes
data
.
Operators
-
operator ==(
Object other) → bool -
The equality operator.
override
Constants
- DATABITS_5 → const int
- Constant to configure port with 5 databits.
- DATABITS_6 → const int
- Constant to configure port with 6 databits.
- DATABITS_7 → const int
- Constant to configure port with 7 databits.
- DATABITS_8 → const int
- Constant to configure port with 8 databits.
- FLOW_CONTROL_DSR_DTR → const int
- Constant to configure port with flow contorl DSR / DTR
- FLOW_CONTROL_OFF → const int
- Constant to configure port with no flow control
- FLOW_CONTROL_RTS_CTS → const int
- Constant to configure port with flow control RTS/CTS
- FLOW_CONTROL_XON_XOFF → const int
- Constant to configure port with flow control XON XOFF
- PARITY_EVEN → const int
- Constant to configure port with event parity.
- PARITY_MARK → const int
- Constant to configure port with mark parity.
- PARITY_NONE → const int
- Constant to configure port with parity none
- PARITY_ODD → const int
- Constant to configure port with odd parity.
- PARITY_SPACE → const int
- Constant to configure port with space parity.
- STOPBITS_1 → const int
- Constant to configure port with 1 stop bits
- STOPBITS_1_5 → const int
- Constant to configure port with 1.5 stop bits
- STOPBITS_2 → const int
- Constant to configure port with 2 stop bits