File tree Expand file tree Collapse file tree 1 file changed +12
-1
lines changed
java/libraries/io/src/processing/io Expand file tree Collapse file tree 1 file changed +12
-1
lines changed Original file line number Diff line number Diff line change @@ -447,7 +447,18 @@ public static void releasePin(int pin) {
447447 * Waits for the value of an input pin to change
448448 * @param pin GPIO pin
449449 * @param mode what to wait for: GPIO.CHANGE, GPIO.FALLING or GPIO.RISING
450- * @param timeout don't wait more than timeout milliseconds (-1 waits indefinitely)
450+ * @webref
451+ */
452+ public static void waitFor (int pin , int mode ) {
453+ waitForInterrupt (pin , mode , -1 );
454+ }
455+
456+
457+ /**
458+ * Waits for the value of an input pin to change
459+ * @param pin GPIO pin
460+ * @param mode what to wait for: GPIO.CHANGE, GPIO.FALLING or GPIO.RISING
461+ * @param timeout don't wait more than timeout milliseconds
451462 * @return true if the interrupt occured, false if the timeout occured
452463 * @webref
453464 */
You can’t perform that action at this time.
0 commit comments