Kflop/Kstep to G0704 KBIC spindle speed control help.


Results 1 to 12 of 12

Thread: Kflop/Kstep to G0704 KBIC spindle speed control help.

  1. #1
    Registered
    Join Date
    Feb 2016
    Location
    United States
    Posts
    13
    Downloads
    0
    Uploads
    0

    Default Kflop/Kstep to G0704 KBIC spindle speed control help.

    Currently I have connected JP33 Pin 7 to KBIC P3 and JP33 Pin 5 to KBIC P1 on Kstep. Measuring voltage across Pin 5 and 7 I have 11.09V, From Pin 6 to Pin 7 I have 3v instead of 5V. From this point I'm not sure what my next step is.


    #include "KMotionDef.h"
    #include "CorrectAnalogFunction.c"

    #define RefVoltage 11.09f

    main()
    {
    float V=5.0;

    FPGA(KAN_TRIG_REG)=4; // Mux PWM0 to JP7 Pin5 IO 44 for KSTEP
    SetBitDirection(44,1); // define bit as an output
    FPGA(IO_PWMS_PRESCALE) = 46; // divide clock by 46 (1.4 KHz)
    FPGA(IO_PWMS+1) = 1; // Enable

    FPGA(IO_PWMS) = CorrectAnalog(V/RefVoltage); // Set PWM
    }

    Similar Threads:
    Last edited by RootbeerFLHX; 06-24-2016 at 08:26 AM.


  2. #2
    Registered
    Join Date
    Feb 2016
    Location
    United States
    Posts
    13
    Downloads
    0
    Uploads
    0

    Default Re: Kflop/Kstep to G0704 KBIC spindle speed control help.

    Do I need to add this C program to get my voltage corrected, or am I missing something else?


    // PWM->Analog Correction

    //

    // assume very non-linear for first few count and linear thereafter

    //

    // Measure output ratio for first 0-7 counts then at 240



    float V[]=

    {

    0.001, // count = 0

    0.031, // count = 1

    0.044, // count = 2

    0.054, // count = 3

    0.062, // count = 4

    0.069, // count = 5

    0.074, // count = 6

    0.079 // count = 7

    };



    float V240=0.970;



    int CorrectAnalog(float v)

    {

    int r;

    float v2=2.0f*v;

    // compare with half way points to determine closest count

    if (v2 < V[1]+V[0]) return 0;

    if (v2 < V[2]+V[1]) return 1;

    if (v2 < V[3]+V[2]) return 2;

    if (v2 < V[4]+V[3]) return 3;

    if (v2 < V[5]+V[4]) return 4;

    if (v2 < V[6]+V[5]) return 5;

    if (v2 < V[7]+V[6]) return 6;



    // must be 7 or higher do linear interpolation



    r = (int)(7.5 + (v-V[7])/(V240-V[7])*(240.0f-7.0f));

    if (r>255) r=255;

    return r;

    }



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

    Default Re: Kflop/Kstep to G0704 KBIC spindle speed control help.

    Hi RootbeerFLHX,

    It should be much closer to 5V. I'm not sure what is wrong. Are you sure you measured 11.09V as the supply voltage? That seems very coincidental that it was the exact default value in the file.

    Does it remain 11.09V after running the program?

    Is the output voltage measured with no load or other connections except your meter?

    If you command voltages other than 5V what do you get?

    The #include "CorrectAnalogFunction.c" statement includes the CorrectAnalog() function (code is more readable if you paste it into CODE tags from the cnczone Advanced page).

    Regards

    Regards
    TK http://dynomotion.com


  4. #4
    Registered
    Join Date
    Feb 2016
    Location
    United States
    Posts
    13
    Downloads
    0
    Uploads
    0

    Default

    Hi Tom.

    The 11.19v on pin 5 and 7 was before the program runs. Checking with the program running it is 4.462v on pin 5 and 7, 3.472v on pin 6 and 7. I changed the RefVoltage to 4.462f, and attached pin 6 to the speed controller, but I'm still only able to get 1248 rpm with a S2500 command.



  5. #5
    Registered
    Join Date
    Feb 2016
    Location
    United States
    Posts
    13
    Downloads
    0
    Uploads
    0

    Default

    Ok, I'm not sure what I did, but now it's running at 2184 with a S2500, maybe the program needed to be restarted? Anyway, is there a way to fine tune the numbers a little closer?



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

    Default Re: Kflop/Kstep to G0704 KBIC spindle speed control help.

    Hi RootbeerFLHX,

    I think you should go back and repeat the previous experiment. KStep only puts a max of a 1Kohm load on the reference voltage from the KBIC drive. The reference voltage out from the drive should remain relatively constant otherwise I suspect things will be very nonlinear. Do you have a specification on the drive?

    Regards

    Regards
    TK http://dynomotion.com


  7. #7
    Registered
    Join Date
    Feb 2016
    Location
    United States
    Posts
    13
    Downloads
    0
    Uploads
    0

    Default

    Specs on the board are:

    Model: JYMC-220B-II
    Input: 115VAC-50/60 HZ
    Output: 0-90 VDC
    Rated: 13.5 ADC
    Yangzhou Jiayi Mechano-electronics Institiute



  8. #8
    Registered
    Join Date
    Feb 2016
    Location
    United States
    Posts
    13
    Downloads
    0
    Uploads
    0

    Default

    the original Potentiometer is 4700ohms.



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

    Default Re: Kflop/Kstep to G0704 KBIC spindle speed control help.

    Hi RootbeerFLHX,

    Can you find a link to the full manual including the analog Reference output voltage specification and analog input requirements?

    Regards

    Regards
    TK http://dynomotion.com


  10. #10
    Registered
    Join Date
    Feb 2016
    Location
    United States
    Posts
    13
    Downloads
    0
    Uploads
    0

    Default Re: Kflop/Kstep to G0704 KBIC spindle speed control help.

    http://www.kbelectronics.com/manuals/kbic_manual.pdf
    KBIC-125 is very similar to what I have. I have been unable to track down a manual using the other part number.



  11. #11
    Community Moderator Al_The_Man's Avatar
    Join Date
    Dec 2003
    Location
    Canada
    Posts
    24221
    Downloads
    0
    Uploads
    0

    Default Re: Kflop/Kstep to G0704 KBIC spindle speed control help.

    That other part number appears to be a totally different drive to the KBIC?
    With the KBIC you should also be using the I1 & I2 terminals to inhibit if reversing etc or stopping by removing motor power, as this resets the drive and allows the drive to use the accel setting to come up to speed.
    Al.

    CNC, Mechatronics Integration and Custom Machine Design

    “Logic will get you from A to B. Imagination will take you everywhere.”
    Albert E.


  12. #12
    Registered
    Join Date
    Feb 2016
    Location
    United States
    Posts
    13
    Downloads
    0
    Uploads
    0

    Default

    Quote Originally Posted by Al_The_Man View Post
    That other part number appears to be a totally different drive to the KBIC?
    With the KBIC you should also be using the I1 & I2 terminals to inhibit if reversing etc or stopping by removing motor power, as this resets the drive and allows the drive to use the accel setting to come up to speed.
    Al.

    Somewhere else I had read they were a Chinese knockoff of the KBMM or KBIC, but that's a good point about the Inhibit connections that I hadn't thought about.



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

Kflop/Kstep to G0704 KBIC spindle speed control help.

Kflop/Kstep to G0704 KBIC spindle speed control help.