Click or drag to resize

SerialReceive Method

Receive at least one text character from the ASCOM serial port

Namespace:  ASCOM.Utilities
Assembly:  ASCOM.Utilities (in ASCOM.Utilities.dll) Version: 3c9121baba46811fe6e53a58a05935662261416d
Syntax
public string Receive()

Return Value

Type: String
The characters received
Exceptions
ExceptionCondition
TimeoutExceptionThrown when a receive timeout occurs.
SerialPortInUseExceptionThrown when unable to acquire the serial port
NotConnectedExceptionThrown when this command is used before setting Connect = True
Remarks
This method reads all of the characters currently in the serial receive buffer. It will not return unless it reads at least one character. A timeout will cause a TimeoutException to be raised. Use this for text data, as it returns a String.
See Also