109
Sample Programs
Measure the internal resistance using the BT3562A and measure the OCV using the DM7276.
Connect the SW1001 and BT3562A, DM7276 to their respective COM ports and perform scan
measurement of internal resistance and OCV from CH1 to CH11 for
SLOT 1
.
'Scan measurement sample
Private Sub ScanSample2()
Dim unit_no As Integer
Dim ch_no As Integer
Dim ch_str As String
Dim recv_str As String
Dim ir_str(50) As String
Dim ocv_str(50) As String
Dim i As Integer
MSComm1.CommPort = 3
'Connect the SW1001 to COM3.
MSComm1.Settings = "9600,n,8,1"
MSComm2.CommPort = 4
'Connect the BT3562A to COM4.
MSComm2.Settings = "9600,n,8,1"
MSComm3.CommPort = 5
'Connect the DM7276 to COM5.
MSComm3.Settings = "9600,n,8,1"
MSComm1.PortOpen = True
MSComm2.PortOpen = True
MSComm3.PortOpen = True
Open App.Path & "\data.csv" For Output As #1
'Open a file for saving.
SendCommand MSComm1, ":SYST:MOD:WIRE:MODE 1,WIRE4"
'Configure SLOT1 as a 4-wire connection.
SendCommand MSComm1, "*OPC?"
'Wait for the operation to complete.
ReceiveCOM MSComm1
SendCommand MSComm2, ":INIT:CONT OFF"
'Turn off the continuous measurement of
BT3562A.
i = 0
For unit_no = 1 To 1
For ch_no = 1 To 11
ch_str = Format(unit_no, "00") & Format(ch_no, "00")
'Create a string to specify the channel.
SendCommand MSComm1, ":CLOS " & ch_str
'Close the specified channel.
SendCommand MSComm1, "*OPC?"
'Wait for the closing of the channel to complete.
ReceiveCOM MSComm1
SendCommand MSComm2, ":READ?"
'Send the one-time measurement command to
the BT3562A.
ir_str(i) = ReceiveCOM(MSComm2)
'Receive the measured value.
i = i + 1
Next
Next
SendCommand MSComm1, ":SYST:MOD:WIRE:MODE 1,WIRE2"
'Configure SLOT1 as a 2-wire connection.
SendCommand MSComm1, "*OPC?"
'Wait for the operation to complete.
ReceiveCOM MSComm1
i = 0
For unit_no = 1 To 1
For ch_no = 12 To 22
'The 2-wire CH12 corresponds to the 4-wire CH1
sense.
ch_str = Format(unit_no, "00") & Format(ch_no, "00")
'Create a string to specify the channel.
SendCommand MSComm1, ":CLOS " & ch_str
'Close the specified channel.
SendCommand MSComm1, "*OPC?"
'Wait for the closing of the channel to complete.
ReceiveCOM MSComm1
SendCommand MSComm3, ":READ?"
'Send the one-time measurement command to
the DM7276.
ocv_str(i) = ReceiveCOM(MSComm3)
'Receive the measured value.
i = i + 1
Next
Next
SendCommand MSComm1, ":OPEN"
'Open all relays after the scan completes.
8
Communication Function
HIOKI SW1001A961-04
Содержание SW9001
Страница 2: ...HIOKI SW1001A961 04...
Страница 42: ...38 Channel Delay Function HIOKI SW1001A961 04...
Страница 48: ...44 Scan Measurement Example HIOKI SW1001A961 04...
Страница 50: ...46 Checking the Device Status HIOKI SW1001A961 04...
Страница 52: ...48 Initialization Settings HIOKI SW1001A961 04...
Страница 118: ...114 Sample Programs 3 Select FILE Save All HIOKI SW1001A961 04...
Страница 160: ...156 Outline Drawings 12 4 Outline Drawings SW1001 Unit mm Tolerance 0 2 HIOKI SW1001A961 04...
Страница 161: ...157 Outline Drawings SW1002 Unit mm Tolerance 0 2 12 Appendix HIOKI SW1001A961 04...
Страница 162: ...158 Outline Drawings HIOKI SW1001A961 04...
Страница 164: ...160 HIOKI SW1001A961 04...
Страница 167: ...HIOKI SW1001A961 04...
Страница 168: ...HIOKI SW1001A961 04...
Страница 169: ...HIOKI SW1001A961 04...