logix5000 verify process ascii string against array?

Mark Gleason

Member
Join Date
Apr 2006
Location
Wisconsin
Posts
3
Greetings,

I am currently working on a bit of code reset a work cell after a specific fault. It will be the scanning of a supervisors barcode to reset the fault in question.

My quandry: How to take the input ascii string from the barcode scanner and compare it to an ascii array of authorized supervisors in order to process the reset (without hundreds of compare blocks)?

5000 L63 version 13
 
Use a For/Next loop to index through the array one at a time. If the input string == that string of the current array position or if you reach the end of the array, exit the loop.
 
Fsc

In RSLogix 5000 there is an instruction FSC (File Search and Compare). This will do exactly what you want it to do. Just go to the online help and type in FSC to see the example of how to use it. One instance of the instruction will perform the function you are looking for.
 
Every time you loop through the For/Next loop you will increment the 'index' number by one.

You will use the same instruction as if you had a hundred separate instructions, but instead of addressing each element of your array directly like AuthorizedSupervisor[0], AuthorizedSupervisor[1], you will use AuthorizedSupervisor[index].



I agree the FSC seems like a better approach.
 
Last edited:

Similar Topics

My apologies if it is something to basic or simple, but I'm pretty sure the 'Verify controller' button in RSlogix 5000 was always on i.e. I could...
Replies
1
Views
2,077
After I open a project in RSLogix5000, how do I verify the project with the program resides in the Contrologix controller ?? Other PLC software...
Replies
6
Views
3,943
Hi! So my problem is a little funky, I had Studio 5000 v 24 and 30 installed, but forgot to install RSLogix (which I cannot go without). Is there...
Replies
2
Views
89
So I had an odd request from a customer for the above. I have written the logic and tested it all in one PLC with only using 7 outputs and 7...
Replies
15
Views
423
I'm a Siemens person, and this is one of my first AB programs. The customer wants everything programmed in Ladder. I have a lot of data (3...
Replies
14
Views
213
Back
Top Bottom