mirror of
https://gitee.com/ThingsGateway/ThingsGateway.git
synced 2025-10-20 18:51:28 +08:00
更新依赖
This commit is contained in:
@@ -12,7 +12,7 @@
|
|||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<PackageReference Include="BootstrapBlazor.TableExport" Version="9.2.6" />
|
<PackageReference Include="BootstrapBlazor.TableExport" Version="9.2.7" />
|
||||||
<PackageReference Include="Yitter.IdGenerator" Version="1.0.14" />
|
<PackageReference Include="Yitter.IdGenerator" Version="1.0.14" />
|
||||||
<PackageReference Include="BootstrapBlazor" Version="9.11.0" />
|
<PackageReference Include="BootstrapBlazor" Version="9.11.0" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
@@ -29,7 +29,7 @@
|
|||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<PackageReference Include="Swashbuckle.AspNetCore" Version="9.0.5" />
|
<PackageReference Include="Swashbuckle.AspNetCore" Version="9.0.6" />
|
||||||
<PackageReference Include="System.Text.Encoding.CodePages" Version="$(NET10Version)" />
|
<PackageReference Include="System.Text.Encoding.CodePages" Version="$(NET10Version)" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
|
@@ -6,7 +6,7 @@
|
|||||||
|
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<PackageReference Include="BootstrapBlazor.FontAwesome" Version="9.1.1" />
|
<PackageReference Include="BootstrapBlazor.FontAwesome" Version="9.1.2" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
|
@@ -28,7 +28,7 @@
|
|||||||
<PackageReference Include="Microsoft.Data.Sqlite" Version="7.0.20" />
|
<PackageReference Include="Microsoft.Data.Sqlite" Version="7.0.20" />
|
||||||
<!--<PackageReference Include="Microsoft.Data.Sqlite" Version="$(NET10Version)" />-->
|
<!--<PackageReference Include="Microsoft.Data.Sqlite" Version="$(NET10Version)" />-->
|
||||||
<PackageReference Include="MySqlConnector" Version="2.4.0" />
|
<PackageReference Include="MySqlConnector" Version="2.4.0" />
|
||||||
<PackageReference Include="Npgsql" Version="9.0.3" />
|
<PackageReference Include="Npgsql" Version="9.0.4" />
|
||||||
<PackageReference Include="CsvHelper" Version="33.1.0" />
|
<PackageReference Include="CsvHelper" Version="33.1.0" />
|
||||||
<PackageReference Include="TDengine.Connector" Version="3.1.9" />
|
<PackageReference Include="TDengine.Connector" Version="3.1.9" />
|
||||||
<PackageReference Include="Oracle.ManagedDataAccess.Core" Version="23.9.1" />
|
<PackageReference Include="Oracle.ManagedDataAccess.Core" Version="23.9.1" />
|
||||||
|
@@ -1,9 +1,9 @@
|
|||||||
<Project>
|
<Project>
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<PluginVersion>10.11.83</PluginVersion>
|
<PluginVersion>10.11.84</PluginVersion>
|
||||||
<ProPluginVersion>10.11.83</ProPluginVersion>
|
<ProPluginVersion>10.11.84</ProPluginVersion>
|
||||||
<DefaultVersion>10.11.83</DefaultVersion>
|
<DefaultVersion>10.11.84</DefaultVersion>
|
||||||
<AuthenticationVersion>10.11.6</AuthenticationVersion>
|
<AuthenticationVersion>10.11.6</AuthenticationVersion>
|
||||||
<SourceGeneratorVersion>10.11.6</SourceGeneratorVersion>
|
<SourceGeneratorVersion>10.11.6</SourceGeneratorVersion>
|
||||||
<NET8Version>8.0.20</NET8Version>
|
<NET8Version>8.0.20</NET8Version>
|
||||||
@@ -12,7 +12,7 @@
|
|||||||
<IsTrimmable>false</IsTrimmable>
|
<IsTrimmable>false</IsTrimmable>
|
||||||
<ManagementProPluginVersion>10.11.70</ManagementProPluginVersion>
|
<ManagementProPluginVersion>10.11.70</ManagementProPluginVersion>
|
||||||
<ManagementPluginVersion>10.11.70</ManagementPluginVersion>
|
<ManagementPluginVersion>10.11.70</ManagementPluginVersion>
|
||||||
<TSVersion>4.0.0-beta.80</TSVersion>
|
<TSVersion>4.0.0-beta.96</TSVersion>
|
||||||
|
|
||||||
|
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
@@ -73,7 +73,7 @@
|
|||||||
<EmbedAllSources>True</EmbedAllSources>
|
<EmbedAllSources>True</EmbedAllSources>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<PackageReference Include="Roslynator.Analyzers" Version="4.14.0">
|
<PackageReference Include="Roslynator.Analyzers" Version="4.14.1">
|
||||||
<PrivateAssets>all</PrivateAssets>
|
<PrivateAssets>all</PrivateAssets>
|
||||||
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
||||||
</PackageReference>
|
</PackageReference>
|
||||||
|
@@ -8,7 +8,7 @@
|
|||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<PackageReference Include="CS-Script" Version="4.11.0" />
|
<PackageReference Include="CS-Script" Version="4.11.2" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
|
@@ -36,6 +36,7 @@
|
|||||||
<EditorItem @bind-Field="@context.StopBits" Ignore=@(context.ChannelType != ChannelTypeEnum.SerialPort) />
|
<EditorItem @bind-Field="@context.StopBits" Ignore=@(context.ChannelType != ChannelTypeEnum.SerialPort) />
|
||||||
<EditorItem @bind-Field="@context.DtrEnable" Ignore=@(context.ChannelType != ChannelTypeEnum.SerialPort) />
|
<EditorItem @bind-Field="@context.DtrEnable" Ignore=@(context.ChannelType != ChannelTypeEnum.SerialPort) />
|
||||||
<EditorItem @bind-Field="@context.RtsEnable" Ignore=@(context.ChannelType != ChannelTypeEnum.SerialPort) />
|
<EditorItem @bind-Field="@context.RtsEnable" Ignore=@(context.ChannelType != ChannelTypeEnum.SerialPort) />
|
||||||
|
<EditorItem @bind-Field="@context.StreamAsync" Ignore=@(context.ChannelType != ChannelTypeEnum.SerialPort) />
|
||||||
<EditorItem @bind-Field="@context.Handshake" Ignore=@(context.ChannelType != ChannelTypeEnum.SerialPort) />
|
<EditorItem @bind-Field="@context.Handshake" Ignore=@(context.ChannelType != ChannelTypeEnum.SerialPort) />
|
||||||
|
|
||||||
|
|
||||||
|
@@ -42,6 +42,7 @@
|
|||||||
"PortName": "COM Port",
|
"PortName": "COM Port",
|
||||||
"RemoteUrl": "Remote IP Address",
|
"RemoteUrl": "Remote IP Address",
|
||||||
"RtsEnable": "Rts",
|
"RtsEnable": "Rts",
|
||||||
|
"StreamAsync": "StreamAsync",
|
||||||
"Handshake": "Handshake",
|
"Handshake": "Handshake",
|
||||||
"SaveChannel": "Add/Modify Channel",
|
"SaveChannel": "Add/Modify Channel",
|
||||||
"StopBits": "Stop Bits"
|
"StopBits": "Stop Bits"
|
||||||
@@ -102,6 +103,7 @@
|
|||||||
"PortName": "PortName",
|
"PortName": "PortName",
|
||||||
"RemoteUrl": "RemoteUrl",
|
"RemoteUrl": "RemoteUrl",
|
||||||
"RtsEnable": "RtsEnable",
|
"RtsEnable": "RtsEnable",
|
||||||
|
"StreamAsync": "StreamAsync",
|
||||||
"Handshake": "Handshake",
|
"Handshake": "Handshake",
|
||||||
"StopBits": "StopBits"
|
"StopBits": "StopBits"
|
||||||
}
|
}
|
||||||
|
@@ -40,6 +40,7 @@
|
|||||||
"PortName": "COM口",
|
"PortName": "COM口",
|
||||||
"RemoteUrl": "远程url",
|
"RemoteUrl": "远程url",
|
||||||
"RtsEnable": "Rts",
|
"RtsEnable": "Rts",
|
||||||
|
"StreamAsync": "流读写",
|
||||||
"Handshake": "Handshake",
|
"Handshake": "Handshake",
|
||||||
"SaveChannel": "添加/修改通道",
|
"SaveChannel": "添加/修改通道",
|
||||||
"StopBits": "停止位"
|
"StopBits": "停止位"
|
||||||
@@ -100,6 +101,7 @@
|
|||||||
"PortName": "COM口",
|
"PortName": "COM口",
|
||||||
"RemoteUrl": "远程url",
|
"RemoteUrl": "远程url",
|
||||||
"RtsEnable": "Rts",
|
"RtsEnable": "Rts",
|
||||||
|
"StreamAsync": "流读写",
|
||||||
"Handshake": "串口流读写",
|
"Handshake": "串口流读写",
|
||||||
"StopBits": "停止位"
|
"StopBits": "停止位"
|
||||||
}
|
}
|
||||||
|
@@ -78,6 +78,8 @@ namespace ThingsGateway.Foundation
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public virtual bool RtsEnable { get; set; } = true;
|
public virtual bool RtsEnable { get; set; } = true;
|
||||||
|
|
||||||
|
public virtual bool StreamAsync { get; set; } = true;
|
||||||
|
|
||||||
/// <inheritdoc/>
|
/// <inheritdoc/>
|
||||||
[MinValue(1)]
|
[MinValue(1)]
|
||||||
public virtual int MaxConcurrentCount { get; set; } = 1;
|
public virtual int MaxConcurrentCount { get; set; } = 1;
|
||||||
|
@@ -172,6 +172,7 @@ public static class ChannelOptionsExtensions
|
|||||||
options.DtrEnable = channelOptions.DtrEnable;
|
options.DtrEnable = channelOptions.DtrEnable;
|
||||||
options.RtsEnable = channelOptions.RtsEnable;
|
options.RtsEnable = channelOptions.RtsEnable;
|
||||||
options.Handshake = channelOptions.Handshake;
|
options.Handshake = channelOptions.Handshake;
|
||||||
|
options.StreamAsync = channelOptions.StreamAsync;
|
||||||
});
|
});
|
||||||
//载入配置
|
//载入配置
|
||||||
SerialPortChannel serialPortChannel = new SerialPortChannel(channelOptions);
|
SerialPortChannel serialPortChannel = new SerialPortChannel(channelOptions);
|
||||||
|
@@ -72,6 +72,8 @@ public interface IChannelOptions
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
bool RtsEnable { get; set; }
|
bool RtsEnable { get; set; }
|
||||||
|
|
||||||
|
bool StreamAsync { get; set; }
|
||||||
|
|
||||||
Handshake Handshake { get; set; }
|
Handshake Handshake { get; set; }
|
||||||
#endregion
|
#endregion
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
@@ -348,7 +348,7 @@ public abstract class DeviceBase : AsyncAndSyncDisposableObject, IDevice
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private Task BeforeSendAsync(IClientChannel channel, CancellationToken token)
|
private ValueTask BeforeSendAsync(IClientChannel channel, CancellationToken token)
|
||||||
{
|
{
|
||||||
SetDataAdapter(channel);
|
SetDataAdapter(channel);
|
||||||
if (AutoConnect && Channel != null && Channel?.Online != true)
|
if (AutoConnect && Channel != null && Channel?.Online != true)
|
||||||
@@ -357,13 +357,13 @@ public abstract class DeviceBase : AsyncAndSyncDisposableObject, IDevice
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
return Task.CompletedTask;
|
return EasyValueTask.CompletedTask;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private WaitLock connectWaitLock = new(nameof(DeviceBase));
|
private WaitLock connectWaitLock = new(nameof(DeviceBase));
|
||||||
|
|
||||||
public async Task ConnectAsync(CancellationToken token)
|
public async ValueTask ConnectAsync(CancellationToken token)
|
||||||
{
|
{
|
||||||
if (AutoConnect && Channel != null && Channel?.Online != true)
|
if (AutoConnect && Channel != null && Channel?.Online != true)
|
||||||
{
|
{
|
||||||
|
@@ -467,5 +467,5 @@ public interface IDevice : IDisposable, IDisposableObject, IAsyncDisposable
|
|||||||
/// <param name="deviceLog">单独设备日志</param>
|
/// <param name="deviceLog">单独设备日志</param>
|
||||||
void InitChannel(IChannel channel, ILog? deviceLog = null);
|
void InitChannel(IChannel channel, ILog? deviceLog = null);
|
||||||
ValueTask<OperResult<ReadOnlyMemory<byte>>> ReadAsync(object state, CancellationToken cancellationToken = default);
|
ValueTask<OperResult<ReadOnlyMemory<byte>>> ReadAsync(object state, CancellationToken cancellationToken = default);
|
||||||
Task ConnectAsync(CancellationToken token);
|
ValueTask ConnectAsync(CancellationToken token);
|
||||||
}
|
}
|
||||||
|
@@ -22,6 +22,7 @@
|
|||||||
"PortName": "PortName",
|
"PortName": "PortName",
|
||||||
"RemoteUrl": "RemoteUrl",
|
"RemoteUrl": "RemoteUrl",
|
||||||
"RtsEnable": "RtsEnable",
|
"RtsEnable": "RtsEnable",
|
||||||
|
"StreamAsync": "StreamAsync",
|
||||||
"Handshake": "Handshake",
|
"Handshake": "Handshake",
|
||||||
"StopBits": "StopBits"
|
"StopBits": "StopBits"
|
||||||
},
|
},
|
||||||
|
@@ -22,6 +22,7 @@
|
|||||||
"PortName": "COM口",
|
"PortName": "COM口",
|
||||||
"RemoteUrl": "远程url",
|
"RemoteUrl": "远程url",
|
||||||
"RtsEnable": "Rts",
|
"RtsEnable": "Rts",
|
||||||
|
"StreamAsync": "流读写",
|
||||||
"Handshake": "Handshake",
|
"Handshake": "Handshake",
|
||||||
"StopBits": "停止位"
|
"StopBits": "停止位"
|
||||||
},
|
},
|
||||||
|
@@ -137,6 +137,13 @@ public class Channel : ChannelOptionsBase, IPrimaryIdEntity, IBaseDataEntity, IB
|
|||||||
[AutoGenerateColumn(Visible = false, Filterable = true, Sortable = true)]
|
[AutoGenerateColumn(Visible = false, Filterable = true, Sortable = true)]
|
||||||
public override bool RtsEnable { get; set; }
|
public override bool RtsEnable { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// StreamAsync
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnDescription = "StreamAsync", IsNullable = true)]
|
||||||
|
[AutoGenerateColumn(Visible = false, Filterable = true, Sortable = true)]
|
||||||
|
public override bool StreamAsync { get; set; }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Handshake
|
/// Handshake
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
@@ -307,6 +307,7 @@
|
|||||||
"PortName": "PortName",
|
"PortName": "PortName",
|
||||||
"RemoteUrl": "RemoteUrl",
|
"RemoteUrl": "RemoteUrl",
|
||||||
"RtsEnable": "RtsEnable",
|
"RtsEnable": "RtsEnable",
|
||||||
|
"StreamAsync": "StreamAsync",
|
||||||
"Handshake": "Handshake",
|
"Handshake": "Handshake",
|
||||||
"SaveChannel": "Add/Modify Channel",
|
"SaveChannel": "Add/Modify Channel",
|
||||||
"SortCode": "SortCode",
|
"SortCode": "SortCode",
|
||||||
|
@@ -306,6 +306,7 @@
|
|||||||
"PortName": "COM口",
|
"PortName": "COM口",
|
||||||
"RemoteUrl": "远程url",
|
"RemoteUrl": "远程url",
|
||||||
"RtsEnable": "Rts",
|
"RtsEnable": "Rts",
|
||||||
|
"StreamAsync": "流读写",
|
||||||
"Handshake": "Handshake",
|
"Handshake": "Handshake",
|
||||||
"SaveChannel": "添加/修改通道",
|
"SaveChannel": "添加/修改通道",
|
||||||
"SortCode": "排序",
|
"SortCode": "排序",
|
||||||
|
@@ -114,6 +114,7 @@
|
|||||||
<EditorItem @bind-Field="@context.StopBits" Ignore=@(context.ChannelType != ChannelTypeEnum.SerialPort) />
|
<EditorItem @bind-Field="@context.StopBits" Ignore=@(context.ChannelType != ChannelTypeEnum.SerialPort) />
|
||||||
<EditorItem @bind-Field="@context.DtrEnable" Ignore=@(context.ChannelType != ChannelTypeEnum.SerialPort) />
|
<EditorItem @bind-Field="@context.DtrEnable" Ignore=@(context.ChannelType != ChannelTypeEnum.SerialPort) />
|
||||||
<EditorItem @bind-Field="@context.RtsEnable" Ignore=@(context.ChannelType != ChannelTypeEnum.SerialPort) />
|
<EditorItem @bind-Field="@context.RtsEnable" Ignore=@(context.ChannelType != ChannelTypeEnum.SerialPort) />
|
||||||
|
<EditorItem @bind-Field="@context.StreamAsync" Ignore=@(context.ChannelType != ChannelTypeEnum.SerialPort) />
|
||||||
<EditorItem @bind-Field="@context.Handshake" Ignore=@(context.ChannelType != ChannelTypeEnum.SerialPort) />
|
<EditorItem @bind-Field="@context.Handshake" Ignore=@(context.ChannelType != ChannelTypeEnum.SerialPort) />
|
||||||
|
|
||||||
|
|
||||||
|
@@ -82,6 +82,7 @@
|
|||||||
<EditorItem @bind-Field="@context.StopBits" Ignore=@(context.ChannelType!=ChannelTypeEnum.SerialPort) />
|
<EditorItem @bind-Field="@context.StopBits" Ignore=@(context.ChannelType!=ChannelTypeEnum.SerialPort) />
|
||||||
<EditorItem @bind-Field="@context.DtrEnable" Ignore=@(context.ChannelType!=ChannelTypeEnum.SerialPort) />
|
<EditorItem @bind-Field="@context.DtrEnable" Ignore=@(context.ChannelType!=ChannelTypeEnum.SerialPort) />
|
||||||
<EditorItem @bind-Field="@context.RtsEnable" Ignore=@(context.ChannelType!=ChannelTypeEnum.SerialPort) />
|
<EditorItem @bind-Field="@context.RtsEnable" Ignore=@(context.ChannelType!=ChannelTypeEnum.SerialPort) />
|
||||||
|
<EditorItem @bind-Field="@context.StreamAsync" Ignore=@(context.ChannelType != ChannelTypeEnum.SerialPort) />
|
||||||
<EditorItem @bind-Field="@context.Handshake" Ignore=@(context.ChannelType!=ChannelTypeEnum.SerialPort) />
|
<EditorItem @bind-Field="@context.Handshake" Ignore=@(context.ChannelType!=ChannelTypeEnum.SerialPort) />
|
||||||
|
|
||||||
|
|
||||||
|
@@ -35,7 +35,7 @@ public class ModbusBenchmark : IDisposable
|
|||||||
{
|
{
|
||||||
public static int ClientCount = 1;
|
public static int ClientCount = 1;
|
||||||
public static int TaskNumberOfItems = 1;
|
public static int TaskNumberOfItems = 1;
|
||||||
public static int NumberOfItems = 1000;
|
public static int NumberOfItems = 10;
|
||||||
|
|
||||||
private readonly List<IModbusClient> _lgbModbusClients = [];
|
private readonly List<IModbusClient> _lgbModbusClients = [];
|
||||||
private List<ModbusMaster> thingsgatewaymodbuss = new();
|
private List<ModbusMaster> thingsgatewaymodbuss = new();
|
||||||
|
@@ -12,7 +12,7 @@
|
|||||||
<PrivateAssets>all</PrivateAssets>
|
<PrivateAssets>all</PrivateAssets>
|
||||||
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
||||||
</PackageReference>
|
</PackageReference>
|
||||||
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.14.1" />
|
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="18.0.0" />
|
||||||
<PackageReference Include="xunit" Version="2.9.3" />
|
<PackageReference Include="xunit" Version="2.9.3" />
|
||||||
<PackageReference Include="xunit.runner.visualstudio" Version="3.1.5">
|
<PackageReference Include="xunit.runner.visualstudio" Version="3.1.5">
|
||||||
<PrivateAssets>all</PrivateAssets>
|
<PrivateAssets>all</PrivateAssets>
|
||||||
|
Reference in New Issue
Block a user