Micrologic Counter

fredjohns

Member
Join Date
Dec 2008
Location
Pennsylvania
Posts
119
We have a machine that has a Micrologic 1000 in it that controls a display panel. Once of the things on the display is the machine count. The machine use to run at a maximum of 30,000 pieces a day and everything was fine. Now the speed has been increased and the machine runs between 60,000 an 70,000 pieces a day. In the micrologic program they were useing a counter to keep track of the machine counts and the diplay got its count from the ACC value of the counter. Now once it gets to around 34,000 or so, the counts start going backwards and I am assuming that is has something to do with the counter not being able to go above a certain number. Is there an easy fix if we want to count up to 60,000 to 70,000 counts now and not have it start counting backwards.

Thanks
Fred Johns
Day Timer, Inc.
 
It's the classic 16-bit Signed Integer limit.

A standard 16-bit Integer value in an SLC or MicroLogix controller (and in many other platforms too) uses the highest bit for the Sign, so there are 15 bits to encode the value.

2 to the 15th power is 32768. Start counting at zero and you'll find your range is 0 to 32767. This value is ingrained in every PLC programmer's subconscious.

A standard Counter can only use Integers, so the maximum value is definitely +32767.

First let's see about the message display. Can it be set up to display an "unsigned integer" ?

We're either going to try to fool the Counter into doing unsigned counting, or go to using a oneshot and a "Add 1" instead of a counter. The MicroLogix 1000 has a nice stable OS but it's definitely limited in its datatypes.
 
What brand and type of software is the HMI display ?

This might be very easy if it has the ability to change the Data Type from "Signed Integer" to "Unsigned Integer".

Do you have access to the editing software for this HMI ?
 
How accurate does your counts have to be?
You could use 2 counters and every 10 parts count up by 1.
Each time you get the done bit from the first counter, reset it and add 1 to the second counter.
On your screen add a note about multiplying displayed counts by 10 to calculate real counts.

You should also be able to display both counters values to the HMI and let the operator read the 10's unit and the 1's unit and add them together.
EX: first field displays 50, second fields display 6. Total would be 506. You may be able to get the fields close enough so they just need to read the total.
This will all depend on your HMI.
 
Yes, that is one of the options we were thinking about, using two counters, first one to 1000 an let it reset it self and increment the 2nd count and have the display made up of the ACC values of both counters, one after the other so it looks like one number but just wanted to see if there was a quick and easy fix before we did that
 
It is a Automation Direct CMore Display and Automation Direct CMore programming software and we do have access to the programming software.

Fred
 
Aa Ken pointed out, your limit is 32767.
The 1000 doesn't support floating points.
The only other option would be trading out the 1000 with one that does support floating points.
 
I've only used CMore once but I do think they support Unsigned Integers.

Check that... I used four C-More terminals on that job. Three that ended up in the trashcan and the one that survived the punishing indoor, air-conditioned control cab environment with the filtered power and the screen protectors.

MicroLogix 1000 Counters will keep on counting right past their Presets and even right past the integer maximum; they just use the 16th bit as an ordinary part of the magnitude.

All the displays and math inside RSLogix 5000 treats it as a negative number, but if your HMI is configured for 16-bit Unsigned Integer data type, then "-15536" in the C5:0.ACC field will show up as "50,000" in the HMI.

This still only gets you to the Unsigned Integer maximum, which is 2 to the 16th power, which is 65535. You said that your maximum values are now somewhere above 70,000.

This suggests the "two counters" approach, using one for the 1000's or the 10,000's.

Modern PLC's are typically 32-bit and can use 32-bit Signed and sometimes Unsigned Integers natively, but the SLC operating system used in the MicroLogix 1000 dates from the 1988 design of the SLC-5/02 and the MicroLogix 1000 model controller hasn't been updated since 1997 or so.
 
Ok, thanks for all your help guys, as always I can always count on your guys to help me out. I will just go ahead and have them program in a second counter tonight in the PLC and also on the HMI display so it will so 0-999 on one of them and then just increment the 2nd one everytime the first one gets to 999
 
My typical solution is instead of using a counter instruction, use an add statement and a one shot to condition the i/p logic. Then use two words to hold the total count value for display. For example, one integer to hold values up to 9999 and then 'roll up' values past that to a second integer: N7:0 holds the 1st 4 digits and N7:1 to holds the next four. Not sure about the Cmore panels, but most displays you can put two numeric displays close enough that a viewer won't know the difference.
 

Similar Topics

Dear all, Currently i'm working with micrologic 1400 cpu and Temate G5 Controller. I plan to communicate micrologic with temate using...
Replies
0
Views
399
Hi All, I am looking for Modbus Communication Address register details for Schneider ACB Micrologic 6.E0.. We are trying to communicate with AB...
Replies
0
Views
377
I had a question regarding the Micrologix 1400 AI/AO's. I have a 4-20mA AI wired to an input channel (I:3.0) and I am moving that value to an...
Replies
5
Views
1,069
Hello Ken Roach, Thank you for your quick reply , As informed earlier i want to read P&F Sensor data on Micrologic 1400 series B using MSG...
Replies
17
Views
5,787
So I have to encoders with A,B and Z pulse 360 encoder wired up to A0+, B0+ and Z0+ and the - pulses wired to common 24vdc. I can see the inputs...
Replies
0
Views
1,037
Back
Top Bottom