replace cpx code with generic gemma analogout

This commit is contained in:
ladyada 2017-10-12 20:16:29 -04:00
parent ddeb2d61e7
commit 85a45fda5a
2 changed files with 1 additions and 16 deletions

View file

@ -1,15 +0,0 @@
# CircuitPlaygroundExpress_AnalogOut
# hook up ground an A0 to a voltmeter or scope
# to watch the voltage rise!
from analogio import AnalogOut
import board
import time
aout = AnalogOut(board.A0)
while True:
# Count up from 0 to 65535, with 64 increment
# which ends up corresponding to the DAC's 10-bit range
for i in range (0,65535,64):
aout.value = i
time.sleep(0.01)

View file

@ -1,4 +1,4 @@
# Gemma IO demo - analog output
# CircuitPython IO demo - analog output
from analogio import AnalogOut
import board