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

How to check for BOOL signal status over a specified time period

  • marlenehj
  • May 18, 2022 at 9:54 AM
  • Thread is Resolved
  • marlenehj
    Trophies
    2
    Posts
    21
    • May 18, 2022 at 9:54 AM
    • #1

    Hi everybody,

    System information:

    • KSS 8.7.3
    • HMI V 8.7 B442
    • Kernel system version KS V8.7.441
    • WorkVisual V6.0.22
    • KR C5 micro controller
    • KR 4 R600 robot

    I have an application, where I want to grip an object with a vacuum gripper (I do not have GripperSpotTech, just fyi). There is a vacuum sensor attached, which is supposed to record if vacuum has been lost, i.e. the object has been dropped accidentally or the vacuum is faulty. The signal is a BOOL, where a high signal means vacuum is on, and the object has been gripped, while a low signal means no vacuum has been established and hence no object has been gripped/the object has been dropped. As of now, the sensor is very sensitive despite setting the sensitivity way down, which means that small fluctuations in the signal occurs during movement of the robot arm, so the sensor will say the object has been dropped even though it is in fact still in the gripper.

    I am monitoring the sensor via a couple of interrupts, which will be triggered, if the object has been gripped (LOW-->HIGH), and if the object has been dropped (HIGH-->LOW). Right now, I'm just sending a warning to the PLC whenever the interrupt is triggered. However, to avoid falsely detecting that the bag has been dropped, I have to look at the signal over a period of time to see if it remains LOW or if the interrupt was triggered on a false-positive fluctuation.

    I was thinking that I'd like to start a timer once the interrupt is triggered and then check the signal again after the timer has run out, to see if it is still LOW, but I don't know the best way to do so without interfering with the motions of the main program.

    Does anybody have a suggestion on how this is best done?

    TIA!

  • panic mode
    Reactions Received
    1,297
    Trophies
    11
    Posts
    13,141
    • May 18, 2022 at 12:38 PM
    • #2

    First of all you want reliable signal. If the sensor you have is giving you false readings, it is not a bad idea to look for a substitute.

    If the glitches are brief, use debouncing to produce stable signal. And rest of the code (interrupts or whatever) should ,only use the debounced signal.

    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

  • panic mode
    Reactions Received
    1,297
    Trophies
    11
    Posts
    13,141
    • May 18, 2022 at 1:29 PM
    • #3

    One possibility is something like this

    Signal vac $IN[666]

    Decl boolvvac_stablw


    $timer_stop[1]=false

    If vac==false then

    $timer[1]=0

    Endif

    Vac_stable=$timer[1]>650: ms

    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

  • marlenehj
    Trophies
    2
    Posts
    21
    • May 18, 2022 at 3:14 PM
    • #4

    Thank you. I will give it a go.

    That's probably better than timing within the interrupt routine.

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
  • krc5
  • KRL
  • KUKA
  • motoman
  • Offset
  • PLC
  • PROFINET
  • Program
  • Programming
  • RAPID
  • 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
  • krc5
  • KRL
  • KUKA
  • motoman
  • Offset
  • PLC
  • PROFINET
  • Program
  • Programming
  • RAPID
  • roboguide
  • robot
  • robotstudio
  • RSI
  • safety
  • Siemens
  • simulation
  • SPEED
  • staubli
  • tcp
  • TCP/IP
  • teach pendant
  • vision
  • Welding
  • workvisual
  • yaskawa
  • YRC1000

Tags

  • Signal
  • vacuum
  • sensor
  • kr4
  • KR C5 micro
  • KR 4
  • KSS 8.7.3
  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