RobotStudio event

How to set up Multitasking correctly

I have searched for hours, here, in ABB litterature and on google. Everyone is talking about multitasking but nowhere to be found is a proper instruction of how to acutally set up multitasking. I have seen things like "semi-static", "parallell" and "multitasking". I want to have my robot doing it's things, but I also want a sensor to measure different distances and making calclulations with these measurements. The sensor is not corralated with the robot hence I want another program for it. I want a program that runs in the background at all times, as fast as an object moves in the way it is going to measure the max and min distances from the sensor as in the attached image. How do I set-up a task to run parallell and making calculations simultaneously? 




Comments

  • I might have found where I set up a new task now, but where do I put my code and make it run? I would have a pseudocode looking like this

    var mindist := 10000
    var maxdist := -10000
    WHILE sensed_object DO
    IF dist_to_object > maxdist THEN
    maxdist := dist_to_object;
    ELSE IF dist_to_object < mindist THEN
    mindist := dist_to_object;
    ENDIF
    ENDWHILE

    Just put it in the task and it will run in parallell?

    How do I send values or share values between tasks?
  • Maxim Riabichev
    edited September 19
    Hello,

    I'll try to put together a guide for setting up multitasking next week. But here's a hint for now (it's 00:13 in the morning/evening):

    See this post about sharing variables: https://forums.robotstudio.com/discussion/3815/multi-tasking/
    Post edited by Maxim Riabichev on

    Maxim Riabichev
    PC Software Support Engineer
  • Have you seen the attached extract from IRC5 controller software application manual?
  • Thanks, they really have to make these PDFs more readely avaliable...