Skip to content

Voltage Outputs

set_pv1 : Set Voltage on PV1

p.set_pv1(value)

set output voltage on PV1 (-5 to +5 V)

parameter description
value between -5 to 5V
return Actual set voltage after accounting for resolution limitations(12-bit)

x = p.set_pv1(2)

import eyes17.eyes
p = eyes17.eyes.open()
p.set_pv1(2)
#Connect PV1 to A1
print ('Voltage at PV1 = ',p.get_voltage('A1'))

set_pv2 : Set Voltage on PV2

p.set_pv2(value)

set output voltage on PV2 (-3.3 to +3.3 V)

parameter description
value between –3.3 to 3.3V
return Actual set voltage after accounting for resolution limitations(12-bit)

x = p.set_pv2(1)

import eyes17.eyes
p = eyes17.eyes.open()
p.set_pv2(1)
#Connect PV2 to A1
print ('Voltage at PV2 = ',p.get_voltage('A1'))
Diode Clipping Demonstration
import eyes17.eyes
p = eyes17.eyes.open()
from matplotlib import pyplot as plt

p.set_sine(200)
p.set_pv1(1.35)       # will clip at 1.35 + diode drop

t,v, tt,vv = p.capture2(500, 20)   # captures A1 and A2

plt.xlabel('Time(mS)')
plt.ylabel('Voltage(V)')
plt.plot([0,10], [0,0], 'black')
plt.ylim([-4,4])

plt.plot(t,v,linewidth = 2, color = 'blue')
plt.plot(tt, vv, linewidth = 2, color = 'red')

plt.show()