Sub routine concept

PSpal

Member
Join Date
Jan 2011
Location
surat
Posts
52
sub routine concept is quite common and I do understand it...but i just want to clearify some doubt.
in the system there are 20 RFID tag reader and 256 RFID tags. as the RFID tag position before any tag reader , the"scaning ' sub routine called and the 'read" tag compared 256 times.. max..with the "stored" tag to detect which RFID tag is positioned before the reader..so ultimately the "loop" is working for 255 times ..max.. to detect 1 no..and this"subroutine" can be called from 20 different section.The sections are not linked and there is no interlock to prevent multiple reading (from different tag reader but same time)

My question is we are facing a lot of tracking errors.. not related to any particular RFID code..but in general...mostly i found "timing error" ...data not read within certain time...IS IT ANYWAY REATED TO IT..IS IT POSIBLE THAT WHEN THE "SUBROUTINE" IS WORKING TO READ 1 CODE, THE NEXT CALLING GETTING DELAYED,,SPECIALLY IF THERE IS 3/4/5 READING REQUEST AT THE SAME INSTANCE?

we using control logix along with prosoft card..for the same...
 
loop reader
get tag
if tag not same as last reading store the reading and do anything you need, set a flag for the tagchange
else skip reader
as getting info takes a lot of time do not wait for it, but collect all data fast

for reader
if tagchange search a small array in sequence of the tag
( take array(127) if tag < array then number is 64 else use 191
repeat 8 times instead of 256 times.) after 8 loops it has found your correct ID if not it is another tag.

BTW a PLC is not the best solution for this task, maybe an arduino is a lot better for this.
 

Similar Topics

We have a project that has all the routines viewable but not editable. I just want to force a bit high but cant do it. The only way to do so is...
Replies
2
Views
2,840
Good Morning , I'm merging another RS Logix 5000 PLC program ( CompactLogix ) into another . Everything is working great except this one...
Replies
9
Views
3,722
Hello everyone, I am new to ladder logic and am currently working on a small project where I might need some help. So I am modifying the sequence...
Replies
9
Views
2,420
Currently I am using a bunch of TON's and TOF's to start up and turn off a motor sequence. I created a sub routine for the manual sequence and I...
Replies
15
Views
4,707
Hi all, In the past I have use Sub Routines more as a organizational tool for my programs than anything else. I would just put things into nice...
Replies
6
Views
2,537
Back
Top Bottom