Lathe with kflop and Kanalog -can't get axis to servo - Page 2


Page 2 of 2 FirstFirst 12
Results 21 to 34 of 34

Thread: Lathe with kflop and Kanalog -can't get axis to servo

  1. #21
    Member
    Join Date
    May 2009
    Location
    United States
    Posts
    98
    Downloads
    0
    Uploads
    0

    Default Re: Lathe with kflop and Kanalog -can't get axis to servo

    Thank you Tom,
    I would have thought that the closed loop would prevent this by the control seeing that the previous command line was not yet in position. The more I learn the less I know ! I will get a picture of the plots and post as soon as I can.



  2. #22
    Member
    Join Date
    May 2009
    Location
    United States
    Posts
    98
    Downloads
    0
    Uploads
    0

    Default Re: Lathe with kflop and Kanalog -can't get axis to servo

    Hi Tom,
    Here are the response screens you requested to see. My C program shows following error at 250.
    Thanks,
    Scott

    Attached Thumbnails Attached Thumbnails Lathe with kflop and Kanalog -can't get axis to servo-position-8-25-16-png   Lathe with kflop and Kanalog -can't get axis to servo-velocity-8-25-16-png  


  3. #23
    Member TomKerekes's Avatar
    Join Date
    May 2006
    Location
    USA
    Posts
    4045
    Downloads
    0
    Uploads
    0

    Default Re: Lathe with kflop and Kanalog -can't get axis to servo

    Hi Scott,

    It looks like Y axis following error is not the problem.

    What are your KMotionCNC Trajectory Planner Settings?

    Regards

    Regards
    TK http://dynomotion.com


  4. #24
    Member
    Join Date
    May 2009
    Location
    United States
    Posts
    98
    Downloads
    0
    Uploads
    0

    Default Re: Lathe with kflop and Kanalog -can't get axis to servo

    Hi Tom,
    Please see attached copy of trajectory screen. I have yet another question. I thought I read in the FAQ section of manual that if you wanted to reverse the operating direction of an axis to try changing both the in and out gain setting to the opposite of what they were set at. I tried that and the axis still worked good but the direction of travel did not change. Should I just change the servo motor power connections feeds around ?

    Thank You Tom
    Scott

    Attached Thumbnails Attached Thumbnails Lathe with kflop and Kanalog -can't get axis to servo-trajectory-8-26-16-jpg  


  5. #25
    Member TomKerekes's Avatar
    Join Date
    May 2006
    Location
    USA
    Posts
    4045
    Downloads
    0
    Uploads
    0

    Default Re: Lathe with kflop and Kanalog -can't get axis to servo

    Hi Scott,

    It doesn't look like you have set the Velocities and Accelerations for the Trajectory Planner for any of your axis.

    For the Y axis the Trajectory Planner is set to allow 16 inches/sec. That is very fast. Can your system do this? At your resolution of 20115 counts/inch that would be

    20115 x16 = 321840 counts/sec

    Which is about 30 times faster than what you tested in your previous email.

    You also have "Rapids as Feeds" selected which is inappropriate for your type of system. Which is why the trajectory planner is using the high feed rates for your Rapids instead of the much Slower Values specified in KFLOP. But regardless the Trajectory Planner setting must be set properly for your system. Please once again try to read this article and characterize your system's Trajectory Planner Settings:
    Dynomotion

    HTH
    Regards

    Last edited by TomKerekes; 08-27-2016 at 12:53 PM. Reason: Forgot Link
    Regards
    TK http://dynomotion.com


  6. #26
    Member
    Join Date
    May 2009
    Location
    United States
    Posts
    98
    Downloads
    0
    Uploads
    0

    Default Re: Lathe with kflop and Kanalog -can't get axis to servo

    Hi Tom,
    I found that when I reassigned the Y axis to Z for proper lathe terminology the direction of travel is now correct for + and -. I saved some programs in a few of the 7 files on Kmotion screen. I then realized that they say File ,not program. Do I need to get those replaced with the original files for proper operationn? I thought they were just g code example programs.
    Thanks,
    Scott



  7. #27
    Member
    Join Date
    May 2009
    Location
    United States
    Posts
    98
    Downloads
    0
    Uploads
    0

    Default Re: Lathe with kflop and Kanalog -can't get axis to servo

    Hi Tom,
    Thanks again for you patience and time. I also apparently do not know how to use the forum as this is the second time I did not see you had replied until after I sent another post. l see what you mean now. I thought these were set by the testing that was done in config / step response / upload C program. I have run some mach 3 turn wizard programs cutting steel and the motors work very well as set with wicked fast rapids,but I will reset per your instructions and see if the premature movement in next block go away. I have only seen it happen in the one long movement return rapid. I know I am exasperating your patience.
    Thank you..
    Scott



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

    Default Re: Lathe with kflop and Kanalog -can't get axis to servo

    Hi Scott,

    No worries. I appreciate your attitude and patience.

    Regards

    Regards
    TK http://dynomotion.com


  9. #29
    Member
    Join Date
    May 2009
    Location
    United States
    Posts
    98
    Downloads
    0
    Uploads
    0

    Default Re: Lathe with kflop and Kanalog -can't get axis to servo

    Hi Tom,
    I have played with Kmotion CNC a bit now and all seems to be working good now. No premature movements before prev. commanded move is finished. I thought about just sticking with Kmotion instead of going on to Mach but the code from many of the turn wizards do not seem to run in knotion. There are g50 and g80 codes used that kmotion does not list as part of its recognized programming ? I use the return to zero on mach screen often and don't see any option on kmotion screen?
    I am pretty much lost (suprise) on the method to set up ports and pins in Mach. Do I have to assign bits to use in the ports and pins using the bits from 0 to 46 ? If so, then do they have to be added to the c program? Can I use the spindle with DAC output example for my freq drive spindle and if so do I have to just remove the print reference to have it actually run the spindle? Is there a further breakdown of setting up the ports and pins I could go to beyond the mach 3 plug in instructions in your manuals?
    Thanks,
    Scott



  10. #30
    Member TomKerekes's Avatar
    Join Date
    May 2006
    Location
    USA
    Posts
    4045
    Downloads
    0
    Uploads
    0

    Default Re: Lathe with kflop and Kanalog -can't get axis to servo

    Hi Scott,

    I am pretty much lost (suprise) on the method to set up ports and pins in Mach. Do I have to assign bits to use in the ports and pins using the bits from 0 to 46
    KFLOP controls all the real-time I/O functions. Mach3 basically just passes trajectories to our Plugin so no Ports and Pins need to be configured in Mach3 (set them all to Port0 Pin1). Mach3 does require the "Enabled" checked for each axis in your system. Also the EStop input can not be disabled so it must be configured to a KFLOP Input Bit or to some dummy Input that never activates. The Init file that configures KFLOP for KMotionCNC should also work for Initializing KFLOP for Mach3 use.

    Can I use the spindle with DAC output example for my freq drive spindle and if so do I have to just remove the print reference to have it actually run the spindle?
    I'm not sure what example you are referring to or how your Spindle is controlled, but the same methods/code that controls the Spindle for KMotionCNC should work for Mach3 with two differences:

    #1 - Mach3 runs the same Spindle program for Spindle functions like on CW, on CCW, off, Set Speed by using a message value to tell the program what to do rather than 4 separate programs that KMotionCNC allows.

    #2 - Mach3 passes a fractional pulley speed value between 0 and 1 instead of an RPM value.

    HTH
    Regards

    Regards
    TK http://dynomotion.com


  11. #31
    Member
    Join Date
    May 2009
    Location
    United States
    Posts
    98
    Downloads
    0
    Uploads
    0

    Default Re: Lathe with kflop and Kanalog -can't get axis to servo

    Hi Tom,

    I am going through the steps to set up KMotionCNC Spindle Control. I am modifying my initialization c program to include the ServiceCSS and call it into a continuous loop. I have attached the Initialization file as I have modified it with the supplied code from the instructions. I am not sure I have inserted it correctly though. Can you look at the attachment and tell me if it is correct? As written the spindle does not run. I have been running the spindle with DAC commands and my spindle accepts 10 v dc + and - for input speed and direction. I decided I should get KMotion CNC running as a complete control before going on to Mach 3. KMotion does still run the two axis correctly with this init.c
    Thank you Tom,
    Scott

    Attached Files Attached Files


  12. #32
    Member TomKerekes's Avatar
    Join Date
    May 2006
    Location
    USA
    Posts
    4045
    Downloads
    0
    Uploads
    0

    Default Re: Lathe with kflop and Kanalog -can't get axis to servo

    Hi Scott,

    Yes you inserted things incorrectly. You pasted both the forever loop and the Service function right into the beginning of the main function. This always makes me chuckle as nothing after a forever loop will be executed. Its like telling someone:

    Step #1 jump up and down forever
    Step #2 get me a glass of water

    main and ServiceCSS are both functions which define code between the curly brackets. Can you see the extents of these two functions? They should remain separated. Don't place one inside the other.

    Put the forever loop at the end of your main function after all the initialization code so that the initialization code executes first before the forever loop is entered.

    Move the global definitions for *css_mode through *css_max_rpm outside and just before the main function.

    Let us know how much of this makes sense.

    Regards
    TK

    Regards
    TK http://dynomotion.com


  13. #33
    Member
    Join Date
    May 2009
    Location
    United States
    Posts
    98
    Downloads
    0
    Uploads
    0

    Default Re: Lathe with kflop and Kanalog -can't get axis to servo

    Hi Tom,
    Sorry so long between. I had to wait for my C code helper to be available. We failed again. The code does not work for spindle. Hoping you can take a look at the latest iteration attempt. Other axis control still works but now KMotion locks up between g code runs and I have to restart the computer. Also included copy of settings on thread 2. Is that the correct thread for these settings ?
    Thank you Tom,
    Scott

    Attached Thumbnails Attached Thumbnails Lathe with kflop and Kanalog -can't get axis to servo-tool-setup-jpg  
    Attached Files Attached Files


  14. #34
    Member TomKerekes's Avatar
    Join Date
    May 2006
    Location
    USA
    Posts
    4045
    Downloads
    0
    Uploads
    0

    Default Re: Lathe with kflop and Kanalog -can't get axis to servo

    Hi Scott,

    The forever loop calling ServiceCSS is now correct!

    You included the CSSJog.c twice. Once with an #include statement (correctly) but also pasted in (incorrectly).

    But I think we need to first take a step back and get all your Axes Configured and working including the Spindle Axis.

    Please specify what Axis you are using for what. Its important for you to understand what axes you are using.

    It looks like you are using 0 and 1 for X and Y.

    But then you have Axis 2 defined with bogus values. I assume you don't intend to use Axis #2. But then you include it into the Coordinate System?

    I assume you intend to use Axis 6 for the Spindle. But that Axis is never configured. But you do enable it?

    Hang in there. You will get it eventually

    Regards

    Regards
    TK http://dynomotion.com


Page 2 of 2 FirstFirst 12

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

Lathe with kflop and Kanalog -can't get axis to servo

Lathe with kflop and Kanalog -can't get axis to servo