This commit is contained in:
xyy
2026-04-02 10:13:01 +08:00
parent 890658ea33
commit e25f4b0e2f
6 changed files with 79 additions and 24 deletions

View File

@@ -28,7 +28,7 @@ namespace MembranePoreTester.Communication
}
// 读取两个连续的保持寄存器转换为32位浮点数假设大端模式
private async Task<float> ReadFloatAsync(ushort startAddress)
public async Task<float> ReadFloatAsync(ushort startAddress)
{
await EnsureConnectedAsync();
var registers = await ReadHoldingRegistersAsync(startAddress, 2);