Strange ControlLogix scan prob

TimeFluxCap

Member
Join Date
Nov 2002
Location
Australia
Posts
321
Hi all

I came across an interesting prob with a new CLX program I wrote the otherday.

I used a DINT word named Internal_Bits to be be used in the program as internal coils and bits. I had the problem of the logic before a coil named Internal_Bit.9 being true bit the coil was not going true. I did not have a problem with any of the other coils from the internal_bits DINT. I simply replaced the coil coil with a new variable BOOL and it worked.

I searched the program and nothing was trying to overwrite the same address.

If anyone has a suggestion as to why this would happen pleae add your comments.
 
Is the program being scanned?

Right off the top of my head thats the only thing I can think of, as you say nothing else is overwriting it. Its very late here so maybe someone else will have another idea.

Make sure the program is listed on the task (right click the task in the project tree, click the program schedule tab, and make sure the program is listed as scheduled.) Then make sure the program's main routine is defined. Right click the program in the project tree and make sure that the main routine is defined. Make sure inhibit program is not checked and if you are online you can observe the scan times.

If in doubt, a quick and dirty way to test if a routine is being scanned is to put in an unconditonal ADD instruction.
ADD dTestTag 1 dTestTag
and then monitor dTestTag to see if it is changing.


Just a suggestion for you to consider, its just a matter of personal style:

I often will create a boolean array B[128] (sized as needed) for general purpose internal bits. Boolaen tags, even though they only require one bit, gobble memory in 4 byte chunks, but when defined in an array (or grouped in a UDT) they are contiguous, so B[128] occupies 16 consecutive bytes. A DINT gives you just 32 contiguous bits, and you could do DINT array to get more, but then it does not address as smoothly as a boolean array ( B[34] -vs- I[1].2 ) . I usually create several boolean arrays with appropriate names, such as OneShots[64] as well, for the same reason.


edit:
Ok now I know it's getting late. I didn't clue in until I read back over the thread after my reply that you replaced bit 9 with a BOOL tag and it worked OK, so apparently the program IS getting scanned.

Maybe you could post the program and we all can take a look at it.
 
Last edited:
Alaric, the routine was definitly being scanned.

Phillip, I wil give that a go. Like I said in my original post I used a newly crerated BOOL coil and it worked fine.

The program is on my memory stick at work. I will post it up and see if you can pick it, I cant see anything overwriting it, but I have been hit with blindness before.
 
I would check to make sure no HMI writing to this bit or word.
It may happen by acceident if that someone wants to display this tag and accidentlyu uses it as a pushbutton.

Also make sure that this tag is not overwritten by any other PLC with MSG or Produced/consumed

And the last thing - make sure no computer writes to it.
 
TimeFluxCap said:
...I have been hit with blindness before.

Haven't we all.

Thats one of the reasons forums like this are great. I think there are many like myself who are the only control engineer/programmer in their company, and sometimes its nice to be able to find someon who can put a second set of eyes on a problem or suggest a different way to do something.
 

Similar Topics

It has been a while since I have used RSLinx extensively, but I do not remember ever seeing anything like this. We have a customer whose C-more...
Replies
0
Views
3,653
It has been a while since I have used RSLinx extensively, but I do not remember ever seeing anything like this. We have a customer whose C-more...
Replies
7
Views
5,267
Hello all, I am facing an issue with my Commander SK that I cannot solve on my own, I am struggling on it since several days :confused: The...
Replies
9
Views
1,044
Hi. I'm doing an upgrade of an old 1400e to a new panel view plus 7 standard using ftv studio v 12,which will be communicating to a slc 5/04 via...
Replies
15
Views
2,626
Can someone explain the jumper between the elements? Does it do anything? See attached jpeg.
Replies
4
Views
686
Back
Top Bottom