Spindle set up and tapping


Results 1 to 8 of 8

Thread: Spindle set up and tapping

  1. #1
    Member
    Join Date
    Jun 2013
    Location
    USA
    Posts
    1007
    Downloads
    0
    Uploads
    0

    Default Spindle set up and tapping

    Hi Tom
    It's been a while since I have posted anything. I finally got around to a mill retrofit using k-flop and kanalog. The machine is using all the original parts. I have successfully gotten the servos, coolant, axis lube, etc... going. The homing to limits and index and all my io are working with the exception of the tool changer which will come later. I have run into a few issues now.

    Kmotion 434 final version is being used. When I use the tool setup screen or flip between the kmotion.exe and kmotion cnc several of the buttons and features I setup for my custom screen will disappear causing me to need to reload the screen. Is there anything you can think of that would cause this problem.

    I setup the spindle the simple way by turning on bits and outputting to a day. This works ok but I need more functionality. I am going to try again using the c programs in the css folder. The big issue I have to start is my spindle has a low speed winding pin that needs to be turned on from 0-1200rpm and turned off for the rest of the 1200-8000rpm range. I have the bit 155 working manually with no issue. Can you suggest a way to have it come on below 1200 and go off above that in the spindle jog program?

    I am not sure what to do exactly with setting up a axis channel to output to a dac. Does this channel get put in my init program and does it get added to the coordinated motion axis?

    Last for now I have the threading section on the tool setup screen set to read my spindle encoder for rpm feedback. It does read the rpm but above about 110rpm the readout disappears. The encoder is 4096 CPR. Do you know what I may be doing wrong?

    Any help is appreciated and I will try to get some videos once I work out my remaining issues. Tapping will be next.


    Thank you
    Ben

    Sent from my E6910 using Tapatalk

    Similar Threads:


  2. #2
    Member
    Join Date
    Jun 2013
    Location
    USA
    Posts
    1007
    Downloads
    0
    Uploads
    0

    Default Re: Spindle set up and tapping

    I have successfully gotten the spindle css programs to work. I am still not sure if I need to add the channel to my init program? I do know if I don't enable the spindle axis it does not work until I do. I am still hoping to get some advice on how to turn on the chw pin during a specific rpm range and clear it at the proper time? I have also run into no longer being able to read the encoder because if I add it to the axis the dac is on the spindle does not work correctly. What I really need is to be able to run the spindle semi closed loop. I would like to be able to use the encoder to drive the dac voltage to make the rpm of the spindle match the commanded rpm but not drive the axis like a servo if that makes any sense.

    Thank you
    Ben

    Sent from my E6910 using Tapatalk



  3. #3
    Member
    Join Date
    Jun 2013
    Location
    USA
    Posts
    1007
    Downloads
    0
    Uploads
    0

    Default Re: Spindle set up and tapping

    I think for the chw bit I need to add a few lines in the spindle jog program that state

    If speedvar is less than or = 1200 then set bit () else clear bit ().

    I have no idea how that would be written in c but I will keep trying until I get a solution that works or someone else presents a better idea.

    Thank you
    Ben

    Sent from my E6910 using Tapatalk



  4. #4
    Member TomKerekes's Avatar
    Join Date
    May 2006
    Location
    USA
    Posts
    3382
    Downloads
    0
    Uploads
    0

    Default Re: Spindle set up and tapping

    Hi Ben,

    Sorry somehow I missed this Thread.

    What I really need is to be able to run the spindle semi closed loop. I would like to be able to use the encoder to drive the dac voltage to make the rpm of the spindle match the commanded rpm but not drive the axis like a servo if that makes any sense.
    I'm not sure why you don't want to operate the Spindle like a Servo. That would make things simpler and more accurate and facilitate tapping.

    Yes you should add any Spindle Configuration and possibly Enable to your Init C Program.

    The commanded Speed can be obtained with ch->last_vel. So you might code this in a forever loop:

    SetStateBit(155, fast_fabs(ch0->last_vel) > 1200.0 * (4096.0 / 60.0));

    Regards
    TK http://dynomotion.com


  5. #5
    Member
    Join Date
    Jun 2013
    Location
    USA
    Posts
    1007
    Downloads
    0
    Uploads
    0

    Default Re: Spindle set up and tapping

    Thank you for the reply Tom. I am not against setting it up like a servo if that will make things easier. Is there a example of how that's done? I set things up according to the last example on the spindle setup page so the factor is 1/8000. When I added the encoder and hit move the spindle turned forward and reverse like a normal move but kept going back and forth continuously until I hit disable. Not sure what caused that reaction or how to fix it. If I set it up like a servo would I still use the same c programs for me,ccw,off,jog and tap?

    Thank you
    Ben

    Sent from my E6910 using Tapatalk



  6. #6
    Member TomKerekes's Avatar
    Join Date
    May 2006
    Location
    USA
    Posts
    3382
    Downloads
    0
    Uploads
    0

    Default Re: Spindle set up and tapping

    H Ben,

    I am not against setting it up like a servo if that will make things easier. Is there a example of how that's done?
    Same as a Servo. Except gains might be low and response much slower. Test with Step Response Screen.

    Remove the Feed Forward and try only small P Gain.



    When I added the encoder and hit move the spindle turned forward and reverse like a normal move but kept going back and forth continuously until I hit disable. Not sure what caused that reaction or how to fix it.
    Reduce gains until stable.

    Regards
    TK http://dynomotion.com


  7. #7
    Member
    Join Date
    Jun 2013
    Location
    USA
    Posts
    1007
    Downloads
    0
    Uploads
    0

    Default Re: Spindle set up and tapping

    I have been experimenting with the spindle tuning. I have had I believe decent results. I had to treat it similar to my servo drive tuning to stay stable. That required low pid gains and feed forward to get me stable and good results. The problem with the spindle is any i gain at all caused instability. I ended up with p=.0015 I=0 d=.015 vff=.004 and aff=.0004. l am wondering if I can have 2 axis channels setup for the spindle. 3 and 4. I would use 3 for tuning to the 8000 rpm max to get good stability for cutting. I would then use 4 to tune to 2000 rpm and use it for tapping. I would be able to tune the spindle for more stiffness at lower rpm for tapping. Do you see any issues this may cause?

    I fixed the issue with seeing the correct rpm display in kmotion cnc. I had changed the font and I believe maybe that caused a problem with the refresh rate of the display. Changing it back fixed it.

    Thank you
    Ben

    Sent from my E6910 using Tapatalk



  8. #8
    Member TomKerekes's Avatar
    Join Date
    May 2006
    Location
    USA
    Posts
    3382
    Downloads
    0
    Uploads
    0

    Default Re: Spindle set up and tapping

    Hi Ben,

    The problem with the spindle is any i gain at all caused instability.
    There should always be some stable value if you make it small enough.

    Your gains all seem very small. Maybe you have a large factor somewhere? Please post all your settings Config, Step Response, and IIR Filters. Also post a plot of movement.

    I would tune without Feed Forward first.

    Its not clear why you would need two types of tuning. If you have stiffness at low rpm it should still work at high rpm.


    I fixed the issue with seeing the correct rpm display in kmotion cnc. I had changed the font and I believe maybe that caused a problem with the refresh rate of the display. Changing it back fixed it.
    Maybe the Control just needed to be made bigger? It could be when the number became more digits it no longer fit.

    Regards
    TK http://dynomotion.com


Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


About CNCzone.com

    We are the largest and most active discussion forum for manufacturing industry. The site is 100% free to join and use, so join today!

Follow us on


Our Brands

Spindle set up and tapping

Spindle set up and tapping

Spindle set up and tapping