ZL.IotHub.Server 2.2.14

dotnet add package ZL.IotHub.Server --version 2.2.14
                    
NuGet\Install-Package ZL.IotHub.Server -Version 2.2.14
                    
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="ZL.IotHub.Server" Version="2.2.14" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="ZL.IotHub.Server" Version="2.2.14" />
                    
Directory.Packages.props
<PackageReference Include="ZL.IotHub.Server" />
                    
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 ZL.IotHub.Server --version 2.2.14
                    
#r "nuget: ZL.IotHub.Server, 2.2.14"
                    
#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 ZL.IotHub.Server@2.2.14
                    
#: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=ZL.IotHub.Server&version=2.2.14
                    
Install as a Cake Addin
#tool nuget:?package=ZL.IotHub.Server&version=2.2.14
                    
Install as a Cake Tool

ZL.IotHub.Server

通用 SCADA 实时网关:把 ZL.IotHub 采集内核的数据, 通过 SignalR(推送 + 命令)+ REST(查询 / 读写) 暴露给 Web / 桌面客户端。

协议无关——凡 ZL.IotHub 能驱动的设备(Siemens S7、Modbus、三菱、欧姆龙、AB、倍福、台达、基恩士…), 均可接入本网关做 SCADA 集成。

三步接入

var builder = WebApplication.CreateBuilder(args);
builder.Services.AddZlScada(builder.Configuration);              // 1. 装配
var app = builder.Build();
ScadaDeviceProvisioner.ProvisionFromConfiguration(app.Configuration, app.Logger); // 2. 配置化注册设备
app.MapZlScada();                                                // 3. 映射端点
app.Run();

appsettings.json:

{
  "Urls": "http://localhost:5003",
  "Scada": {
    "Devices": [
      {
        "DeviceId": "PLC001",
        "Protocol": "siemens-s7",
        "Params": { "DeviceIp": "127.0.0.1", "Port": "102", "Rack": "0", "Slot": "1" },
        "Tags": [ { "Id": "MotorSpeed", "Address": "DB1.DBD14", "DataTypeCode": "int", "Length": 4, "AccessMode": "ReadWrite" } ]
      }
    ]
  }
}

默认端点

类型 路径
SignalR Hub /scadahub
健康检查 /health(含设备数/授权状态)
REST /api/devices、/api/tags/...、/api/devices/{id}/batch-read\|batch-write、/api/metrics

SignalR 事件:Snapshot、TagChanges、ConnectionStatus、DeviceStateChanged;方法:SendCommand、Subscribe。

可组合映射(进阶)

app.MapZlScadaHub("/iot/hub");     // 只取 Hub(可自行加鉴权)
app.MapZlScadaRestApi("/iot");     // 自定义 REST 前缀
app.MapZlScadaHealth();

边界

  • 不含具体协议驱动(依赖 ZL.IotHub;HSL 商业协议需额外引用 ZL.IotHub.X);
  • 不含用户/鉴权体系(消费方自行接入);
  • 不含历史数据库。

详见仓库 docs/249(架构审查)与 docs/250(使用指南)。

Product Compatible and additional computed target framework versions.
.NET net8.0 is compatible.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed.  net9.0 was computed.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  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
2.2.14 24 10/6/2026