Create light-plot.py
initial commit
This commit is contained in:
parent
0942989ab8
commit
68696f402f
1 changed files with 11 additions and 0 deletions
11
Make_It_Sense/light-plot.py
Normal file
11
Make_It_Sense/light-plot.py
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
import time
|
||||
import analogio
|
||||
import board
|
||||
|
||||
# Create the light sensor object to read from
|
||||
light = analogio.AnalogIn(board.LIGHT)
|
||||
|
||||
# Do readings, be sure to pause between readings
|
||||
while True:
|
||||
print((light.value, ))
|
||||
time.sleep(0.1)
|
||||
Loading…
Reference in a new issue