The official ASCOM .NET Templates available with the ASCOM Platform Developer Components use the Visual Studio template wizard. Therefore, it is required to use Visual Studio to benefit of the template. To use the template in an other IDE, the only way is to uncompress the template zip file provided by the ASCOM Platform Developer Components and manually edit the files, removing not required files, ...
This project, allows to create an ASCOM device project with the dotnet new
command (require the .NET Core/.NET 5 SDK).
More information on dotnet templating :
- https://github.com/dotnet/templating#info-for-dotnet-new-users
- https://github.com/dotnet/docs/blob/master/docs/core/tools/custom-templates.md
The installation and the use of the template require the .NET Core or .NET 5 to be installed.
Download or clone the source code.
Open a command line terminal (cmd or powershell) in the template root directory
Run the command dotnet new --install ./content/
Download the NuGet package from the releases page
Execute the command : dotnet new -i .\ASCOM.Device.Template.0.1.0-beta.1.nupkg
To create a new driver project, execute the command dotnet new ascomdevice --name MyDome --deviceType Dome
where --name
is the name of the project and --deviceType
the type of the driver.
For complete help on the supported driver values and other parameters, execute dotnet new ascomdevice -h