I have connected VCC
in 5V pin, GND
in gnd pin and IN
in GPIO 26 of my Pi.
Using simple python code to control the relay
import RPi.GPIO as GPIO
GPIO.setmode(GPIO.BCM)
relay_ch = 26
GPIO.setup(relay_ch, GPIO.OUT) // this switch the relay on (green led with sound)
GPIO.output(relay_ch, GPIO.HIGH) //this wont do anything
GPIO.output(relay_ch, GPIO.LOW) //this wont do anything
GPIO.output(relay_ch, True) //this wont do anything
GPIO.output(relay_ch, False) //this wont do anything
GPIO.setup(relay_ch, GPIO.IN) // this turn the relay swift off
why??
I'm using SRD-05VDC-SL-C relay module.