Commit 8a53baae authored by Kristian Tan's avatar Kristian Tan

removed '' around pin outputs

parent 3132bcd3
......@@ -7,7 +7,7 @@ GPIO.setmode(GPIO.BCM)
# Create a dictionary called pins to store the pin number, name, and pin state:
pins = {
25: {'name': 'Light', 'state': 'GPIO.LOW'}
25: {'name': 'Light', 'state': GPIO.LOW}
}
#
# Set each pin as an output and make it low:
......@@ -20,7 +20,7 @@ for pin in pins:
def main():
# For each pin, read the pin state and store it in the pins dictionary:
for pin in pins:
pins[pin]['state'] = 'GPIO.input(pin)'
pins[pin]['state'] = GPIO.input(pin)
# Put the pin dictionary into the template data dictionary:
template_data = {
'pins': pins
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment