hotfix camera function

This commit is contained in:
Alejandro Diaz 2023-09-13 13:11:35 -06:00
parent 37f8d5883a
commit a60d427dd4

View file

@ -26,7 +26,7 @@ def home(request):
def take_photo(request):
capture_image("/tmp/static/photo.jpg")
pin_control.capture_image("/tmp/static/photo.jpg")
return HttpResponse("Ok")
@ -40,11 +40,13 @@ def led(request, led):
return HttpResponse("Ok")
def turn_off_all():
print("TURN OFF ALL")
for pin in leds_gpio.values():
pin_control.turn_on_pin(pin)
return HttpResponse("Ok")
def turn_on_all():
print("TURN ON ALL")
for pin in leds_gpio.values():
pin_control.turn_off_pin(pin)
return HttpResponse("Ok")
def toggle_led(led, turn_on):