system
August 2, 2014, 3:03pm
1
i need to switch on a solid state relay with few condition.
i need to use 2 output say output1 & output2.
input are IN1 , IN2 , IN3 , IN4.
Programme will be.
if IN1 = high
IN2 = high.
IN3 = low
& when IN 4 = high.
OUTPUT 1 & OUTPUT 2 will be on.
when IN 1 = low.
OUTPUT 2 =low.
when IN2 low , OUTPUT 1 = high
when IN3 high , OUTPUT 1 = low
when IN3 LOW, OUTPUT 1 =low.
when IN 2 high , OUTPUT 1 = high.
& this OUTPUT 1 keeps going high & low depending on IN2 & IN3.
1 reset button required.
Arduino is C/C++ wrapped up with wiring libraries just workout your code in IF or Switch conditions as you would do with any C/C++ software programme and then use wiring methods of pinMode() to set the pin mode to output or input and use digitalWrite to control the outputs!
Read the reference section on how to use, try to write the code and test it and if its doesn't work post here, people will workout the problem.
I think you should learn yourself, start with Blink example examine it, change values, learn what "digitalRead" means
Then you need to start with Bare Minimum
Open Arduino IDE Select "File" Menu > "Examples" > "01.Basics" > "BareMinimum "
This will open a new window.
in void setup() you are going to setup Arduino Pins
You have 2 output and 4 input, define them here
in void loop() you are going to program what should these pin will
you are going to use "if" "else" statements learn it and apply to your program
http://arduino.cc/en/Reference/Else
system
August 2, 2014, 7:51pm
4
At the top of this page in green click Reference.
Study the Structure and Functions. Some have examples, try them.
system
August 3, 2014, 3:45am
5
actually i am doing this all on PLC.
and i thought if i could learn to do the same on micro-controller,
i could do more out of the same programme.
please guyz help me learning .
sunil202001:
please guyz help me learning .
Three members just did exactly that, pointing you at resources and suggesting basic code structure.
If by help you learning, you mean you want someone to do the code for you, well that's a different thing altogether.
1 reset button required
The board has a reset button: do you mean something different from a button that resets the board and restarts your code?
actually i am doing this all on PLC.
and i thought if i could learn to do the same on micro-controller,
The two are so differant that there is no advantage in knowing how to do it in C
Grumpy_Mike:
actually i am doing this all on PLC.
and i thought if i could learn to do the same on micro-controller,
The two are so differant that there is no advantage in knowing how to do it in C
If he just needs to switch a relay as he stated, then plc is way overkill.
I think this guy isn't sure what he actually wants.
Also asking a question is also an art ,you have to put it the right way.
Hi, sunil202001, you will be programming in ladder I would assume.
You need to find a plc forum, of which there are many around.
Is this an educational project or a commercial project or a personal project?
If educational, then you should have a teacher, lecturer, tutor who can help you.
Also I'd say you would already have been taught ladder programming.
Tom....