Unstable ADD operand

new2abPLC

Member
Join Date
Nov 2008
Location
everett
Posts
2
Hi,

I have a photo eye that will be used to trigger counts for products passing by on a conveyor belt. Instead of doing a count, I would like to do an ADD operand to keep track of the number of products. However, when I do a 'toggle bit' instead of adding 1 to the value, it adds random large positive values. I used an ONS but it doesn't just add one. Why? Or what can I do so it only adds one each time a product passes by? Thanks.

----]PE[--[ONS]-----|Add|--
 
Welcome to the Forum


First, please let us konw which processor you are using. There are some slight differences in the one shot instructions between processor lines.

Also, is it possible that the photo eye is getting triggered multiple times when the product passes it?
 
Norm states 2 good points. You may need a PhotoEye delay time so that you only trigger the add instruction once, then have to wait a time period (minimum time until next product) before triggering the add instruction again by the photoeye.
 
I suspect it may be Omron - if so, only add on a rising edge - place an @ symbol in front of the ADD function.

Alternatetively, use @INC - increment used on a rising edge.
 
I'm using AB RsLogix5000; I assume that by 'toggling bit' it means it should only enable 1 bit...anyways, I really appreciate everyone's response! I was struggling with this for quite a while and figured out that I used the same ONS twice at two separate rungs...and it wasn't happy hence it jumped all over...craziness...oh well...lesson well learned! Thanks peeps!
 

Similar Topics

It takes a minute or two just to open, I think this is from the license checks. After it is open it takes like 5-10 minutes to upload a 2.5MB...
Replies
1
Views
1,198
Hello all! I am trying to figure out how to tune PIDE for an unstable heater. This is a startup tuning. My project was to remove old temp...
Replies
5
Views
3,230
I'm fairly new to the world of PLC's. So far I've managed to resolve the problems I've crossed but this one has me stumped. I've got a Rotork...
Replies
6
Views
3,828
Hi, I am doing I/O testing on a new installation. My Kiesselmann valves on ASi are not opening when I give the open command. I can see from the...
Replies
6
Views
1,789
Dearall, I am using a Delta SS2 PLC with 6xa analog card, [ TO K0 K1 H480 K1] using first two analog inputs ans 0~10 v dc input and rest of the...
Replies
2
Views
1,859
Back
Top Bottom