Show / Hide Table of Contents

Class DeviceBase

Base class of any client device implementation.

It defines the common methods that every device has to implement

Inheritance
System.Object
DeviceBase
Camera
Dome
FilterWheel
Focuser
ObservingConditions
Rotator
SafetyMonitor
Switch
Telescope
Implements
IDevice
IDeviceAsync
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: ES.Ascom.Alpaca.Client.Devices
Assembly: ES.Ascom.Alpaca.Client.dll
Syntax
public abstract class DeviceBase : IDevice, IDeviceAsync

Constructors

| Improve this Doc View Source

DeviceBase(DeviceConfiguration)

Initializes a new device instance.

Declaration
protected DeviceBase(DeviceConfiguration configuration)
Parameters
Type Name Description
DeviceConfiguration configuration

Device configuration

| Improve this Doc View Source

DeviceBase(DeviceConfiguration, ILogger)

Initializes a new device instance.

Declaration
protected DeviceBase(DeviceConfiguration configuration, ILogger logger)
Parameters
Type Name Description
DeviceConfiguration configuration

Device configuration

ILogger logger

Logger, can be useful for debugging

| Improve this Doc View Source

DeviceBase(DeviceConfiguration, IClientTransactionIdGenerator)

Initializes a new device instance.

Declaration
protected DeviceBase(DeviceConfiguration configuration, IClientTransactionIdGenerator clientTransactionIdGenerator)
Parameters
Type Name Description
DeviceConfiguration configuration

Device configuration

IClientTransactionIdGenerator clientTransactionIdGenerator

Client Transaction ID Generator

| Improve this Doc View Source

DeviceBase(DeviceConfiguration, IClientTransactionIdGenerator, ILogger)

Initializes a new device instance.

Declaration
protected DeviceBase(DeviceConfiguration configuration, IClientTransactionIdGenerator clientTransactionIdGenerator, ILogger logger)
Parameters
Type Name Description
DeviceConfiguration configuration

Device configuration

IClientTransactionIdGenerator clientTransactionIdGenerator

Client Transaction ID Generator

ILogger logger

Logger, can be useful for debugging

| Improve this Doc View Source

DeviceBase(DeviceConfiguration, ICommandSender)

Initializes a new device instance.

Declaration
protected DeviceBase(DeviceConfiguration configuration, ICommandSender commandSender)
Parameters
Type Name Description
DeviceConfiguration configuration

Device configuration

ES.Ascom.Alpaca.Client.Request.ICommandSender commandSender

Command sender

| Improve this Doc View Source

DeviceBase(DeviceConfiguration, ICommandSender, IClientTransactionIdGenerator)

Initializes a new device instance.

Declaration
protected DeviceBase(DeviceConfiguration configuration, ICommandSender commandSender, IClientTransactionIdGenerator clientTransactionIdGenerator)
Parameters
Type Name Description
DeviceConfiguration configuration

Device configuration

ES.Ascom.Alpaca.Client.Request.ICommandSender commandSender

Command sender

IClientTransactionIdGenerator clientTransactionIdGenerator

Client Transaction ID Generator

Properties

| Improve this Doc View Source

DeviceNumber

Gets the device number

This number come from the DeviceConfiguration passed to the constructor

Declaration
public int DeviceNumber { get; }
Property Value
Type Description
System.Int32

Methods

| Improve this Doc View Source

GetDescription()

Declaration
public string GetDescription()
Returns
Type Description
System.String
| Improve this Doc View Source

GetDescriptionAsync()

Declaration
public Task<string> GetDescriptionAsync()
Returns
Type Description
System.Threading.Tasks.Task<System.String>
| Improve this Doc View Source

GetDriverInfo()

Declaration
public string GetDriverInfo()
Returns
Type Description
System.String
| Improve this Doc View Source

GetDriverInfoAsync()

Declaration
public Task<string> GetDriverInfoAsync()
Returns
Type Description
System.Threading.Tasks.Task<System.String>
| Improve this Doc View Source

GetDriverVersion()

Declaration
public string GetDriverVersion()
Returns
Type Description
System.String
| Improve this Doc View Source

GetDriverVersionAsync()

Declaration
public Task<string> GetDriverVersionAsync()
Returns
Type Description
System.Threading.Tasks.Task<System.String>
| Improve this Doc View Source

GetInterfaceVersion()

Declaration
public int GetInterfaceVersion()
Returns
Type Description
System.Int32
| Improve this Doc View Source

GetInterfaceVersionAsync()

Declaration
public Task<int> GetInterfaceVersionAsync()
Returns
Type Description
System.Threading.Tasks.Task<System.Int32>
| Improve this Doc View Source

GetName()

Declaration
public string GetName()
Returns
Type Description
System.String
| Improve this Doc View Source

GetNameAsync()

Declaration
public Task<string> GetNameAsync()
Returns
Type Description
System.Threading.Tasks.Task<System.String>
| Improve this Doc View Source

GetSupportedActions()

Declaration
public IList<string> GetSupportedActions()
Returns
Type Description
System.Collections.Generic.IList<System.String>
| Improve this Doc View Source

GetSupportedActionsAsync()

Declaration
public Task<IList<string>> GetSupportedActionsAsync()
Returns
Type Description
System.Threading.Tasks.Task<System.Collections.Generic.IList<System.String>>
| Improve this Doc View Source

InvokeAction(String, String)

Declaration
public string InvokeAction(string actionName, string actionParameters)
Parameters
Type Name Description
System.String actionName
System.String actionParameters
Returns
Type Description
System.String
| Improve this Doc View Source

InvokeActionAsync(String, String)

Declaration
public Task<string> InvokeActionAsync(string actionName, string actionParameters)
Parameters
Type Name Description
System.String actionName
System.String actionParameters
Returns
Type Description
System.Threading.Tasks.Task<System.String>
| Improve this Doc View Source

IsConnected()

Declaration
public bool IsConnected()
Returns
Type Description
System.Boolean
| Improve this Doc View Source

IsConnectedAsync()

Declaration
public Task<bool> IsConnectedAsync()
Returns
Type Description
System.Threading.Tasks.Task<System.Boolean>
| Improve this Doc View Source

SendCommandBlind(String, Boolean)

Declaration
public void SendCommandBlind(string command, bool raw = false)
Parameters
Type Name Description
System.String command
System.Boolean raw
| Improve this Doc View Source

SendCommandBlindAsync(String, Boolean)

Declaration
public Task SendCommandBlindAsync(string command, bool raw = false)
Parameters
Type Name Description
System.String command
System.Boolean raw
Returns
Type Description
System.Threading.Tasks.Task
| Improve this Doc View Source

SendCommandBool(String, Boolean)

Declaration
public bool SendCommandBool(string command, bool raw = false)
Parameters
Type Name Description
System.String command
System.Boolean raw
Returns
Type Description
System.Boolean
| Improve this Doc View Source

SendCommandBoolAsync(String, Boolean)

Declaration
public Task<bool> SendCommandBoolAsync(string command, bool raw = false)
Parameters
Type Name Description
System.String command
System.Boolean raw
Returns
Type Description
System.Threading.Tasks.Task<System.Boolean>
| Improve this Doc View Source

SendCommandString(String, Boolean)

Declaration
public string SendCommandString(string command, bool raw = false)
Parameters
Type Name Description
System.String command
System.Boolean raw
Returns
Type Description
System.String
| Improve this Doc View Source

SendCommandStringAsync(String, Boolean)

Declaration
public Task<string> SendCommandStringAsync(string command, bool raw = false)
Parameters
Type Name Description
System.String command
System.Boolean raw
Returns
Type Description
System.Threading.Tasks.Task<System.String>
| Improve this Doc View Source

SetConnected(Boolean)

Declaration
public void SetConnected(bool connected)
Parameters
Type Name Description
System.Boolean connected
| Improve this Doc View Source

SetConnectedAsync(Boolean)

Declaration
public Task SetConnectedAsync(bool connected)
Parameters
Type Name Description
System.Boolean connected
Returns
Type Description
System.Threading.Tasks.Task

Implements

IDevice
IDeviceAsync
  • Improve this Doc
  • View Source
Back to top Generated by DocFX