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

program reset

  • jrobotics
  • April 18, 2023 at 1:04 PM
  • Thread is Unresolved
  • jrobotics
    Trophies
    1
    Posts
    10
    • April 18, 2023 at 1:04 PM
    • #1

    Hi, Im new to programming robots, currently working on my frist big project.

    Im working on KR120R2700_2 robot, KS V8.7.441, KR C5.

    I'm posting to request help with finding an error or finding the right path to do it.

    The robot works as an pick and place unit. There is a need to implement mechanism that detects if the product have been dropped. Im using a set of three inductive sensors that indicate whether the product it properly picked or not. Four interrupts are declared at the start of the program. Three interrupts are executed by xProductDropped subprogram which stops the robot, turns off the interrupts, opens gripper, sends information to PLC about the event, waits for acknowledge, sets reset_req bit on true and performs a homing procedure. Without implementing any additional mechanisms the robot will continue the program from the point where interrupt occured. At this point robot should start the program from the begining. The fourth interrupt declared check for the variable reset_req and is supposed to reset a program if it is true (which is after executing xProductDropped subprogram). I don't know what function to use to make the program reset itself. Or maybe there is another path of making program end/start from the begingin after an event occurs.

    The interrupts declaration:


    Code
          INTERRUPT DECL 11 WHEN di_sensorLeft==FALSE DO xProductDropped()
          INTERRUPT DECL 12 WHEN di_sensorMid==FALSE DO xProductDropped()
          INTERRUPT DECL 13 WHEN di_sensorRight==FALSE DO xProductDropped() 
          INTERRUPT DECL 14 WHEN b_reset_req==TRUE DO RESET

    xProductDropped subprogram:

    Code
    &ACCESS RVO1
    &REL 3
    &PARAM EDITMASK = *
    DEF  xProductDropped( )
       BRAKE F
       INTERRUPT OFF 11
       INTERRUPT OFF 12
       INTERRUPT OFF 13  
       BRAKE F
       xGripper(false);open gripped to drop product, if any left
       do_ProductDropped = TRUE
       b_reset_req = TRUE
       WAIT SEC 3
       do_ProductDropped = FALSE
       WAIT FOR di_ProductDroppedAck
       xHomingProcedure();  
     
    END
    Display More

    Whole sequence of event after dropping a product is properly executed: robot stops, gripper opens, robot sends a signal and waits for ack, and executes a homing procedure. The only thing thats not working is making the program reset.

    Ive searched the manuals that I have (KSS_82_SI_en) and found usage of GOTO function. But I also have problems with properly declare labels and use the GOTO function. I've tried to use functions like GOTO, JUMPTO, JUMP,BRA,RESET,ABORT and some other stuff.

    Thanks in advance for any help,

  • Fubini April 18, 2023 at 1:13 PM

    Approved the thread.
  • panic mode
    Reactions Received
    1,295
    Trophies
    11
    Posts
    13,130
    • April 18, 2023 at 3:39 PM
    • #2

    why use old manual for KSS8.2 (KSS_82_SI_en) when you are using much newer KSS (8.7)?

    three are rules when and unconditional jumps are possible. for example you cannot jump out of program or across incompatible blocks (for example from one CASE block to another, jumping into loop etc.).

    Code
    GOTO program_middle
    program_start:
    
    ; do something (part A)
    
    GOTO program_end
    program_middle:
    
    ; do something (part B)
    
    program_end:
    
    ; do something (part C)
    GOTO program_start
    Display More

    also i am way to skeptical that someone unable to figure out GOTO can understand how interrupts function. and one should not do anything time consuming inside interrupts, or something involving complex motions like moving robot through the maze even if one calls that home recovery (bringing robot home).

    same goes for selecting/cancelling/resetting program. all of this is documented and as stated in the documentation - this need to be done in another interpreter. if you want to start submit #4, you can do that from robot program or submit #7 or submit #2 but not from submit #4 (never itself). if you want to start (or reset) robot pram you can do that from one of submits bit from robot program itself.

    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

  • Hes
    Reactions Received
    42
    Trophies
    2
    Posts
    243
    • April 18, 2023 at 7:16 PM
    • #3

    just a sidenote but you can bind your sensors together in 1 $cycflag and use that as condition to trigger interrupt from any of your sensors instead of declaring 4 separate interrupts.

  • Mr.Question
    Trophies
    1
    Posts
    33
    • August 1, 2023 at 3:57 PM
    • #4
    Quote from panic mode

    why use old manual for KSS8.2 (KSS_82_SI_en) when you are using much newer KSS (8.7)?

    three are rules when and unconditional jumps are possible. for example you cannot jump out of program or across incompatible blocks (for example from one CASE block to another, jumping into loop etc.).

    Code
    GOTO program_middle
    program_start:
    
    ; do something (part A)
    
    GOTO program_end
    program_middle:
    
    ; do something (part B)
    
    program_end:
    
    ; do something (part C)
    GOTO program_start
    Display More

    also i am way to skeptical that someone unable to figure out GOTO can understand how interrupts function. and one should not do anything time consuming inside interrupts, or something involving complex motions like moving robot through the maze even if one calls that home recovery (bringing robot home).

    same goes for selecting/cancelling/resetting program. all of this is documented and as stated in the documentation - this need to be done in another interpreter. if you want to start submit #4, you can do that from robot program or submit #7 or submit #2 but not from submit #4 (never itself). if you want to start (or reset) robot pram you can do that from one of submits bit from robot program itself.

    Regarding those GOTO, what sets the end of the Marke/Label?

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

  • How to communicate with a EtherCAT device in KRL

    • chiachingyen
    • June 12, 2021 at 11:38 AM
    • KUKA Robot Forum
  • FD050 Noises, Trambling and returning Overload/speed error in multiple axis

    • Jonathan PAK
    • March 9, 2023 at 1:55 PM
    • Kawasaki Robot Forum
  • Triggering an Interrupt in cell.src

    • RemoteKRC
    • May 5, 2016 at 8:58 PM
    • KUKA Robot Forum
  • RPS switch wont turn on...

    • dj_adamix
    • June 23, 2022 at 10:29 PM
    • Kawasaki Robot Forum
  • $CYCFLAG mysterious behaviour

    • Hes
    • May 27, 2022 at 12:20 AM
    • KUKA Robot Forum
  • Cancel Program and Send Pointer to Cell.

    • PGG
    • August 31, 2017 at 10:40 PM
    • KUKA Robot Forum
  • Problem with the command SOUT

    • Draga
    • March 5, 2022 at 11:28 PM
    • Kawasaki Robot Forum
  • Kuka krc2 RESET DE PROGRAMA EN AUTOMÁTICO EXTERNO

    • Reiner Berbesi
    • February 28, 2022 at 10:05 PM
    • KUKA Robot Forum
  • PRIME JOB

    • Motouser
    • August 18, 2020 at 5:38 PM
    • Kawasaki Robot Forum
  • ABB Multimove: Launch a Robot B Proc from Robot A main routine?

    • OliveRobot
    • August 18, 2020 at 9:42 AM
    • ABB Robot Forum

Tags

  • interrupt
  • Reset
  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