possible to create new robtargets with PC SDK?

MichelinFlicka
MichelinFlicka Sweden
edited May 2016 in Developer Tools
Is it possible to create new robtargets by using the PCSDK, robot studio SDK or TP SDK?
creating a PC SDK application and i want to create new robtargets when i saving a position. For now, i manually put in a couple of robtargets in the rapid code which i fill with data.

Comments

  • John_Verheij
    John_Verheij Netherlands ✭✭
    The TP SDK contains a function "CreateRapidData", with which it is possible to create new robtargets.

    The example below is copy/pasted from http://developercenter.robotstudio.com/BlobProxy/devcenter/FPSDK/html/e5b1a0f9-30ef-5885-75c8-4c765f0d3fef.htm
    If needed I can create an example with robtargets..
    using ABB.Robotics;
    using ABB.Robotics.Controllers;
    using ABB.Robotics.Controllers.RapidDomain;
    ...
    Controller c = new Controller();
    
    Task[] allTasks = c.Rapid.GetTasks();
    Task firstTask = allTasks[0];
    
    Module mod = _task.GetModule("Conveyor");
    
    //The following code creates a simple rapid data instance.
    mod.CreateRapidData("count", "num", false, StorageType.Pesistent);
  • Thanks man, im very happy for all this help! 
    Is it a problem to use both PC SDK and FP SDK ? when i add ABB.Robotics.Controllers (FP SDK) ive got errors cuz i already have the one from PC SDK. but that one dosent contain "CreateRapidData".

    if you have time, please give me an example with robtargets!

  • carlosmtz2000
    carlosmtz2000 United States ✭✭

    The FP SDK (Flex Pendant SDK) can only be used for applications that run in the Flex Pendant, not in a PC. How many robtargets are you planning to create on the fly? thinking if you can find a workaround to accomplish the user experience you are looking for.

    BR



    Carlos Martinez
    ABB
  • John_Verheij
    John_Verheij Netherlands ✭✭
    Yes true, for creating a PC application you have to stick with the PC-SDK. The FP-SDK can be used to create a flexpendant application and the RobotStudioSDK to create an add-in for RobotStudio. 

    A work-around is to load a 'new' program or module with the created robtargets. This can be done with the "LoadModuleFromFile" or "LoadProgramFromFile" functions. 
  • okey thanks now its starts to get a little more clear what I can do. is it any good to combine the PC SDK code with the Robotstudio SDK, for example create a add in which makes it possible to create targets and paths and so on, but still have the PC SDK application as the base? ive tried to combine these two in a project but gets a lot of problems and im not sure it even worth the work if i manage to solve it. 
    BR
  • John_Verheij
    John_Verheij Netherlands ✭✭
    If you want to create a RobotStudio-addin, you can also use the PC-SDK. What do you mean with getting a lot of problems?
  • I already have a PC SDK VS project where i manipulate the robot, for now in robot studio, but the aim is to use it on the real controller later. i created a add in, just so i could make new paths and targets to use in my PC project cuz that would really make my application more useful. but I had problems combine the two projects together. i tried both imort the add in project to my application and the other way around. im new at this and i couldnt get it to work or understand the problem so i leaved the idea for a while. Im not even sure its a good idea to use an addin for the prupose to create targets on the fly or if i will have problems later when i wanna use my pc application on the real controller.
  • carlosmtz2000
    carlosmtz2000 United States ✭✭

    HI again,

    I will recommend to use mainly the PCSDK if you want to interact with a real controller; you can sill use the RobotStudio SDK to help you host your AddIn inside RobotStudio. You can also use the RobotStudio SDK to create path and targets, however, these are created inside the RobotStudio Station, not in the virtual controller.

    Can you share some of the methods you are using to create paths and targets? I agree with John, that your option could be to have a RAPID module with your generated data.

    Can you host this functionality in the FlexPendant?


    BR 

    Carlos Martinez
    ABB
Sign In or Register to comment.