changing a value

wb7076

Member
Join Date
Dec 2012
Location
TN
Posts
4
how would i convert a value in ladder logic
say a = 2000 i want b = 1
then say a = 4500 i want b = 2
then a = 8000 i want b = 3

what i am doing is using a count up to turn on and off valves at different times and i want to add a hmi step switch with a another counter. so step 1 is = 2000 on the first counter, step 2 = 4500, step 3 = 8000. also keep the plc running from the last step enterd. i have it working with the counter but i have to push the step button a lot to get from one step to the next. i just cant add values cause the valves trigger at different count times.
 
how would i convert a value in ladder logic
say a = 2000 i want b = 1
then say a = 4500 i want b = 2
then a = 8000 i want b = 3

its not liner or scale or table i cant use math.
in c++ i would just say if a = 2000 b then = 1
 
In current PLCs there are compare blocks for use in ladder.
Something like this:

Code:
-----[A=B]----[MOV A-B]
   a-[A  ]  1-[A     B]-b
2000-[B  ]  
 
-----[A=B]----[MOV A-B]
   a-[A  ]  2-[A     B]-b
4500-[B  ] 
 
-----[A=B]----[MOV A-B]
   a-[A  ]  3-[A     B]-b
8000-[B  ]
 

Similar Topics

Hi All, I am currently at the beginning of a new project for writing a PLC program (using CCW) for an old sugar centrifugal. Most of our...
Replies
3
Views
1,985
Hello All I am new to the forum and also to the world of PLCs. I would like to have your expert advice, If I can change the floating point value...
Replies
15
Views
5,768
Hello What would be the best way to write a value into "Source B" of a GEQ SLC500 PLC instruction from Wonderware? I would like the operator to...
Replies
2
Views
1,784
I am new to this line of work so please excuse me if this is extremely simple. I have also Searched the forums and web for answeres and am getting...
Replies
1
Views
1,270
Hello, I am trying to make a sequence program by using MOV function to change the value of a register. So far I have always used SET and RSET for...
Replies
5
Views
2,194
Back
Top Bottom