FORUM CTRLX AUTOMATION
ctrlX World Partner Apps for ctrlX AUTOMATION
11-06-2023 09:42 AM
Hello everyone,
here i have attached XMl file of my program file, prevously i have used case for programming to move next case. but i am not able to jump to next case instead of signal toggle between true and false after completing first case.
basically i have made program for 10 point for continous cycle but it only works for perticular 10 point if i only add 5 points instead of 10 then this is not working, therefore i have used case but as i mentioned above case is also not working for random points between 1 to 10. if there any alternative to perform perticular task.
Solved! Go to Solution.
11-06-2023 02:56 PM
It's quite hard to figure out what you're trying to do.
But I cant find any assignment to the case, for instance point[3]
I usually write sequences in ST like this
CASE Point[3] OF
1:
MoveLinearAbsolute[3](ExecuteCmd:= TRUE, ...);
IF MoveLinearAbsolute[3].Done THEN
MoveLinearAbsolute[3](ExecuteCmd:= FALSE, ...);
// Move to the next state
Point[3]:= 2;
END_IF;
END_CASE
But a tip is to use named enumerations for the case, makes it much easer to debug:
https://alltwincat.com/2021/11/16/local-enumerations/
11-07-2023 08:07 AM
Thank you for your Email.
It is robot programming for 10 position which you see in attached XML file and it is completly working continue in cycle. I want to run this program from HMI . There is 10 position pre fix right now and now i want to run 5 or 4 or 3 position instead of 10 position from HMI So according to that, which type of changes i have to do programming.
11-16-2023 09:53 AM
For me the key question is which data is given by the HMI and so the customer?