VOOZH about

URL: https://www.nuget.org/packages/Inheco.SiLA2.Scila.Features/

⇱ NuGet Gallery | Inheco.SiLA2.Scila.Features 0.10.0-BETA




👁 Image
Inheco.SiLA2.Scila.Features 0.10.0-BETA

This is a prerelease version of Inheco.SiLA2.Scila.Features.
dotnet add package Inheco.SiLA2.Scila.Features --version 0.10.0-BETA
 
 
NuGet\Install-Package Inheco.SiLA2.Scila.Features -Version 0.10.0-BETA
 
 
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Inheco.SiLA2.Scila.Features" Version="0.10.0-BETA" />
 
 
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Inheco.SiLA2.Scila.Features" Version="0.10.0-BETA" />
 
Directory.Packages.props
<PackageReference Include="Inheco.SiLA2.Scila.Features" />
 
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Inheco.SiLA2.Scila.Features --version 0.10.0-BETA
 
 
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: Inheco.SiLA2.Scila.Features, 0.10.0-BETA"
 
 
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Inheco.SiLA2.Scila.Features@0.10.0-BETA
 
 
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Inheco.SiLA2.Scila.Features&version=0.10.0-BETA&prerelease
 
Install as a Cake Addin
#tool nuget:?package=Inheco.SiLA2.Scila.Features&version=0.10.0-BETA&prerelease
 
Install as a Cake Tool
The NuGet Team does not provide support for this client. Please contact its maintainers for support.

##SiLA2 Implementation of INHECO SCILA Device

This feature enables the integration of SCILA device in a SiLA2 standard conformed software solutions.

For an introduction about SiLA2 development with C# there is a SiLA2 reference implementation sila_csharp.

The service that implements this SiLA2 feature is called

SiLA2.Scila.Features.Services.ScilaSiLA1Service

The configuration of the service in a SiLA2 Server would follow the pattern described in the sila_csharp reference implementation with additional parameters. NetworkInterfaceName and DeviceIP are required.

"ServerConfig": {
 "Name": "Inheco SiLA2 SCILA Prototype Server",
 "UUID": "CB2CDF15-AB7D-4EC1-B7C8-CD0BCE40135C",
 "FQHN": "localhost", //IP or CIDR or Fully Qualified Host Name
 "Port": 7706,
 "NetworkInterface": "Default",
 "DiscoveryServiceName": "_sila._tcp"
 },
 "CommandLifetimeInSeconds": 60,
 "ServerInfo": {
 "VendorURI": "https://www.inheco.com",
 "Description": "SCILA SiLA2 server implementation.",
 "Version": "7.5.3",
 "Type": "SiLA2ScilaServer"
 },
 "NetworkInterfaceName": "My Ethernet",
 "DeviceIp": "192.168.1.128"
 //"ConnectLockId": "myLockId",
 //"CustomDeviceId": "myDeviceId",
 //"EventReceiverPort": 7071

Internally, the feature connects to a IhcPmsLib.Scila.Scila device (specified by the "DeviceIp" above) which sends DataEvents and StatusEvents to the PMS.

Registration of the services with WebApplicationBuilder (from sila_csharp reference implementation) would include also the following lines:

using static Sila2.Com.Inheco.Scila.Scilasila1.V1.ScilaSiLA1;
...
app.MapGrpcService<ScilaSiLA1Service>();
... 
services.AddSingleton<ScilaSiLA1Service>();
...

In a SiLA2 client application, we could call a SiLA2 command as follows:

private static async Task<GrpcChannel> GetChannel(string[] args) {
 var configBuilder = new ConfigurationBuilder()
 .SetBasePath(Directory.GetCurrentDirectory())
 .AddJsonFile("appsettings.json", optional: false, reloadOnChange: true);
 var configuration = configBuilder.Build();
 var clientSetup = new Configurator(configuration, args);
 ILogger<Program> logger = (ILogger<Program>)clientSetup.ServiceProvider.GetService(typeof(ILogger<Program>));
 var clientConfig = clientSetup.ServiceProvider.GetService<IClientConfig>();
 Console.WriteLine($"Using Server-URI '{clientConfig.IpOrCdirOrFullyQualifiedHostName}:{clientConfig.Port}' from ClientConfig");
 GrpcChannel channel = await ((IGrpcChannelProvider)clientSetup.ServiceProvider.GetService(typeof(IGrpcChannelProvider))).GetChannel(clientConfig.IpOrCdirOrFullyQualifiedHostName, clientConfig.Port, accceptAnyServerCertificate: true);
 return channel;
}

try
{
 var client = new ScilaSiLA1.ScilaSiLA1Client(channel);
 var resGS = client.GetStatus(new GetStatus_Parameters());
 var resGDI = client.GetDeviceIdentification(new GetDeviceIdentification_Parameters());
}
catch (Grpc.Core.RpcException rpcex)
{
 _errorMessage = ErrorHandling.HandleException(rpcex);
}
catch (Exception ex)
{
 _errorMessage = ex.Message;
}
 
Product Versions Compatible and additional computed target framework versions.
.NET net8.0 net8.0 is compatible.  net8.0-android net8.0-android was computed.  net8.0-browser net8.0-browser was computed.  net8.0-ios net8.0-ios was computed.  net8.0-maccatalyst net8.0-maccatalyst was computed.  net8.0-macos net8.0-macos was computed.  net8.0-tvos net8.0-tvos was computed.  net8.0-windows net8.0-windows was computed.  net9.0 net9.0 was computed.  net9.0-android net9.0-android was computed.  net9.0-browser net9.0-browser was computed.  net9.0-ios net9.0-ios was computed.  net9.0-maccatalyst net9.0-maccatalyst was computed.  net9.0-macos net9.0-macos was computed.  net9.0-tvos net9.0-tvos was computed.  net9.0-windows net9.0-windows was computed.  net10.0 net10.0 was computed.  net10.0-android net10.0-android was computed.  net10.0-browser net10.0-browser was computed.  net10.0-ios net10.0-ios was computed.  net10.0-maccatalyst net10.0-maccatalyst was computed.  net10.0-macos net10.0-macos was computed.  net10.0-tvos net10.0-tvos was computed.  net10.0-windows net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
0.10.0-BETA 220 6/27/2024
0.9.1-BETA 321 10/23/2023
0.9.0-BETA 163 10/16/2023

v0.10.0
- new SiLA2-Features: split into mandatory/common/scila specific
- added various SiLA2 properties
- updated reference: SiLA2.Core 8.1.0, Grpc.Tools 2.64.0
- updated reference: Inheco.IhcPmasLib.Scila 1.1.0
v0.9.2
- target framework net8.0
v0.9.1
- feature.xml included as embedded resource
- server should ensure to call ScilaSiLA1Service-ctor once at startup.
v0.9.0
- initial beta release