Mill atc configuration

More
03 Sep 2023 11:01 #279711 by Aciera
Replied by Aciera on topic Mill atc configuration
Ah, yes, The problem here is that 'spindle.0.orient' goes through that convoluted logic I mentioned above. So change this:

# M19 trigger orient.enable; orient-pid enable; spinena; select analogout
net spindle-orient <= spindle.0.orient
net spindle-orient => or2.1.in0 #to orient enable
net spindle-orient => and2.0.in0 #to spindle is oriented

net orient-lock <= spindle.0.locked
net orient-lock => or2.1.in1 #to orient ennable

net orient-enable => or2.1.out
net orient-enable => orient.enable
net orient-enable => orient-pid.enable
net orient-enable => or2.0.in1
net orient-enable => mux2.0.sel


To this:


# M19 trigger orient.enable; orient-pid enable; spinena; select analogout
net orient-enable <= spindle.0.orient
net orient-enable => orient.enable
net orient-enable => orient-pid.enable
net orient-enable => or2.0.in1
net orient-enable => mux2.0.sel

I'm not sure if you stil have these lines but remove them if you do :

net orient-complete => and2.0.in1
net spindle-is-oriented <= and2.0.out


Also remove the components 'or2.1' and 'and2.0' from 'loadrt/addf'
The following user(s) said Thank You: Artur_1617

Please Log in or Create an account to join the conversation.

More
03 Sep 2023 11:05 #279713 by Aciera
Replied by Aciera on topic Mill atc configuration
Actually you'll probably want to leave 'or2.1' in the 'loadrt' because of the component numbering you would have to renumber all the ones with a higher index numer.
The following user(s) said Thank You: Artur_1617

Please Log in or Create an account to join the conversation.

More
03 Sep 2023 13:48 #279716 by Artur_1617
Replied by Artur_1617 on topic Mill atc configuration
Now orient.enable after orient is complete is low
But after orient is complete spindle.0.is-oriented is low. Even if spindle stop exactly on orient position.
Still play with orient pid but often after orient is complete spindle turn little and is out of orient.tolerance.
Actual hal
 

File Attachment:

File Name: Frezarka_z...9-03.hal
File Size:17 KB
Attachments:

Please Log in or Create an account to join the conversation.

More
03 Sep 2023 14:35 #279721 by Aciera
Replied by Aciera on topic Mill atc configuration

But after orient is complete spindle.0.is-oriented is low. Even if spindle stop exactly on orient position.

Yes, I think that is the intended behavior  but I don't have a system to actually verify this.

'orient.is-oriented' True -> 'spindle.0.is-oriented' True -> 'spindle.0.orient' False -> 'orient.enable' False -> 'orient.is-oriented' False -> 'spindle.0.is-oriented' False

If you need a signal that stays True after a completed orient then you can use 'spindle.0.locked' which stays True until M3,M4 or M5 command

linuxcnc.org/docs/html/man/man9/motion.9.html

Still play with orient pid but often after orient is complete spindle turn little and is out of orient.tolerance.

Depending on the inertia of the spindle and the spindle drive I would expect that to be a problem and I don't really know how to deal with that if the spindle drive cannot get the spindle to stop quickly enough (unless maybe with a mechanical brake).
The following user(s) said Thank You: Artur_1617

Please Log in or Create an account to join the conversation.

More
03 Sep 2023 15:00 #279723 by Artur_1617
Replied by Artur_1617 on topic Mill atc configuration
Now my Pid working like that. Start M19 R180 which is 114 encoder count. Spindle start turn from encoder count 0 and go to about 125 and start oscilation 125-124, 124-123, 123-122, 122-121, 121-120, 120-119, 119-118, 118-117, 117-116, 116-115, 115-114 and hit orient but past some micro time when relays off and and spindle stop. Sometimes on 113, 114, 115,116
That should work orient?

Please Log in or Create an account to join the conversation.

More
03 Sep 2023 15:14 #279725 by Aciera
Replied by Aciera on topic Mill atc configuration
I'm afraid I can't really help you with the PID tuning but maybe you get some inspiration from this thread:
forum.linuxcnc.org/24-hal-components/458...-solved-yay?start=60
The following user(s) said Thank You: Artur_1617

Please Log in or Create an account to join the conversation.

More
04 Sep 2023 10:31 #279810 by Artur_1617
Replied by Artur_1617 on topic Mill atc configuration
Today try rigid taping but dont working.
Try to make M6 with command G33.1 Z-15 K1
Turn spindle with hand tapping start after hit index  Z axis go to Z-1 after that  Z axis dont move again.
Spindle-at-speed is still High
spindle.0.index-enable After start rigid tapping is set to High but after hit index is set to Low and dont go to High anymore.
 

Please Log in or Create an account to join the conversation.

More
04 Sep 2023 11:45 #279813 by Aciera
Replied by Aciera on topic Mill atc configuration

Spindle-at-speed is still High
spindle.0.index-enable After start rigid tapping is set to High but after hit index is set to Low and dont go to High anymore.

Sounds correct.
I think I may have made a mistake resetting the encoder with the input-index. So remove this:

net spindle-input-index <= hm2_5i25.0.encoder.04.input-index
net spindle-input-index <= hm2_5i25.0.encoder.04.reset

and add this instead:

net spindle-index-enable <= hm2_5i25.0.encoder.04.input-index

 
The following user(s) said Thank You: Artur_1617

Please Log in or Create an account to join the conversation.

More
04 Sep 2023 12:45 - 04 Sep 2023 12:45 #279820 by Artur_1617
Replied by Artur_1617 on topic Mill atc configuration
This we have now in spindle setup   net spindle-index-enable <= hm2_5i25.0.encoder.04.input-index
After delete net spindle-input-index <= hm2_5i25.0.encoder.04.input-index and net spindle-input-index <= hm2_5i25.0.encoder.04.reset
Rigid tapping now working but orient stop working.
Last edit: 04 Sep 2023 12:45 by Artur_1617.

Please Log in or Create an account to join the conversation.

More
04 Sep 2023 13:18 #279826 by Aciera
Replied by Aciera on topic Mill atc configuration
Hm, not sure if this works but replace this:

net spindle-index-enable <= hm2_5i25.0.encoder.04.input-index

with this:

net spindle-index-enable <= hm2_5i25.0.encoder.04.input-index
net orient-enable => and2.1.in0
net spindle-input-index => and2.1.in1
net encoder-reset <= and2.1.out => hm2_5i25.0.encoder.04.reset

Don't forget to 'loadrt/addf' the 'and2.1' component
The following user(s) said Thank You: Artur_1617

Please Log in or Create an account to join the conversation.

Time to create page: 0.159 seconds
Powered by Kunena Forum