//更新测量项 public void updateItem(DividerData dividerData, DividerProcess dividerProcess) { int index = dividerProcess.curNum; DividerItem item = null; switch (dividerProcess.curMode) { case EnumMode.Divider_V_DCP: item = dividerData.voltageDCPData[index]; break; case EnumMode.Divider_V_DCN: item = dividerData.voltageDCNData[index]; break; case EnumMode.Divider_V_AC: item = dividerData.voltageACData[index]; break; case EnumMode.Divider_F: item = dividerData.frequencyData[index]; break; } item.State = 1; }
public DividerData() { DividerItem item = null; voltageDCPData = new List <DividerItem>(num); for (int i = 0; i < num; i++) { item = new DividerItem("VDCP"); voltageDCPData.Add(item); } voltageDCNData = new List <DividerItem>(num); for (int i = 0; i < num; i++) { item = new DividerItem("VDCN"); voltageDCNData.Add(item); } voltageACData = new List <DividerItem>(num); for (int i = 0; i < num; i++) { item = new DividerItem("VAC"); voltageACData.Add(item); } frequencyData = new List <DividerItem>(num * 2); for (int i = 0; i < num * 2; i++) { item = new DividerItem("F"); frequencyData.Add(item); } ResetSource(); }