FFL Instruction

Jim-F

Member
Join Date
Nov 2007
Location
WI
Posts
11
I've been reading a LOT of the past topics, and A-B Knowledgebase, on the FFL/FFU instructions, but I still don't understand a couple of things.

Can you use the FFL instruction by itself, or is it mandatory to use the FFU with it as a pair? As long as you reset the ".POS = 0" when the FFL is done, then wouldn't it just continue to overwrite the existing data elements within the array?

If you have to use the FFU instruction, then do you also have to reset the .POS of the FFU?

Is the length of the FFU the same as the FFL, or is it the length of the DESTination? I will be unloading a 30 element DINT array into a single DINT waste tag, so I don't care if it is overwritten.

Here's what I have set up so far in the FFL/FFU instructions. Screen captures can be done if needed.


FFL:
Source A450 KW Total
FIFO A450 KW Total Array[0]
Control A450 FFL Control[0]
Length 30
POS 0
FFU:
FIFO A450 KW Total Array[0]
DEST A450 FFU Destination
Control A450 FFL Control
Length 30
Position 0
I'm copying the Total Array to a buffer array each time, and sorting that to perform other functions, so if I don't have to unload the FIFO, then it would make things a lot easier.
 
Can you use the FFL instruction by itself..? ANSWER: YES

or is it mandatory to use the FFU with it as a pair? ANSWER: NO

As long as you reset the ".POS = 0" when the FFL is done, then wouldn't it just continue to overwrite the existing data elements within the array? ANSWER: YES

If you have to use the FFU instruction, then do you also have to reset the .POS of the FFU? ANSWER: When you use them as a pair (normal way), then you do not have to reset the Position. It counts down as FFU unloads the file.

Is the length of the FFU the same as the FFL, or is it the length of the DESTination? ANSWER: It is whatever value is in the "Length" parameter of the FFU, and normally that should be the same as the "Length" of the FFL. If you are not using the FFU, then it's Length will not be relevant. Normally, the "Control" location is made the same for both the FFL and FFU, so that they share the same Status bits, Length, and Position values.

Here is a demonstration program that shows you can use FFL without FFU, and that you can reset the POS word.

FIFO_DEMO.jpg
 
Last edited:
Lancie1: Thanks for the help. After reading about using them as pairs, I just couldn't see the need for the FFU in my application, and looking at the control flowchart, it seemed like the FFL could stand alone.

Thanks for the verification and the ladder logic. 🍻
 
Whoa gentlemen.

Use a COP instruction instead of the FFL/U. Just copy
from the top down (ie. copy from element 1 to element 0).
The copy length is the length of your queue.

Simpler, cheaper, faster...

Good to be back

(8{)} :) .)
 
welcome back, Yosi ... where've you been? ...

to Jim-F ...

what Yosi is getting at is that the FFL/FFU instructions are ideal for the use for which they are intended ... and as Lancie1 has said, you certainly can use just the FFL by itself ...

but ...

most of the time when people are trying to use just the FFL alone, it's because they're trying to store data into memory locations and then shift that data up or down step-by-step ... sometimes this is called a "ripple" effect ...

while the FFL certainly CAN do this, most programmers eventually discover that the COP approach recommended by our friend with the cryptic name is an easier way to handle this operation ... the topic has been covered before on the forum ... let us know if you're interested and we'll post a link or two ...

if not, then party on with the FFL ...
 
We use FFU/FFL pairs a lot to track production orders through our process. It's a linear process so the FIFO FFU/FFL setup works well for us. Ron, I'm interesting in learning more about how you fellas use the COP command. Would you mind posting those links please?
 
Yosi: I tried using the COP commands, and I can see how it would work, but initially I messed it up somewhere, and started looking at the FFL/FFU.

Ron: I've been through most of the COP and FFL/FFU after doing searches on both. I've read a LOT of your postings, and have to thank you for taking the time to share your knowledge with those of us that are new to the PLC world. Sometimes I read too much and start getting things confused.

I came in this morning and started working through the ladder logic, and I got the CLR for the POS set up, removed the FFU, and some other tweaking. When I was all done, I let the logic run and waited for the cycles to get the POS>LEN and the DN bit to set.

When I saw it all work as planned, with everyone's help, I was elated. This PLC is the central processor for our entire steam plant, and if it were to have a major fault, it would be a very bad day around here. Now all I need to do is build some RSView screens, and display the data I'm collecting now.

Thanks to all 🍻
 
Thanks for the link Ron. That makes sense.

EDIT: For those who've already read my long winded reply. Never mind. I answered my own question. I should read more carefully before replying!
 
Last edited:

Similar Topics

EDIT: I suppose i should mention, RSLogix 500 V8.40, SLC 5/04 (1747-L542C) Is there is a way to use the FFL instruction in a way that doesn't...
Replies
4
Views
864
We are converting an RSLogix5 PLC code to Siemens S7. Looking for the S7 instruction that replaces RSLogix5 FFL instruction.
Replies
5
Views
2,324
Could someone please show me how AB FFL/FFU works in RSlogix 500. I can get data in the FFL just can`t get it out.:shock:A small sample of code...
Replies
3
Views
12,800
I'm having trouble finding the control block length for the FFL instruction, and I'm really not sure how to find it. On the component it lists...
Replies
2
Views
4,111
I have a project that is loading pallets into 10 test bays and then unloading them when the test is complete. I am using an array to store which...
Replies
3
Views
170
Back
Top Bottom