586,061 active members*
4,414 visitors online*
Register for free
Login
IndustryArena Forum > Machine Controllers Software and Solutions > Dynomotion/Kflop/Kanalog > KFlop, KStep, and Konnect Board: Conflict with Jog and the Konnect interface?
Results 1 to 7 of 7
  1. #1
    Join Date
    Jul 2004
    Posts
    235

    KFlop, KStep, and Konnect Board: Conflict with Jog and the Konnect interface?

    Greetings,

    I am not using any of the I/O on the Kflop or the KStep, but only want to use the Konnect Board for Input and Output.

    However, something about the Konnect board and its interface, is interrupting the Jog ability of the X axis or CH0... If I disable the output 35, which stops the boards communications, jogging is allowed again...

    Note: This problem also translates to the KMotionCNC as well.
    _____________________

    Do you have any clue as to what this confict is? I am using Ver. 4.32.

    This is the second bug, including the previous GetVirtualBits(??) problem.

    Sincerely,

    Jeff
    Robot & Machine Design - BLUECNC4, GreenCNC3, RedCNC2L, SilverCNC2; CNC Software!
    www.truemachinedesign.com - - - - - - - - - - - - - www.truemachineautomation.com

  2. #2
    Join Date
    May 2006
    Posts
    4045

    Re: KFlop, KStep, and Konnect Board: Conflict with Jog and the Konnect interface?

    Hi Jeff,

    I can't think of what would cause such a thing. Please post the Initialization C Program you are using.

    What are you doing exactly? Are you Jogging with the Buttons on the KMotionCNC Screen? What happens exactly? Is the X axis disabled? Does the Destination on the KMotion Axis Screen change when you Jog? Will the other Axes still Jog?

    Regards
    TK
    http://dynomotion.com

  3. #3
    Join Date
    Jul 2004
    Posts
    235

    Re: KFlop, KStep, and Konnect Board: Conflict with Jog and the Konnect interface?

    All other Axis jog. Only the Ch0 or X axis is effected it seems.
    Does the same in KMotionCNC and my BlueCNC4.

    _______________________________________________ init file below.

    #include "KMotionDef.h"

    // Defines axis 0, 1, 2, 3 as simple step dir TTL outputs for KSTEP
    // enables them
    // sets them as an xyzA coordinate system for GCode

    int main()
    {
    double T0, LastX=0, LastY=0, LastZ=0, LastA=0, Tau;

    KStepPresent=TRUE; // enable KSTEP input multiplexing
    FPGA(KAN_TRIG_REG)=4; // Mux PWM0 to JP7 Pin5 IO 44 for KSTEP

    FPGA(STEP_PULSE_LENGTH_ADD) = 63 + 0x80; // set polarity and pulse length to 4us

    ch0->InputMode=NO_INPUT_MODE;
    ch0->OutputMode=STEP_DIR_MODE;
    ch0->Vel=40000;
    ch0->Accel=200000;
    ch0->Jerk=4e+006;
    ch0->P=0;
    ch0->I=0.01;
    ch0->D=0;
    ch0->FFAccel=0;
    ch0->FFVel=0;
    ch0->MaxI=200;
    ch0->MaxErr=1e+006;
    ch0->MaxOutput=200;
    ch0->DeadBandGain=1;
    ch0->DeadBandRange=0;
    ch0->InputChan0=0;
    ch0->InputChan1=0;
    ch0->OutputChan0=8;
    ch0->OutputChan1=0;
    ch0->MasterAxis=-1;
    ch0->LimitSwitchOptions=0x0;
    ch0->InputGain0=1;
    ch0->InputGain1=1;
    ch0->InputOffset0=0;
    ch0->InputOffset1=0;
    ch0->OutputGain=1;
    ch0->OutputOffset=0;
    ch0->SlaveGain=1;
    ch0->BacklashMode=BACKLASH_OFF;
    ch0->BacklashAmount=0;
    ch0->BacklashRate=0;
    ch0->invDistPerCycle=20000;
    ch0->Lead=0;
    ch0->MaxFollowingError=1000000000;
    ch0->StepperAmplitude=20;

    ch0->iir[0].B0=1;
    ch0->iir[0].B1=0;
    ch0->iir[0].B2=0;
    ch0->iir[0].A1=0;
    ch0->iir[0].A2=0;

    ch0->iir[1].B0=1;
    ch0->iir[1].B1=0;
    ch0->iir[1].B2=0;
    ch0->iir[1].A1=0;
    ch0->iir[1].A2=0;

    ch0->iir[2].B0=0.000769;
    ch0->iir[2].B1=0.001538;
    ch0->iir[2].B2=0.000769;
    ch0->iir[2].A1=1.92076;
    ch0->iir[2].A2=-0.923833;
    EnableAxisDest(0,0);

    ch1->InputMode=NO_INPUT_MODE;
    ch1->OutputMode=STEP_DIR_MODE;
    ch1->Vel=40000;
    ch1->Accel=200000;
    ch1->Jerk=4e+006;
    ch1->P=0;
    ch1->I=0.01;
    ch1->D=0;
    ch1->FFAccel=0;
    ch1->FFVel=0;
    ch1->MaxI=200;
    ch1->MaxErr=1e+006;
    ch1->MaxOutput=200;
    ch1->DeadBandGain=1;
    ch1->DeadBandRange=0;
    ch1->InputChan0=0;
    ch1->InputChan1=0;
    ch1->OutputChan0=9;
    ch1->OutputChan1=0;
    ch1->MasterAxis=-1;
    ch1->LimitSwitchOptions=0x0;
    ch1->InputGain0=1;
    ch1->InputGain1=1;
    ch1->InputOffset0=0;
    ch1->InputOffset1=0;
    ch1->OutputGain=1;
    ch1->OutputOffset=0;
    ch1->SlaveGain=1;
    ch1->BacklashMode=BACKLASH_OFF;
    ch1->BacklashAmount=0;
    ch1->BacklashRate=0;
    ch1->invDistPerCycle=1;
    ch1->Lead=0;
    ch1->MaxFollowingError=1000000000;
    ch1->StepperAmplitude=20;

    ch1->iir[0].B0=1;
    ch1->iir[0].B1=0;
    ch1->iir[0].B2=0;
    ch1->iir[0].A1=0;
    ch1->iir[0].A2=0;

    ch1->iir[1].B0=1;
    ch1->iir[1].B1=0;
    ch1->iir[1].B2=0;
    ch1->iir[1].A1=0;
    ch1->iir[1].A2=0;

    ch1->iir[2].B0=0.000769;
    ch1->iir[2].B1=0.001538;
    ch1->iir[2].B2=0.000769;
    ch1->iir[2].A1=1.92076;
    ch1->iir[2].A2=-0.923833;
    EnableAxisDest(1,0);

    ch2->InputMode=NO_INPUT_MODE;
    ch2->OutputMode=STEP_DIR_MODE;
    ch2->Vel=40000;
    ch2->Accel=200000;
    ch2->Jerk=4e+006;
    ch2->P=0;
    ch2->I=0.01;
    ch2->D=0;
    ch2->FFAccel=0;
    ch2->FFVel=0;
    ch2->MaxI=200;
    ch2->MaxErr=1e+006;
    ch2->MaxOutput=200;
    ch2->DeadBandGain=1;
    ch2->DeadBandRange=0;
    ch2->InputChan0=0;
    ch2->InputChan1=0;
    ch2->OutputChan0=10;
    ch2->OutputChan1=0;
    ch2->MasterAxis=-1;
    ch2->LimitSwitchOptions=0x0;
    ch2->InputGain0=1;
    ch2->InputGain1=1;
    ch2->InputOffset0=0;
    ch2->InputOffset1=0;
    ch2->OutputGain=-1;
    ch2->OutputOffset=0;
    ch2->SlaveGain=1;
    ch2->BacklashMode=BACKLASH_OFF;
    ch2->BacklashAmount=0;
    ch2->BacklashRate=0;
    ch2->invDistPerCycle=1;
    ch2->Lead=0;
    ch2->MaxFollowingError=1000000000;
    ch2->StepperAmplitude=20;

    ch2->iir[0].B0=1;
    ch2->iir[0].B1=0;
    ch2->iir[0].B2=0;
    ch2->iir[0].A1=0;
    ch2->iir[0].A2=0;

    ch2->iir[1].B0=1;
    ch2->iir[1].B1=0;
    ch2->iir[1].B2=0;
    ch2->iir[1].A1=0;
    ch2->iir[1].A2=0;

    ch2->iir[2].B0=1;
    ch2->iir[2].B1=0;
    ch2->iir[2].B2=0;
    ch2->iir[2].A1=0;
    ch2->iir[2].A2=0;
    EnableAxisDest(2,0);

    ch3->InputMode=NO_INPUT_MODE;
    ch3->OutputMode=STEP_DIR_MODE;
    ch3->Vel=4000;
    ch3->Accel=400000;
    ch3->Jerk=4e+006;
    ch3->P=0;
    ch3->I=0.01;
    ch3->D=0;
    ch3->FFAccel=0;
    ch3->FFVel=0;
    ch3->MaxI=200;
    ch3->MaxErr=1e+006;
    ch3->MaxOutput=200;
    ch3->DeadBandGain=1;
    ch3->DeadBandRange=0;
    ch3->InputChan0=0;
    ch3->InputChan1=0;
    ch3->OutputChan0=11;
    ch3->OutputChan1=0;
    ch3->MasterAxis=-1;
    ch3->LimitSwitchOptions=0x0;
    ch3->InputGain0=1;
    ch3->InputGain1=1;
    ch3->InputOffset0=0;
    ch3->InputOffset1=0;
    ch3->OutputGain=1;
    ch3->OutputOffset=0;
    ch3->SlaveGain=1;
    ch3->BacklashMode=BACKLASH_OFF;
    ch3->BacklashAmount=0;
    ch3->BacklashRate=0;
    ch3->invDistPerCycle=1;
    ch3->Lead=0;
    ch3->MaxFollowingError=1000000000;
    ch3->StepperAmplitude=20;

    ch3->iir[0].B0=1;
    ch3->iir[0].B1=0;
    ch3->iir[0].B2=0;
    ch3->iir[0].A1=0;
    ch3->iir[0].A2=0;

    ch3->iir[1].B0=1;
    ch3->iir[1].B1=0;
    ch3->iir[1].B2=0;
    ch3->iir[1].A1=0;
    ch3->iir[1].A2=0;

    ch3->iir[2].B0=0.000769;
    ch3->iir[2].B1=0.001538;
    ch3->iir[2].B2=0.000769;
    ch3->iir[2].A1=1.92076;
    ch3->iir[2].A2=-0.923833;
    EnableAxisDest(3,0);

    DefineCoordSystem(0,1,2,3);

    //Add IO Board
    AddKonnect(0,&VirtualBits,VirtualBitsEx);

    SetBitDirection(45,1); // set Enable Signal as Output
    SetBit(45); // Enable the amplifiers

    // Add a small amount of Coordinated Motion Path smoothing if desired
    // Tau = 0.001; // seconds for Low Pass Filter Time Constant
    // KLP = exp(-TIMEBASE/Tau);
    KLP=0; // force to 0 to disable
    // printf("Tau=%f KLP=%f\n",Tau,KLP);


    for (; // loop forever
    {
    WaitNextTimeSlice();

    // Service Amplifier disable after no activity for a while
    if (ch0->Dest != LastX || ch1->Dest != LastY || ch2->Dest != LastZ || ch3->Dest != LastA)
    {
    // we moved - enable KStep Amplifers
    SetBit(45);
    T0 = Time_sec(); // record the time and position of last motion
    LastX=ch0->Dest;
    LastY=ch1->Dest;
    LastZ=ch2->Dest;
    }
    else
    {
    if (Time_sec() > T0 + 10.0) ClearBit(45);
    }
    }

    return 0;
    }
    Robot & Machine Design - BLUECNC4, GreenCNC3, RedCNC2L, SilverCNC2; CNC Software!
    www.truemachinedesign.com - - - - - - - - - - - - - www.truemachineautomation.com

  4. #4
    Join Date
    May 2006
    Posts
    4045

    Re: KFlop, KStep, and Konnect Board: Conflict with Jog and the Konnect interface?

    Hi Jeff,

    I do see you are not resetting the number of Auxillary boards with the InitAux() function. That would cause an additional Konnect to be added and serviced each time you Initialize since the time KFLOP was powered up. Does the problem occur after a few Initializations? Otherwise please answer my other questions.

    Should be:

    InitAux();
    AddKonnect(0,&VirtualBits,VirtualBitsEx);

    Regards
    TK
    TK
    http://dynomotion.com

  5. #5
    Join Date
    Jul 2004
    Posts
    235

    Re: KFlop, KStep, and Konnect Board: Conflict with Jog and the Konnect interface?

    Tom,

    Thanks for you time. I changed the code as mentioned above. Still had the problem.
    __________________________________

    Strange thing going on... , I found "CaptureXYZMotionToFile.c" loaded into thread 5 and running.

    I did not tell this to run... nor have I ever looked at it?

    If it is running, then it "screws up" the Ch0 or Xaxis jog ability, with the KStep Board. The axis will run, if a program is executed... but won't jog. My jogging is using "Script" commands for simplicity...
    I "commented out" the program, and then whenever it is loaded, by whatever is loading it; it will do nothing.

    Thus I am operational again.

    What loads this file, to thread 5?

    - Thanks again.
    Robot & Machine Design - BLUECNC4, GreenCNC3, RedCNC2L, SilverCNC2; CNC Software!
    www.truemachinedesign.com - - - - - - - - - - - - - www.truemachineautomation.com

  6. #6
    Join Date
    May 2006
    Posts
    4045

    Re: KFlop, KStep, and Konnect Board: Conflict with Jog and the Konnect interface?

    Hi Jeff,

    The KMotion.exe C Programs Edit windows for each Thread do not necessarily show what has been downloaded to KFLOP Thread Memories. In fact there is no way to "see" what programs have been compiled and downloaded to KFLOP. It up to you to keep track of that.

    But if there is a Green Bar on the Thread number then it indicates that some program is running in KFLOP for that Thread Space.

    It is possible to have Threads automatically launched on Startup. But you must Flash User Data into KFLOP for that to occur. Flash "New Version" to reset KFLOP to the original state with no Data or Programs if you think this is a possibility.

    Otherwise maybe you inadvertently sent an Execute Program to KFLOP? Or possibly invoked an MCode Action to Execute Program?

    KMotionCNC can be configured to Download/Execute Programs on Startup, or Exit, or when Pushing a User Button or MCode. Check the KMotionCNC | Tool Setup | M0-M30 configuration Page

    HTH
    Regards
    TK
    http://dynomotion.com

  7. #7
    Join Date
    Jul 2004
    Posts
    235

    Re: KFlop, KStep, and Konnect Board: Conflict with Jog and the Konnect interface?

    Ok, must have done it somehow...

    Thanks for all your help....!
    Robot & Machine Design - BLUECNC4, GreenCNC3, RedCNC2L, SilverCNC2; CNC Software!
    www.truemachinedesign.com - - - - - - - - - - - - - www.truemachineautomation.com

Similar Threads

  1. Kflop/Kanalog/Konnect - MR-J2S-xxA and everything in between
    By wheeliecake in forum Dynomotion/Kflop/Kanalog
    Replies: 7
    Last Post: 10-25-2014, 02:21 AM
  2. Problem with Konnect
    By mk00 in forum Dynomotion/Kflop/Kanalog
    Replies: 2
    Last Post: 02-14-2014, 06:13 AM
  3. Konnect & PWM outputs
    By itchief in forum Dynomotion/Kflop/Kanalog
    Replies: 19
    Last Post: 12-10-2013, 04:26 AM
  4. Konnect cable length
    By itchief in forum Dynomotion/Kflop/Kanalog
    Replies: 4
    Last Post: 12-09-2013, 06:34 AM
  5. Announcing Dynomotion's 48 channel 24V IO Expander - KONNECT
    By TomKerekes in forum Dynomotion/Kflop/Kanalog
    Replies: 0
    Last Post: 10-29-2013, 08:34 PM

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
  •