- LinuxCNC
- General LinuxCNC Questions
- How to dynamically switch one ethercat servo motor from spindle to axis ?
How to dynamically switch one ethercat servo motor from spindle to axis ?
04 Jul 2024 01:52 - 04 Jul 2024 09:03 #304352
by timaer
Hi,everyone,I've configured an ethercat controlled servo motor as a spindle with hal,and I was able to config it as a angular axis too .But ,now the demand is to switch it from spindle then the A angular axis dynamically,I dont know how to achive this.I've read about sample code in linuxcnc called millturn,but a little complicated.The problem seems that if there is a way to dynamically switch from a spindle to joint or joint to spindle in hal.I read about cia402 comp doc ,saying it's not possible for security reason.So,I dont know ,what is the best solution for a turn-mill or mill-turn machine.Because it need using one servo motor as both a spindle and an axis.I've added my hal in the attachment .Could anyone give me some advice how to make it in linuxcnc ? Thanks.
Last edit: 04 Jul 2024 09:03 by timaer.
Please Log in or Create an account to join the conversation.
07 Jul 2024 17:25 #304587
by andypugh
Replied by andypugh on topic How to dynamically switch one ethercat servo motor from spindle to axis ?
If the spindle is controlled with velocity commands then it may be just a case of switching to a position PID (which still outputs velocity commands)
wiki.linuxcnc.org/cgi-bin/wiki.pl?SpindleOrient
wiki.linuxcnc.org/cgi-bin/wiki.pl?SpindleOrient
The following user(s) said Thank You: timaer
Please Log in or Create an account to join the conversation.
08 Jul 2024 01:28 #304620
by timaer
Replied by timaer on topic How to dynamically switch one ethercat servo motor from spindle to axis ?
Thank you ,andy. I'm using a servo motor as the spindle,and it is controlled by linuxcnc-ethercat.I dont know if it is satisfied for the condition to use the Orient component.I 've read the link you provided,but the final output seems to be VFD,is it compatiable with ethercat's control mode ? In fact ,I only want the servo motor to be acted as both spindle and c-axis,it can run the G-Code ,such like M3 S1000 for spindle ,and also G0 C100 for axis move. I dont know if using Orient component is the solution for it ,hope to recv more info to done it in linuxcnc.
Please Log in or Create an account to join the conversation.
08 Jul 2024 04:36 #304630
by Aciera
Replied by Aciera on topic How to dynamically switch one ethercat servo motor from spindle to axis ?
Possible solutions will depend on the hardware you are running, so you might want to ask this question in the EtherCAT section.
The following user(s) said Thank You: timaer
Please Log in or Create an account to join the conversation.
08 Jul 2024 05:08 #304634
by timaer
Replied by timaer on topic How to dynamically switch one ethercat servo motor from spindle to axis ?
Thanks.I'll post a question in Ethercat section then.BTW,if without considering the hardware condition,what will be the best solution for my requirement? To buy a PWM or VFD motor and using Orient component ?
Please Log in or Create an account to join the conversation.
08 Jul 2024 07:54 - 08 Jul 2024 07:59 #304641
by Aciera
Replied by Aciera on topic How to dynamically switch one ethercat servo motor from spindle to axis ?
I wouldn't use a VFD for a C-axis. A VFD might be able to orient well enough for a tool changer but the dynamics and precision of a rotary axis are much higher and a servo motor would certainly be my choice.
There is also a video in german:
forum.linuxcnc.org/10-advanced-configura...able-issues?start=20
I have successfully used a servo motor for this in an experimental setup. In that case I dynamically switched between step/dir position command for rotary and analog (0..10V) for spindle velocity. A modified orient component and M19 command was used to rehome the spindle when switching from spindle to rotary mode. In the end the problem was that my servo motor setup was not stiff enough in rotary mode and the motor brake had too much play when engaged.
[edit]
I gather that traditionally there is a motor with belt drive for the spindle mode and a different motor on a worm gear that is mechanically engaged for the rotary mode. Although I would be somewhat surprised if that was still the case on modern machines.
There is also a video in german:
forum.linuxcnc.org/10-advanced-configura...able-issues?start=20
I have successfully used a servo motor for this in an experimental setup. In that case I dynamically switched between step/dir position command for rotary and analog (0..10V) for spindle velocity. A modified orient component and M19 command was used to rehome the spindle when switching from spindle to rotary mode. In the end the problem was that my servo motor setup was not stiff enough in rotary mode and the motor brake had too much play when engaged.
[edit]
I gather that traditionally there is a motor with belt drive for the spindle mode and a different motor on a worm gear that is mechanically engaged for the rotary mode. Although I would be somewhat surprised if that was still the case on modern machines.
Last edit: 08 Jul 2024 07:59 by Aciera.
The following user(s) said Thank You: timaer
Please Log in or Create an account to join the conversation.
08 Jul 2024 08:09 #304644
by timaer
Replied by timaer on topic How to dynamically switch one ethercat servo motor from spindle to axis ?
Thank you ,Aciera.In fact I also want to use servo motor
to be acted as both spindle and axis too. The below youtube link is the final result I want to achive,though the sample hal config in the comment ,I found a little too complex for me :(
to be acted as both spindle and axis too. The below youtube link is the final result I want to achive,though the sample hal config in the comment ,I found a little too complex for me :(
Please Log in or Create an account to join the conversation.
08 Jul 2024 08:18 #304646
by timaer
Replied by timaer on topic How to dynamically switch one ethercat servo motor from spindle to axis ?
Hi,I'v watched your youtube video.It looks that the most of the solution need to use Mesa board.but I'm now using Raspberry pi ,so do I have to buy a Mesa board for achiving the spindle / axis as one functionality?
Please Log in or Create an account to join the conversation.
08 Jul 2024 08:20 #304647
by Aciera
Replied by Aciera on topic How to dynamically switch one ethercat servo motor from spindle to axis ?
Also a bit dated, a fair bit has changed since. Although setting up the spindle orientation is certainly still not the easiest thing to do.though the sample hal config in the comment ,I found a little too complex for me
Please Log in or Create an account to join the conversation.
08 Jul 2024 08:34 #304650
by timaer
Replied by timaer on topic How to dynamically switch one ethercat servo motor from spindle to axis ?
Yes,I quite agree with that. I think both the spindle orientation or the spindle/c-axis for mill-turn functionality are commonly used .It's better to make it easier for using it in linuxcnc.Maybe the developer or the community of linuxcnc should consider to simplify it for the common user.
Please Log in or Create an account to join the conversation.
- LinuxCNC
- General LinuxCNC Questions
- How to dynamically switch one ethercat servo motor from spindle to axis ?
Time to create page: 0.385 seconds