Cancel
Showing results for 
Search instead for 
Did you mean: 

CSE simulation of rotary axis

Valued Contributor
Valued Contributor

Hello

 

I have 5 axis cnc machine at hand, where C-axis rotation direction is determined by sign (+-).

and value is absolute value.

 

How this kind of axis is configured in CSE?

in CSE it always tryes to take shortest path.

12 REPLIES 12
Highlighted

Re: CSE simulation of rotary axis

Valued Contributor
Valued Contributor

Got it half way, only problem remains is how to I take - sign account?

 

I use SetJointRotationMode command  to determine rotation direction.

But I need to distingt between -0. and 0.. 

-0. will rotate CCW to 0 degrees and 0. will rotate CW to 0 degrees.

Sign determines rotation direction.

 

I modifyid C adress to check rotation direction.

Capture.JPG

 

 

So any ideas how can I take this account?

 

 

Re: CSE simulation of rotary axis

Siemens Phenom Siemens Phenom
Siemens Phenom

Hi Jussi,

 

about which controller are we talking here?

 

Thomas

Re: CSE simulation of rotary axis

Valued Contributor
Valued Contributor
Hello

Fanuc based.

It's for my own machine.
Control is LinuxCNC.

Re: CSE simulation of rotary axis

Siemens Phenom Siemens Phenom
Siemens Phenom

Hi Jussi,

 

I might be wrong, but would the mode "normal" do what you like?

With mode normal the joint behaves like a standard linear axis.

 

Thomas Schulz
Siemens PLM
Manufacturing Engineering Software

Re: CSE simulation of rotary axis

Siemens Phenom Siemens Phenom
Siemens Phenom
Hi Jussi,

to find out the sign on the axis value you can use the SGN() CSE function excerpt for 0.
If 0 values should also work you have to do some "crazy stuff" with python. This means you have to evaluate on bit level which sign was programmed. In case of e.g. C-0 you have to create a double instead of integer expression in yacc and later in the metacode definition you have to cast the address value to float type. With this type you get the information (+ or - sign) you need.
With current CSE board tools its not possible.

Thomas

Re: CSE simulation of rotary axis

Valued Contributor
Valued Contributor
Hello.
My background is in low level C programing. But i have never programmed python before.
Except in last training session.

Thanks for a tip. I need to dig into this deeper.
I was afraid that it might take more than first seems.

Jussi

Re: CSE simulation of rotary axis

Solution Partner Experimenter Solution Partner Experimenter
Solution Partner Experimenter

Hello,

I need to switch mode with RTCP

I use SetJointRotationMode but when I go from "shortcut" to "normal" if the current value of my axis is negative, it is transformed into an absolute value.

Example: if my axis is oriented at -90 °, its value becomes 270 °.

Is there a way to avoid this?

in the continuation of the programe there is again a C-90 so the plate makes a complete turn.

Erwan Chotard

Re: CSE simulation of rotary axis

Siemens Phenom Siemens Phenom
Siemens Phenom

Hello Erwan,
I wonder if that might be a separated topics of the previous one. If so a extra thread would be better.

 

But anyhow focus on your needs.

I would like to ask you to describe the behaviour you need before talking about which CSE kernel function to use.
I do see here different facts to clarify.

 

  • the topic is about 5 axis simultaneously RTCP mode only?
  • What are the real (machine tool) rotary axis behaviour?
    unlimited or with limits?
  • what is the NC code you like to simulate and what is the expected behaviour

Looking froward to support you

 

Thomas Schulz
Siemens PLM
Manufacturing Engineering Software

Re: CSE simulation of rotary axis

Siemens Phenom Siemens Phenom
Siemens Phenom

Hi Erwan,

in addition to SpaceToms description... you can influence the RTCP behavior by setup another interpolation type with CSE command 'SetInterpolationMode' (look into the cse doc to figure out which mode is needed)

Thomas

Learn online





Solution Information