1. Home
    1. Dashboard
    2. Search
  2. Forum
    1. Unresolved Threads
    2. Members
      1. Recent Activities
      2. Users Online
      3. Team Members
      4. Search Members
      5. Trophys
  3. Articles
  4. Blog
  5. Videos
  6. Jobs
  7. Shop
    1. Orders
  • Login or register
  • Search
This Thread
  • Everywhere
  • This Thread
  • This Forum
  • Articles
  • Pages
  • Forum
  • Blog Articles
  • Products
  • More Options
  1. Robotforum - Support and discussion community for industrial robots and cobots
  2. Forum
  3. Industrial Robot Support and Discussion Center
  4. KUKA Robot Forum
Your browser does not support videos RoboDK Software for simulation and programming
Visit our Mainsponsor
IRBCAM
Robotics Channel
Robotics Training
Advertise in robotics
Sponsored Ads

Timer in kuka

  • capital9
  • June 9, 2022 at 2:33 PM
  • Thread is Unresolved
  • capital9
    Reactions Received
    3
    Trophies
    2
    Posts
    71
    • June 9, 2022 at 2:33 PM
    • #1

    hey guys,

    I am using KRC4, KSS 8.6.8

    i have a question regarding timer in KUKA.

    i just found out that even if the Timer is started in Robot program, the timer will continue even when the robot program stops.

    lets say,

    $timer[1]=0

    $timer_stop[1]=false

    wait for $timer[1]>10000

    $timer[1]=0

    $timer_stop[1]=true

    so if i run this program timer will basically stop after 10000 ms.

    but what if the program is somehow forced to stop by mean of external button or some emergency stop before 10000 ms.

    the timer will keep on going all the time.

    so i was looking for a solution where the timer stops when the robot program stops.

    can anyone help me with it?

  • panic mode
    Reactions Received
    1,268
    Trophies
    11
    Posts
    13,040
    • June 9, 2022 at 2:53 PM
    • #2

    simply use submit to stop the timer if program is not running

    $timer_stop[1]=not $pro_act

    or

    $timer_stop[1]=$pro_act=false

    or

    $timer_stop[1]=$pro_state1<>#p_active

    or similar...

    key documentation is your friend (Programming Manuals for Systems Integrators, System Variables Manual). for more info check READ FIRST

    1) read pinned topic: READ FIRST...

    2) if you have an issue with robot, post question in the correct forum section... do NOT contact me directly

    3) read 1 and 2

  • capital9
    Reactions Received
    3
    Trophies
    2
    Posts
    71
    • June 9, 2022 at 4:17 PM
    • #3

    thankyou very much for the idea,

    its not like i dont read those manuals, manuals are standard explanation.

    Manuals cant generate a good idea like you did for this.

    but anyways thankyou again,

    that way i can try to fix some problem, if i cant fix it maybe i will summon you again.

  • Mangesh Shenavi
    Reactions Received
    1
    Trophies
    1
    Posts
    80
    • July 15, 2022 at 12:07 PM
    • #4

    I also try this logic, but no any changes, timer running as it is even program stop.

    Where i have to use this logic ??

    In my program or in sps or in conf. ??

    Please explain in brief...

  • panic mode
    Reactions Received
    1,268
    Trophies
    11
    Posts
    13,040
    • July 15, 2022 at 3:39 PM
    • #5

    The only way for program instructions to be executed is if they are placed inside a program, program is linked (interpreted) and the code is valid

    Placing above in robot program can work while robot program is interpreted. But once the program is stopped, code is no longer processed.

    One solution is to place such code into a program that is normally processed all the time - submit interpreter

    1) read pinned topic: READ FIRST...

    2) if you have an issue with robot, post question in the correct forum section... do NOT contact me directly

    3) read 1 and 2

  • Mangesh Shenavi
    Reactions Received
    1
    Trophies
    1
    Posts
    80
    • July 16, 2022 at 6:44 AM
    • #6

    Still i am confuse in this, I used all yours optional code in my program but timer runnning as it is.

    Will you please explain that code with example. ??

    1.I want to reset timer 1

    2.Then i want to start timer 1

    3.After some working of robot i want to stop timer 1

    4.In between working of robot, if i stop the robot motion by help of hold button or by means of any external emergency stop pb, timer shold be stop, for that certain robo stop period.

  • SkyeFire
    Reactions Received
    1,044
    Trophies
    12
    Posts
    9,391
    • July 17, 2022 at 12:17 AM
    • #7
    Quote from Mangesh Shenavi

    1.I want to reset timer 1

    $TIMER[1] =0

    Quote from Mangesh Shenavi

    2.Then i want to start timer 1

    $TIMER_STOP[1] = FALSE

    Quote from Mangesh Shenavi

    3.After some working of robot i want to stop timer 1

    $TIMER_STOP[1] = TRUE

  • Mangesh Shenavi
    Reactions Received
    1
    Trophies
    1
    Posts
    80
    • July 17, 2022 at 5:38 AM
    • #8

    please help me for my 4th point also.!!

  • capital9
    Reactions Received
    3
    Trophies
    2
    Posts
    71
    • July 18, 2022 at 8:14 AM
    • #9

    Mangesh Shenavi if robot motion stops then, $robot_stopped = true

    if robot is moving then, $robot_stopped = false

    if robot_running_with_program == false then

    if $robot_stopped == true then

    $TIMER_STOP[1]=true

    endif

    endif

    robot_running_with_program, define this variable in config.dat, make it go true when robot program is running and if false turn it off. then use above code in SPS sub and you have to try everything by yourself, try to understand the behaviour of your own program and robot system variable.

  • Mangesh Shenavi
    Reactions Received
    1
    Trophies
    1
    Posts
    80
    • July 18, 2022 at 2:30 PM
    • #10

    Now i understand perfectly with your deep explanation....


    Thank you so much for help.

  • Mangesh Shenavi
    Reactions Received
    1
    Trophies
    1
    Posts
    80
    • July 19, 2022 at 6:55 AM
    • #11
    Quote from capital9

    Mangesh Shenavi if robot motion stops then, $robot_stopped = true

    if robot is moving then, $robot_stopped = false

    if robot_running_with_program == false then

    if $robot_stopped == true then

    $TIMER_STOP[1]=true

    endif

    endif

    robot_running_with_program, define this variable in config.dat, make it go true when robot program is running and if false turn it off. then use above code in SPS sub and you have to try everything by yourself, try to understand the behaviour of your own program and robot system variable.

    Display More

    I just try this code in my pendant

    Then contig.dat is in error.

    And the error is 'variable is longer than 24 character'


    What i have to do now ??

  • DS186
    Reactions Received
    199
    Trophies
    6
    Posts
    1,051
    • July 19, 2022 at 7:07 AM
    • #12

    Do what the message says, use a shorter name for that variable.

  • Mangesh Shenavi
    Reactions Received
    1
    Trophies
    1
    Posts
    80
    • July 19, 2022 at 7:45 AM
    • #13

    I will try this as soon !!

Advertising from our partners

IRBCAM
Robotics Channel
Robotics Training
Advertise in robotics
Advertise in Robotics
Advertise in Robotics

Job Postings

  • Anyware Robotics is hiring!

    yzhou377 February 23, 2025 at 4:54 AM
  • How to see your Job Posting (search or recruit) here in Robot-Forum.com

    Werner Hampel November 18, 2021 at 3:44 PM
Your browser does not support videos RoboDK Software for simulation and programming

Tag Cloud

  • abb
  • Backup
  • calibration
  • Communication
  • CRX
  • DCS
  • dx100
  • dx200
  • error
  • Ethernet
  • Ethernet IP
  • external axis
  • Fanuc
  • help
  • hmi
  • I/O
  • irc5
  • IRVIsion
  • karel
  • kawasaki
  • KRC2
  • KRC4
  • KRC 4
  • KRL
  • KUKA
  • motoman
  • Offset
  • PLC
  • PROFINET
  • Program
  • Programming
  • RAPID
  • robodk
  • roboguide
  • robot
  • robotstudio
  • RSI
  • safety
  • Siemens
  • simulation
  • SPEED
  • staubli
  • tcp
  • TCP/IP
  • teach pendant
  • vision
  • Welding
  • workvisual
  • yaskawa
  • YRC1000

Thread Tag Cloud

  • abb
  • Backup
  • calibration
  • Communication
  • CRX
  • DCS
  • dx100
  • dx200
  • error
  • Ethernet
  • Ethernet IP
  • external axis
  • Fanuc
  • help
  • hmi
  • I/O
  • irc5
  • IRVIsion
  • karel
  • kawasaki
  • KRC2
  • KRC4
  • KRC 4
  • KRL
  • KUKA
  • motoman
  • Offset
  • PLC
  • PROFINET
  • Program
  • Programming
  • RAPID
  • robodk
  • roboguide
  • robot
  • robotstudio
  • RSI
  • safety
  • Siemens
  • simulation
  • SPEED
  • staubli
  • tcp
  • TCP/IP
  • teach pendant
  • vision
  • Welding
  • workvisual
  • yaskawa
  • YRC1000

Similar Threads

  • KRC4 - Custom Weld Timer

    • notverycreeative
    • December 5, 2021 at 1:33 AM
    • KUKA Robot Forum
  • associate a timer to action

    • hugochab38
    • November 27, 2018 at 2:10 PM
    • KUKA Robot Forum
  • KUKA Ethernet KRL UDP

    • SiRi
    • May 31, 2022 at 6:42 PM
    • KUKA Robot Forum
  • How does the $STOPMESS get triggered

    • Sakya
    • March 4, 2016 at 7:49 AM
    • KUKA Robot Forum
  • Kuka safe robot

    • adaskox97
    • May 7, 2020 at 7:40 AM
    • KUKA Robot Forum
  • Kuka and directly connected sensors. Some hack ;)

    • Henry Sheppard
    • June 15, 2020 at 8:13 AM
    • KUKA Robot Forum
  • Kuka Multitasking parallel instruction

    • RoNNeZ
    • September 4, 2019 at 9:34 PM
    • KUKA Robot Forum
  • How to add a heart beat in the sps

    • plustandard
    • July 13, 2019 at 4:09 AM
    • KUKA Robot Forum
  • Maximum timer value

    • brianr
    • April 20, 2019 at 1:39 AM
    • KUKA Robot Forum
  • KUKA Automating Screw process

    • Anwal
    • September 26, 2018 at 11:50 AM
    • KUKA Robot Forum

Tags

  • KUKA
  • KRC4
  • timer
  1. Privacy Policy
  2. Legal Notice
Powered by WoltLab Suite™
As a registered Member:
* You will see no Google advertising
* You can translate posts into your local language
* You can ask questions or help the community with your knowledge
* You can thank the authors for their help
* You can receive notifications of replies or new topics on request
* We do not sell your data - we promise

JOIN OUR GREAT ROBOTICS COMMUNITY.
Don’t have an account yet? Register yourself now and be a part of our community!
Register Yourself Lost Password
Robotforum - Support and discussion community for industrial robots and cobots in the WSC-Connect App on Google Play
Robotforum - Support and discussion community for industrial robots and cobots in the WSC-Connect App on the App Store
Download