AlpacaClientGetDeviceT(AscomDevice, Int32, Int32, Int32, UInt32, String, String, Boolean, ILogger, ImageArrayTransferType, ImageArrayCompression, String, String, Boolean, Boolean, Boolean) Method
Create an Alpaca client for a discovered ASCOM device specifying all parameters
Namespace: ASCOM.Alpaca.ClientsAssembly: ASCOM.Alpaca (in ASCOM.Alpaca.dll) Version: 3.0.0-rc.1+86c25ce733aebb4d8b1b8a62e84770ea5e972bea
public static T GetDevice<T>(
AscomDevice ascomDevice,
int establishConnectionTimeout = 5,
int standardDeviceResponseTimeout = 10,
int longDeviceResponseTimeout = 100,
uint clientNumber = 1,
string userName = "",
string password = "",
bool strictCasing = true,
ILogger logger = null,
ImageArrayTransferType imageArrayTransferType = ImageArrayTransferType.BestAvailable,
ImageArrayCompression imageArrayCompression = ImageArrayCompression.None,
string userAgentProductName = null,
string userAgentProductVersion = null,
bool trustUserGeneratedSslCertificates = false,
bool throwOnBadDateTimeJSON = false,
bool request100Continue = false
)
where T : new(), AlpacaDeviceBaseClass
Public Shared Function GetDevice(Of T As {New, AlpacaDeviceBaseClass}) (
ascomDevice As AscomDevice,
Optional establishConnectionTimeout As Integer = 5,
Optional standardDeviceResponseTimeout As Integer = 10,
Optional longDeviceResponseTimeout As Integer = 100,
Optional clientNumber As UInteger = 1,
Optional userName As String = "",
Optional password As String = "",
Optional strictCasing As Boolean = true,
Optional logger As ILogger = Nothing,
Optional imageArrayTransferType As ImageArrayTransferType = ImageArrayTransferType.BestAvailable,
Optional imageArrayCompression As ImageArrayCompression = ImageArrayCompression.None,
Optional userAgentProductName As String = Nothing,
Optional userAgentProductVersion As String = Nothing,
Optional trustUserGeneratedSslCertificates As Boolean = false,
Optional throwOnBadDateTimeJSON As Boolean = false,
Optional request100Continue As Boolean = false
) As T
- ascomDevice AscomDevice
- An AscomDevice instance representing the device to use (mandatory parameter)
- establishConnectionTimeout Int32 (Optional)
- Communications timeout (seconds) when initially connecting to the client. Default: 3 seconds
- standardDeviceResponseTimeout Int32 (Optional)
- Communications timeout (seconds) for commands that are expected to complete quickly. Default: 3 seconds
- longDeviceResponseTimeout Int32 (Optional)
- Communications timeout (seconds) for commands that are expected to take a long time such as synchronous telescope slews. Default: 100 seconds
- clientNumber UInt32 (Optional)
- Arbitrary number identifying this particular client. Default: 1
- userName String (Optional)
- Basic authentication user name. Supply a or empty string if basic authentication is not required. Default: Empty string
- password String (Optional)
- Basic authentication password. Ignored if password is or an empty string. Default: Empty string
- strictCasing Boolean (Optional)
- Set true to require strict JSON casing in device responses.. Default: true
- logger ILogger (Optional)
- ILogger instance or null. Default: null
- imageArrayTransferType ImageArrayTransferType (Optional)
- Image array transfer type (Only relevant to Camera devices). Default: ImageArrayTransferType.BestAvailable
- imageArrayCompression ImageArrayCompression (Optional)
- Image array compression type (Only relevant to Camera devices). Default: ImageArrayCompression.None
- userAgentProductName String (Optional)
- User agent header product name. Default: Not added to header.
- userAgentProductVersion String (Optional)
- User agent header product version. Default: Not added to header.
- trustUserGeneratedSslCertificates Boolean (Optional)
- Trust user generated SSL certificates. Default: User generated SSL certificates are not trusted.
- throwOnBadDateTimeJSON Boolean (Optional)
- Return an error if the UTCDate JSON format is incorrect (Only relevant to Telescope devices). Default: Will accept the provided format and not return an error.
- request100Continue Boolean (Optional)
- Request that PUT requests use the 100CONTINUE HTTP protocol. Default: The 100CONTINUE protocol is not requested.
- T
TAn Alpaca client instance for the supplied device and configuration
Supported in: 2.0