Green Project (Arduino Relay x2 )

Hi everybody !

I have a big project thanks to you, I was a beginner in the Arduino's world there is 6 month, and thanks to you I succed to realise something really big I think :wink:

To begin, I have a Raspberry Pi 3 with Domoticz on It. On this Raspberry is connected an Arduino Uno.
On this arduino I have the most of my sensors on control, exept one...

The sensors' list :

-DHT22
-2x Soil Moisture
-2x Relays
-Activity detector

It's seems to be not much.. but the code was a nightmare at the beginning ^^

As I said, I have the control on most of them, exept relays, I just succed too make It work only one at a time but never the both.. I dont understand, which variables I forget to make It work ?
Each time, I duplicate the other codes, I changed variables, and I had 2 values, cool.. but for this one, I dont know how to say to him that I have a Relay on Pin 3 and an other on Pin4..

So I give you the code and ask me all your questions if you have some ideas ^^

".ino Joined with the post because to heavy to put here"

Remember, I learned with all of that, I think you will find a lot of mistakes in It, so tell me I'm ready to learn more ! And sorry for my bad english ^^

Green_Project.ino (7.42 KB)