shifting data conveyor

atvracer

Member
Join Date
Jan 2015
Location
Oklahoma
Posts
16
I'm working on a conveyor type system where i have a part moving on a conveyor that i measure the length with sensors puts the floating point data in F8:2 RSlogix 1100 no problem there. now i want the data to fallow the part down the conveyor
like you do with Bit shift right BSR but instead of a bit i want to do a complete data file
then i can display the file on a HMI also eject the part in the right bin that matches the length
 
File shift

More Elaboration,

File shift could be achieved by copying(or in some processors file copy (MVF) data from N7:1 into N7:0 with a length that can fit your need.

Best regards
Hagos
 
If there are 80 pulses of an encoder for the entire length, then create an integer or floating point array 100 long.

I've seen a few methods from here, one would select an entry point and exit point and shift the entire array every pulse.

Another would include a counter which would go from 0 to the max and continuously loop. You know that the item will pop out 80 pulses from when it goes in, so add 80 to the current count and place the number for the length there, every pulse you check the location in the array.

For example, a component is 134.6 when the length is detected, at your entry time when you want to store this your counter is 53, 80+53 = 133, your array is 100, so place 134.6 in the array position 33, your counter on every pulse will increment, when it reaches 101 it is set to 1, finally it gets to 33 and you pull the data.
 
It sounds like you're looking for the FFL & FFU instructions. You can use these on an array of UDT or other data type.

The only issue I've found with this method is that you cannot choose the direction the data flows in the array (if I remember correctly)
 
A FIFO (FFL and FFU) together is the way to do what you want but you can not use floating point data type (F:0)
FIFO only supports Integer data type (N:0)
so you will need to convert your Floating point data to integer type.
 
A FIFO (FFL and FFU) together is the way to do what you want but you can not use floating point data type (F:0)
FIFO only supports Integer data type (N:0)
so you will need to convert your Floating point data to integer type.

FIFO's are not good for tracking, the only time I've used FIFO's is if it is coded in a way to detect missing objects and throw away the data.

You have to track properly, a FIFO does not do that in itself.
 
FIFO have been used for years for tracking
FFL and FFU output instructions are used in pairs. The FFL loads words into a user-created file called a FIFO stack on successive false-to-true transitions of the rungs controlling input logic. The FFU (FIFO Unload) unloads words from the FIFO stack in the same order as they were entered.

This instruction is helpful in applications where it is necessary to load and unload values in the same order. An example might be tracking parts through an assembly line where parts are represented by values that have a part number and assembly code

read the instruction help the RSLogix 500
 
Gary, I assure you, after working in Airports for many years, using a FIFO as you say is a big, big no no.

Objects come together, objects go missing, arbitarily expecting the next object seen as the one placed in a FIFO is a recipe for disaster.

Accurate tracking is done using some sort of encoder which creates a pulse and the objects being tracked, normally just the leading edge of the object, is moved in some sort of array.

When you detect the object at the next sensor it must be expected within a time window, if an object takes 20 seconds to get from one sensor to the next and the next sensor detects an object 10 seconds later, it is not your object, if its detected between say 18 and 22 seconds later then its a good chance its your object.

Assuming the first object seen, no matter when, is the first one put in is not the way to go for accurate tracking.
 
I will stand by the FIFO for your project
I don't think you understand that you can manipulate data anyplace in the data table
you can clear data or change it at any point within the FIFO
use the encoder to trigger / step the FIFO Load Unload the positions will be the same
the data will be stepped along the table.
if the step with the data is at the sensor and the sensor fails to read the object then clear the data at that step.
you can write your own file move an remove but you are only doing what the FIFO dos with far less coding
 
then i can display the file on a HMI also eject the part in the right bin that matches the length
OP states he wants to display the shifted data. This is trivial with a shift register structure as a given stage of the register will consistently match up with a physical point on the conveyor (assuming it's encoder driven). How would this be done with a FIFO?
 
you would display the table (array) the same as you would any table (N7:0 - N7:100)
In a FIFO it fills from the top down 100,99,98.......4,3,2,1,0 after it loaded or
Set the control position to load at 100 it will load top down.
On every encoder pulse load and unload and place /clear data in the table at any desired position
 
cool thanks i got some good stuff i can play with this weekend

i also i have a correction my system uses a stepper motor to drive the belt so i count the out going pulses put it in N7 not F8 sorry then i do a little math converting the pulses to length and putting it into the F8 so i can do all of my shifting using N7's

thank you ill let you know what i did and my next roadblock
 
why go through all that keep it simple
1. figure out the number of steps for the stepper per inch this will give you the length
count the pulses in a counter with the preset counts set counts per inch
use the counter DN to stem the FIFO
number of steps in the FIFO = conveyor length
read the date at the downstream scanner, scanner = data object in true
 

Similar Topics

Hello specialists! I am little bit concerned about transferring 4 chars to data block every time we receive positive edge. The thing is, I would...
Replies
2
Views
2,222
Hello all, What I want to do is take a word of data and move the bits over 1 bit. So to keep it simple: 0001 0011 1100 0110 and move into...
Replies
2
Views
1,513
Good day all! I am using a compact logic controller, L16ER, and I have an 8 position rotary table. I will try to explain the table positions as I...
Replies
5
Views
2,201
Hello, Im trying to shift 110 bytes of data down by 10 bytes within the same datablock (data block is actually 110 bytes in size) so im...
Replies
20
Views
11,275
Hi! I have an array of 300 part numbers (each is an ascii string of 2 DINT in size). I need to display the top part number at the first station...
Replies
7
Views
4,472
Back
Top Bottom