Logix 500 Keep adding to register?

nlconner

Member
Join Date
Aug 2008
Location
Minnesota
Posts
7
How can I keep adding a value from one register to another and retain the added number so It keeps incrementing?

Example. I want to add the value of F8:5 to ITSELF every second for one minute.

Not sure how to retain the original number so I can keep adding to it.
 
Explain this a little better please. Do you want to :

1) F8:5 = 1. At 1 sec, add it to itself > F8:5 = 2. At 2 sec, F8:5 = 4. At 3 sec, F8:5 = 8...

or

2) F8:5 = 1. At 1 sec, F8:5 = 2. At 2 sec, F8:5 = 3. ...

Which is it?


The hardest, yet most important part of any automation project is defining what you want to do. Draw this up in a flow chart first ... THEN start programming.
 
Ok. (This seems like a homework/class assignment, so I'm not going to exactly tell you how to do it, but rather am going to try to lead you to a right method... And I say a "right method" because there are many, many ways of successfully accomplishing this.)

What is the "trigger" to execute the command? How does the trigger reset?

What instruction do you need to use to make this happen? (e.g. How are you going to add a value to itself?? Where are you going to store the results?)

Do you have a flow chart yet??
 
I wish it was just a homework assignment!! We just installed a new DA for our boilers... Well the pulse output from the ABB flow meter stopped PULSING.... That made it easier.... I just need a chemical pump to fire every 100gal through the meter. SO I am scaling the 4-20 from the flow meter and taking it to an N register... I want to look at that every second divide the value by 60 and add the result.. BUT I am not sure how to keep from over writing the stored value!
 
Sorry for making that assumption... (That's an awful word isn't it...)

If you're totalizing, don't you WANT to overwrite the stored value?? You're wanting to add the incremental to the total (F8:5), then write the total (F8:5).
 
Correct... I am looking at F8:5 every second... which changes with flow... I can do a move from F8:5 to F8:6 or whatnot... But I want to just keep adding the value of F8:5 every second to a different register... So you are right.. I am totalizing with this. How can I keep adding a value to a single register?
 
Make one of the sources for the addition the same as the destination.

F8:5 is the calculated incremental value (I think)

Total + Incremental = Total

So, make your total F8:6. F8:6 + F8:5 = F8:6
 
SHOOT ME IN THE HEAD!!... Do you ever try to make thing more elaborite then they really have to be??!! I was doing that but was moving my value to yet a different register... Of course it makes total and EASY sense now.. Thanks guys I'll throw it in there & hopefully get good results!
 
That should do it.. Thanks again guys!... I might as well ask another **** Question!! How large can a Floating Point number be before I have to Move a "0" back into the register? I know we are not limited to 32767 using the F register
 
Be a little careful with OZEE's answer. While you have the large range listed you lose resolution much faster than that. This means you cannot add a 'small' number to a 'big' number and have the 'big' number increment. That point comes much sooner than the absolute range limits.

Keith
 
kamenges said:
Be a little careful with OZEE's answer. While you have the large range listed you lose resolution much faster than that. This means you cannot add a 'small' number to a 'big' number and have the 'big' number increment. That point comes much sooner than the absolute range limits.

Keith

For example, if the value you are adding is 1.0 you can't add to more than 16.7 million before you loose the ability to increment by 1, If the increment is .5 or less its about 8 million - this is because you loose resolution in the smaller digits as the floating point number gets larger. About 4 million at .25, and two million at .125 increment.... you can see how it goes.
 

Similar Topics

Good Afternoon, I'm trying to do online edits on a SLC 500 5/05 . After I put my instruction in , I keep getting " Test Edits Failed " ...
Replies
6
Views
3,733
I'm working with a Micrologix 1500 (1764-28BXB)on a machine and I was trying to get it to talk to a panelview 300 micro (2711-M3A19L1) directly...
Replies
9
Views
4,236
Hi Everyone, I am not proficient in RSLogix 500 so I have a question regarding the evaluation of N7:0 data as an input. So as I understand in...
Replies
1
Views
74
I have been working on this for a while now and I can't seem to get it. I was finally able to view the 1500 on the PanelView under the serial...
Replies
1
Views
76
I have a little bit of experience with Allen-Bradley. I have a Micrologix 1500 (RSLogix 500) and a PanelView Plus 7 (FactoryTalk View Studio ME)...
Replies
3
Views
159
Back
Top Bottom