Servo positions not updating.Could you please explain this code ?

Rob S.

Member
Join Date
Sep 2008
Location
Maryland
Posts
739
Good Afternoon ,

We have a new machine from Italy , and for some reason , the servo actual positions quit updating on the HMI. I looked at the tag in the "connection" tab in Numeric Display and it is
{[CLX]HMI.Scope.Recipe_Par[153]}.

I thought it was going to be simple , till I looked at the code below. I
know it not the easiest to read , the way I have it. What do you think the S:FS Bit stands for in a ControlLogix ? It may be that this bit is not true. Where would I see this. Also attached is another piece of code , that a cross reference of that HMI tag showed ?

What is a SIZE instruction used for ?

Thank you so much for your help. Why is code written so difficult sometimes :( ?

// Inizializzazione parametri all'accensione
// The below program initialises data to desired power up values. This only runs on S:FS Bit.
IF S:FS THEN

MAN_AX_LAST :=32;

// Tutti i parametri di ricetta invisibili
// All recipe parameters Not Displayed
FOR INDEX:=0 TO (MAX_MACHINE_PARAMETERS_NR-1) BY 1 DO
HMI_CONFIG.RECIPE_PAR_MIN_VALUE[INDEX] := 0;
HMI_CONFIG.RECIPE_PAR_MAX_VALUE[INDEX] := 0;
HMI.SCOPE.RECIPE_PAR[INDEX] := 0;
END_FOR;
 
Rob:
This info comes from help :

Size:
This information applies to the CompactLogix 5370, ControlLogix 5570, Compact GuardLogix 5370, GuardLogix 5570, CompactLogix 5380, CompactLogix 5480, and ControlLogix 5580 controllers.

The SIZE instruction finds the size of a dimension of an array. This instruction can also operate on a string where it returns the size of the DATA portion of the string.
 
What do you think the S:FS Bit stands for in a ControlLogix ?

I have never worked with ControlLogix, but something tells me it could be a System:First Scan? That makes sense as the code inside of the IF structure seems to do some initializations.
 
Thanks for your thoughts and information. Where would I find this S:FS bit in the program . I recall seeing something similar in RS Logix 500 ( SLC ) in the controller folder . I will check online today , and see if it is in the processor folder. If that is a condition to make those positions update , is it a bit I can force ?.

Thanks again
 
No S:FS can not be forced.
If you want to check it just modify your program to make s:fs to add 1 to a number you know is constant.
Every time you restart your plc that number will add 1 to itself.
 
The S:FS bit is just being used to clear out the recipe when the PLC is first powered up. This will stop the end used from running whatever recipe was loaded when the PLC was last powered up. So if for example, Bubba doesn't want to look for the real problem and tried the great cure all of cycling power to the processor, the program will force you to reselect the recipe you want to use. Elsewhere in the code are the instructions for selecting what recipe to load into memory.


Bubba.
 

Similar Topics

Hi People, I've had a two servos working in tandem for about 2 years now and the company say they are not happy about having to reteach them...
Replies
7
Views
2,108
Is it possible for me to tuning 2 servo at the same time, because this servo is connected by mechanical so I'm afraid that I need to tuning them...
Replies
3
Views
98
Hi all, New here and new all round to PLC`s. We have a servo drive that runs a cross travel beam backwards and forwards. I am having trouble with...
Replies
3
Views
134
My servo motor instruction is not being executed on the gx works 3 even after the positioning parameters have been set
Replies
0
Views
114
Back
Top Bottom