Compare register from one scan to another scan

lostpatrol1

Member
Join Date
Aug 2002
Posts
67
Anyone know how to do a value scan from one scan to another scan? Using Micrologix 1500 PLC?

By that I mean, i.e. I store a value HSC:1.ACC to N7:1 (this scan), then next scan I compare HSc:1.ACC to N7:1 which was stored at the previous scan.

Thanks.
 
Put compare instruction on rung before store instruction rung.
Rung one compare
Rung two store
Mickey
 
Sorry 'guest', that would cause them to occur on the SAME scan...

Lostpatrol,

One possibility would be to:
A.) Put the compare before the store
B.) Trigger a one-shot (OSR) after your store
C.) Use this one shot on your compare instruction

IOW:

| Existing 1-Shot
|----] [-----] [-----------[COMPARE]
| Existing
|----] [-------------+-----[STORE]
| |
| +-----[OSR] 1-Shot


.
(pardon the double-spacing)

This will inhibit the compare until the following scan.

beerchug

-Eric
 
I think GUEST had the interpretation correct. I think LOSTPATROL1 wants to work on any possible change from rung-to-rung.

Doing a comparison between the current value and what was stored on the previous scan on one rung then, on the next run, performing the store, would accomplish this.

We have a situation where we recieve counts to a High Speed Counter and store the number of pulses received duing the previous scan in this same manner.
 
lostpatrol1 said:
Anyone know how to do a value scan from one scan to another scan? Using Micrologix 1500 PLC?

By that I mean, i.e. I store a value HSC:1.ACC to N7:1 (this scan), then next scan I compare HSc:1.ACC to N7:1 which was stored at the previous scan.

Thanks.

MOVE HSC:1.ACC to N7:0----------| This Scan
EQU N7:0/ N7:1 ------------( )--|
MOVE N7:0 to N7:1 V-------------| For the Next Scan

Thats for if HSC is Timer !
 
Thansk all...got it..

Kudos to Kim Gold

For those who want to know what I ended up...this is what I did

first rung, read the HSC1 Acc and subtract to N7:8 which at this poing, N7:8 is 0

do my logic...then move HSC1 Acc to N7:8

On next scan, HSC1 Acc (current) subtract N7:8 (previvous HSC1 ACC) and do my logic.

Thansk again!
 
Last edited:

Similar Topics

Help please. Im new to Omron and have a machine down. I have a compare = for barcode label scan. I've attached two pics. On the Mnemonics you can...
Replies
4
Views
602
Hi everyone! Accidentally closed it and it wont appear again. Checked and unchecked the option and seem to make no difference. Running v7.10.00...
Replies
16
Views
1,815
I'm working on an array that contains a UDT of 5 Items Array[4] DataType[0] - Part 1 - Part 2 - Part 3 - Part 4...
Replies
1
Views
814
Hi. I have 2 files where I would like to see the ladder logic differences (similar to the Rockwell compare function). I am using TISoft Siemens...
Replies
1
Views
1,228
Hello experts, I am just starting with AB programing, I have a questions regarding a compare done in an old RSlogix500 and causing me issues when...
Replies
5
Views
1,913
Back
Top Bottom