SourceMeter® Instrument User's Manual Section 9: Measuring I-V characteristi
2450-900-01 Rev. E / August 2019 9-9
-- Define initial values.
voltage = defbuffer1.sourcevalues
current = defbuffer1
isc = current[1]
mincurr = current[1]
imax = current[1]
voc = voltage[1]
vmax = voltage[1]
pmax = voltage[1]*current[1]
-- Calculate values.
for i = 1, num do
print(voltage[i],current[i],voltage[i]*current[i])
if (voltage[i]*current[i] < pmax) then
pmax = voltage[i]*current[i]
imax = current[i]
vmax = voltage[i]
end
if math.abs(current[i]) < math.abs(mincurr) then
voc = voltage[i]
end
end
pmax = math.abs(pmax)
imax = math.abs(imax)
print("Pmax = ", pmax, ", Imax = ", imax, ", Vmax = ", vmax, ", Isc = ", isc, ", " ..
"Voc = ", voc)
-- Display values on the front panel.
display.changescreen(display.SCREEN_USER_SWIPE)
display.settext(display.TEXT1, string.format("Pmax = %.4fW", pmax))
display.settext(display.TEXT2, string.format("Isc = %.4fA, Voc = %.2fV", isc, voc))
In the example above, the instrument is programmed to display custom text on the USER swipe
screen using the display.changescreen and display.settext commands. After the test is
finished, the display will indicate the maximum power (P
MAX
), the short circuit current (I
SC
), and the
open circuit voltage (V
OC
), as shown in the figure below.
Figure 53: Solar cell I-V sweep results on the USER swipe screen