mirror of
https://github.com/KevinMidboe/python-gpiozero.git
synced 2026-01-12 12:25:52 +00:00
Convert recipe examples to includes
Makes it much easier to test things - no copying'n'pasting just run the examples straight from the dir (after wiring stuff up)
This commit is contained in:
9
docs/examples/led_builtin.py
Normal file
9
docs/examples/led_builtin.py
Normal file
@@ -0,0 +1,9 @@
|
||||
from gpiozero import LED
|
||||
from signal import pause
|
||||
|
||||
power = LED(35) # /sys/class/leds/led1
|
||||
activity = LED(47) # /sys/class/leds/led0
|
||||
|
||||
activity.blink()
|
||||
power.blink()
|
||||
pause()
|
||||
Reference in New Issue
Block a user