Importing robot programs on RoboDK

  • Hi there,

    Importing "hand-written" program is not an officially supported feature.

    Therefore, we cannot guarantee any result.

    I still recommend you to give it a try.

    Start by building your station with the same robot and tool(s) as in your program.
    You can then drag and drop the program in RoboDK's window.


    If things turn out well, you can retrieve the movements and the target.
    If only the movements appear, select the movements (one or many at the same time) -> "right click" -> "Select Targets".

    If you are importing from KUKA, we also have a dedicated script to import .src files.

    "Main menu" -> "Tools" -> "Run Script" -> "Import_KUKA_SRC_Program"


    Hope it helps.

    Have a great day.


    Jeremy

    RoboDK - Simulation and Offline programming software for industrial and collaborative robots.

    Visit us at RoboDK.com
    Take a look at our tutorial videos on our YouTube channel.

  • Do all the points have to be defined in the SRC file? I mean that is the DAT file ignored?


    RoboDK example program for importing works fine.

    But if I have handwritten logic, loops, counters, calculations ... it will not work.

    If I would like to try out some behavior like that I have to write it in Python ?

  • Hi Koppel,


    It's better if the points were part of the SRC file as DAT file can't be loaded.

    As said before, you may need to use the "Select targets" option to retrieve the position.


    For logics, loops, counter, etc. you need to use the Python API.

    Mode details in this link.


    Have a great day.

    Jeremy

    RoboDK - Simulation and Offline programming software for industrial and collaborative robots.

    Visit us at RoboDK.com
    Take a look at our tutorial videos on our YouTube channel.

  • Hi,


    I don't understand what is supposed to happen when I choose "Select target"

    What I have done:

    • Import my SRC file with points as "PTP {X 0, Y 500, Z 450, A 0, B 40, C -180}"
    • I right click on one of the Move-es inside the program that was created in RoboDK and pick "Select target" and then a target is created with the same name as the move "T MoveJ 1"
    • If I right click on many of the Move-es inside the program, right click and choose "Select targets" ... then many targets with the same name are created.


    ... I guess I understand what is supposed to happen... but I don't understand how this is useful?
    Seems like just another way to import targets...


    What I would like to have is a trick that would enable me to kind of use the points in a SRC file in the format of "PTP Point1"... "PTP Point2" ... etc.

    Where the coordinates are in a DAT file.

    I wondered if I already had a TARGET named "Point1" and I then import the SRC file... that it would somehow pick up the relationship but it didn't.


    I tested another way.

    • import all my points as Targets
    • Open the SRC file that has the "bad" format "PTP Point1"... "PTP Point2"
    • RoboDK tells me "Failed to retrieve target (line 7):PTP Point1" ... for all the lines and doesn't import anything.

    I was expecting to exchange the failed points with my previously imported targets and then at least make the sequence of the movements work.


    I guess I have to manually recreate my program in RoboDK by importing all the points in my DAT file and then create new program and adding "Set reference frame instruction" between the points when nessessary

  • Hi Koppel,


    As mention, this feature is not official.
    We are just giving you access to a piece of development we did some times ago and never became a full blown feature for 1 main reasons, we support about 30 different brands, if we do it for one... we need to do it for at lease 10-12 brands... That's a big can of worms for us.
    End that's not considering the different "flavor" of code each brand has. Example: .src, .src + .dat, .src + .csv

    If you really need this, developing just one specific solution for your specific needs is not such a huge thing and if you have a bit of a coding background, you should be able to pull it of. In the end, you just need to "read" the .src and .dat file and extract the information.


    Using Python you can easily crawl through your .dat file, fine a point, retrieve Name, Position, Joints and use something like:

    Code
    RDK = Robolink()
    RDK.AddTaget(Name)
    Name.setPose(Position)


    There's already a small example of that in the local library you installed with RoboDK.
    C:/RoboDK/Library/Script -> Import_KUKA_SRC_Program


    You can find more info regarding our API here: API Documentation


    Jeremy

    RoboDK - Simulation and Offline programming software for industrial and collaborative robots.

    Visit us at RoboDK.com
    Take a look at our tutorial videos on our YouTube channel.

Advertising from our partners