sum

sapoleon

Member
Join Date
Aug 2003
Location
salta, salta
Posts
315
hi,
I wanted to know if there is something wrong with the modification that i made a few days ago.
I changed a CPT function in an AB SLC5, that only made the sum of 5 N (from N31:10 to N31:14) to this new format (in the attachment) in which I add only if a bit asociated with the value is checked.

thanks in advance.
 
This display would be correct if conditions changed (something were writing a '1' into N31:25, the values of N31:10 - 14 were overwritten with '0' or the enabling bits (B30:1/0-4) were cleared) somewhere between the execution of this rung and the end of the scan.
 
Looks like values will not be added unless the associated bit is disabled. Should work just fine. I don't know what value or purpose is served by N31:22, it must be the 80% referred to in the comment, but looking at the data ( 0 ) in the destination, N31:22 must contain a zero if this pdf was captured from online data.
 
Last edited:
Guest1 said:
N31:25 is always going to be 0. Look at the start of the rung.

Not true - if any of the bit instructions are evaluated true, then the addition on that branch will happen increasing N31:25 by whatever is in the appropriate N31:10-14 register . . .

Marc



PS: On this scan everything in N31:10-14 is zero, so you are correct for this scan, but since we can't see the controlling logic for these registers, I see no reason to expect N31:25 to always be 0.
 
Last edited:
Given this particular screen capture with the conditions shown - if nothing after this rung were affecting N31:25 then its value should have been '0', but it shows '1'. Thus my comment indicating that, as far as this particular capture is concerned, something else between this rung and the end must have affected the values shown.
 
bernie_carlton said:
Given this particular screen capture with the conditions shown - if nothing after this rung were affecting N31:25 then its value should have been '0', but it shows '1'. Thus my comment indicating that, as far as this particular capture is concerned, something else between this rung and the end must have affected the values shown.

. . . or this rung is not being currently scanned (in a conditional sub / in a JMP / etc.), and in a previous scan, something in one of the N31:10-4 registers was a '1'.

Marc
 
hi,
No the rung was not taken online. It keeps values from the las operation, or god knows from where.
The total number, is the total adition of the times of 5 diferent steps. The times and conditional bits are send with a recipe, and I add them if they are going to use time in the selected step.
Then I use that value, and substract the current time and show in a Panelview the remaining time.
The 80% is used in case of fault, and return to the process, to decide if this particulars 5 steps continue or I jump directly to the next sequences.

Thanks to all for the inputs. Like I said before, just wanted to know if the rung was making the job correctly
 
So - you download your recipe which sets (one or more) of the appropriate bits (B30:1/0 - B30:1/4), and the appropriate times into N31:10 - N31:10-14, then this rung combines that information to get a total time . . .

If I understand you correctly, it should work fine as written. Be careful that the rung is being scanned appropriately and that you aren't adjusting N31:25 elsewhere . . .

Marc
 

Similar Topics

Hi again, I´m still working on the upgrade from 500 to 5000 of this program. I found something that I cannot explain, in RSLogix 500. It seems...
Replies
0
Views
822
First, a background on the equipment so you know what is going on. I have an AB ControlLogix L63 processor controlling some Mitsubishi...
Replies
17
Views
6,020
hello, I am a beginner and also new here, I was reading something about PID loop, there is two tanks , each with a sensor of pH, the control...
Replies
9
Views
3,087
Hello all, I'm trying to recreate the following checksum calculation in the PLC. The example is written in C++ of which I am not very familiar...
Replies
8
Views
3,060
I'm trying to sum the last part of an array starting at element 70 for 30 elements. I placed a 70 in the .POS element of the FAL and it gets...
Replies
66
Views
14,579
Back
Top Bottom