Skip to content

Commit 5e47970

Browse files
First Steps in Controlling the Raspberry Camera with python
1 parent 9da865a commit 5e47970

File tree

2 files changed

+22
-0
lines changed

2 files changed

+22
-0
lines changed

HolaMundo.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
print ("Hola mundo")

LedControl.py

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
#First steps to handle the camera led
2+
from picamera import PiCamera
3+
import time
4+
import RPi.GPIO as GPIO
5+
from CameraLED import CameraLED
6+
7+
GPIO.setmode(GPIO.BCM)
8+
GPIO.setwarnings(False)
9+
camera = PiCamera()
10+
led = CameraLED()
11+
12+
i = 3
13+
led.on()
14+
time.sleep(2)
15+
led.off()
16+
print("Spuestamente tendría que estar apagado el led")
17+
time.sleep(5)
18+
led.on()
19+
print("Encendido")
20+
time.sleep(2)
21+
led.off()

0 commit comments

Comments
 (0)