uArm Vacuum Head Switch Control

Hi,

I am trying to make a program that has a feature that will decrease the z axis (go down) until the vacuum head suction cup hits the top of a stack. There is a switch on the vacuum head that should tell the uArm when it is fully pressed down and use that signal as an interrupt, however I cannot find what code will allow for this. Can someone direct me to either documentation or an example of how to access and use this signal?

Thank you

In uarm_library.h, you can see the declaration:

#define STOPPER                 2    // LOW = Pressed

So, all you need do is:

if (digitalRead(STOPPER) == LOW) {
  Serial.println("Stopper is pressed!");
}

A technique that I have found useful is to move the arm downwards a centimeter at a time (“AtOnce”) rather than slowly. It helps to keep the stopper pin from binding and failing to register at first.

1 Like

Thank you, this is very helpful.

Do you know if there is documentation for the library so that I can understand how, when and why to use the different functions?

I didn’t find explicit documentation for the library but look at the examples given with the help of uarm_library.h, you can understand how to use these functions.

If you have not seen it yet, there is also http://developer.ufactory.cc/api/arduino/

But I agree with @Waru that looking at the examples and reviewing the code directly are your best avenues to understanding. :slight_smile: