RobotStudio event

Changing External Axes values for a robTaget

Hi,

I am trying using C# API to set external axes for a robTarget (coordinated with the positioner user frame) and do a jumpTo(), but it still robTarget uses the old external axes values. If I click on Auto Configuration on Home>Path&Target>Path>mypath the changes will get activated. Can you help me  how I can some how I update the robTarget with the new values.



Thanks,
Khaled

Comments

  • I have a similar problem, I don´t see in the Station the changes do it in the robtarget despite if I read it the external axes values are the new ones.
  • HM
    HM
    edited May 2013
    I´ve made some advances here, and my problem was that I forgot to activate the external axis:

    // In my case the external axis is the second mechanical unit
    station.Irc5Controllers[0].MechanicalUnits[1].ActivationMode = MechanicalUnitActivationMode.Active;
  • Hello,
    i have a similar problem. I can read the external axis values but can not write them.
    Compiling works, but during the execution of the AddIn, an error occurs.

    Can anybody help?

    C#:
    .....
                    ExternalAxisValues eav = rtx.GetExternalAxes(true);
    
                    double[] ExAxVals = rtx.GetExternalAxes(true).GetAxisValues();
    
                    //Change VALUES just an example...
                    ExAxVals[0] += 1;
    
                    ExternalAxisValues.SetAxisValues(ref eav, ExAxVals);
                    rtx.SetExternalAxes(eav, true);
    .....

    Thanks a lot,

    Jonathan