上机测试优化2

This commit is contained in:
hsc
2026-07-21 15:51:49 +08:00
parent 4386449925
commit be7b459385
4 changed files with 53 additions and 25 deletions

View File

@@ -109,10 +109,34 @@ namespace DeviceCommand.Devices
/// 设置电子负载的基本工作模式 (INPut:FUNCtion <mode>)
/// (支持 CC, CV, CR, CP, CCD, CVD, CRD, CPD, OCP, OPP, ESR, MPP, SWEEP 等)
/// </summary>
public virtual async Task (string , CancellationToken ct = default)
public enum DeviceWorkMode
{
string modeUpper = .ToUpper();
await SendAsync($"INPut:FUNCtion {modeUpper}{ScpiDelimiter}", ct);
CC,
CV,
CR,
CP,
CCD,
ESR,
AUTO,
DISCHARGE,
CHARGE,
OCP,
CVD,
CRD,
MPP,
CVCC,
CRCC,
CPCC,
CVCR,
WAVE,
SWEEP,
OPP,
CPD,
SZ
}
public virtual async Task (DeviceWorkMode , CancellationToken ct = default)
{
await SendAsync($"INPut:FUNCtion {Enum.GetName(模式)}{ScpiDelimiter}", ct);
}
/// <summary>