4Devs: Pad & Shift Manager (Include) v3.1

Multi-pad or SHIFT single-/double-/triple-tap & hold interaction support script with user functions, intended to be easily included into your own scripts.

The pad manager delays all pad or shift-button reactions by a small time amout to be able to analyse the interactions for single/double/triple taps and optional holds.
After the analyse time has passed, the user callback events OnPad or OnShift are called with parmeters set.

It is possible to exclude specific pads or all pads or the shift button from the analysis. In this sample the last pads of each row react directly, calling OnPad without any analysis delay.

If needed, the main timer can be managed by your script.

All user defined settings are done via variables in the OnLoad, no need to modify anything inside the Pad Manager script part of the source.

Originally based on
Single Tap, Double Tap, and Tap-and-Hold by Bryan Appel

.

More Info
———————
The blue ‘source code’ button to the right links to a in depth description containing the source code and instructions on how to add the snippet to own scripts

Author
1161 PM
  • Platform:
  • Category: Utility
  • Revision: 3.1
  • License: Creative Commons Attribution Share Alike 4.0
  • Views: 838
  • Modified: 2 months ago
Chat about this patch on Discord! Download (46) Source Code
Appreciate 5
6 comments on “4Devs: Pad & Shift Manager (Include) v3.1
  • wim-number37 on said:

    Thanks! Nicely done. You saved me a bunch of time and did it better than I would have. 👏

  • -ki on said:

    Added ‘4Devs:’ to title and ‘for developers’ tag to indicate that this script is intended for script developers

  • -ki on said:

    Updated to v3.0
    – Added shift button single/double/hold functionality
    – Updated instructions
    – It is possible to define overload the shift or pad functionality with on user events to only use one of the features.

  • -ki on said:

    Updated to v3.0.1
    – Changed formatting and description

  • -ki on said:

    Updated to 3.1
    – Much simplified user callback events (2 with params instead 6)
    – Support for multi-taps depending on the configured analysis time
    – Can detect double-tap-hold versus double-tap (time >= 250)
    – Can detect triple-tap-hold versus triple-tap (time >= 300)
    – Less internal functions and variables
    – HELP knob to show documentation (with double tap support)

  • -ki on said:

    Added source code/documentation link to Audiobus Forum Wiki

  • Leave a Reply