relay 2 or 4 or 8 channel ?!
-
hi
I want build a relay 2 or 4 or 8 channel , but I dont know What is the program?have any body the program of relay 2 and 4 and 8 channel ?
also , for a relay 8 channel with arduino , there are 6 pins ( 2,9,10,11,12,13) in arduino for radio nrf24l01 and there are 6 digital pins for relay !!! what am I do ?
please help me and give me a correct program for 2,4,8 relay .
-
@reza if you are looking for solution to control relays without buttons then you can use default mysensors relay-actuator sketch.
You only need to change this line according to the number of relays you want to control (this will work with 2 and 4 channel relays).
#define NUMBER_OF_RELAYS 1 // Total number of attached relaysFor 8 channel I think you would need custom sketch.
Check this thread. Sketch posted there allows you to assign individual pins. -
hiii,
Go through this link. http://forum.mysensors.org/topic/2833/relaywithbuttonactuator-6-channel -
@reza if you are looking for solution to control relays without buttons then you can use default mysensors relay-actuator sketch.
You only need to change this line according to the number of relays you want to control (this will work with 2 and 4 channel relays).
#define NUMBER_OF_RELAYS 1 // Total number of attached relaysFor 8 channel I think you would need custom sketch.
Check this thread. Sketch posted there allows you to assign individual pins.@niccodemi
hi my dear friend,
really ? just this line ???
so dont need I add new lines ? for example 4 channel :
#define RELAY_1 3
#define RELAY_2 4
#define RELAY_3 5
#define RELAY_4 6
I think these you say all of relay on or all of relay off ? is it true ? I want manage each relay Separately -
hiii,
Go through this link. http://forum.mysensors.org/topic/2833/relaywithbuttonactuator-6-channel -
@Reza below is example for 4 channel relay
#define NUMBER_OF_RELAYS 4It is that simple. If you will use this sketch then connect relays to pins 3, 4, 5 and 6.
You will be able to control each relay independently.
Relay actuator sketch allows you to control relays only via controller ie Veralite. Relay actuator with button sketch allows you to control relays via controller AND physical button (light switch). -
@Reza below is example for 4 channel relay
#define NUMBER_OF_RELAYS 4It is that simple. If you will use this sketch then connect relays to pins 3, 4, 5 and 6.
You will be able to control each relay independently.
Relay actuator sketch allows you to control relays only via controller ie Veralite. Relay actuator with button sketch allows you to control relays via controller AND physical button (light switch).@niccodemi
so mean that if i change "just" this line (#define NUMBER_OF_RELAYS 4) I can have a relay 4 channel ?
also I dont need define :
#define RELAY_1 3
#define RELAY_2 4
#define RELAY_3 5
#define RELAY_4 6
???