CrowPI-L Software Problem
Greetings:
I have a new CrowPi-L computer with modules.
I went over to the Python-Lessons-Hardware section of the software..
I followed the setup of the hardware and typed in the programs for two different programs.
I typed in the switch-light program #3 and it would not work and displayed error.
I next typed in the program for magnetic field sensor - program #5, and it would not work either.
I checked and rechecked both the wiring and the programs and they do not work.
Has anyone reported this problem.
Is there new software? that been corrected?
Please help
Thanks
Tom
I have a new CrowPi-L computer with modules.
I went over to the Python-Lessons-Hardware section of the software..
I followed the setup of the hardware and typed in the programs for two different programs.
I typed in the switch-light program #3 and it would not work and displayed error.
I next typed in the program for magnetic field sensor - program #5, and it would not work either.
I checked and rechecked both the wiring and the programs and they do not work.
Has anyone reported this problem.
Is there new software? that been corrected?
Please help
Thanks
Tom
Comments
Chris
import RPi.GPIO as GPIO import time GPIO.setwarnings(False) led_pin = 4 hall_pin = 5 buzzer_pin = 6 GPIO.setmode(GPIO.BCM) GPIO.setup(led_pin, GPIO.OUT) GPIO.setup(buzzer_pin, GPIO.OUT) GPIO.setup(hall_pin, GPIO.IN) while True: if (GPIO.input(hall_pin)==0): GPIO.output(led_pin, GPIO.HIGH) GPIO.output(buzzer_pin, GPIO.HIGH) time.sleep(0.5) GPIO.output(led_pin, GPIO.LOW) GPIO.output(buzzer_pin, GPIO.LOW) time.sleep(0.5) else: GPIO.output(led_pin, GPIO.LOW) GPIO.output(buzzer_pin, GPIO.LOW)
import RPi.GPIO as GPIO import time GPIO.setwarnings(False) led_pin = 5 button_pin = 6 GPIO.setmode(GPIO.BCM) GPIO.setup(led_pin, GPIO.OUT) GPIO.setup(button_pin, GPIO.IN) while True: if GPIO.input(button_pin): GPIO.output(led_pin, GPIO.HIGH) time.sleep(0.5) GPIO.output(led_pin, GPIO.LOW)