With Callbacks you can extend the functionality of Pally to your needs.

Your Waypoints or custom code in the Callback will automatically be executed when that specific events occur.

Some typical use examples for Callbacks are:

And many more..

Callbacks

Initial MoveJ node

Executed once on startup, after all configuration variables have been initialized. This allows runtime configuration changes and special tuning.

beforePallet

Before starting a new and empty pallet.

  • Start conveyor

  • Start other machine

  • Initialize variable that should be use trough the program

beforeZone

Before entering a new zone (typically a new layer on the pallet)

  • Lifting column control

  • Action before new layer or zone

onNextTask

Before starting all calculations for the next pick and place.

  • Modify path planning parameters dynamically

  • Prepare for custom motion towards the pick point

beforeGrab

Before lifting up a box from the pickup position. (gripper is placed onto the box)

  • Perform custom motion towards the pick point

  • Turn on vacuum

afterGrab

After lifting up a box from the pickup position. (gripper is placed onto the box)

  • Perform custom motion towards the target position on the pallet

  • If using a parallel gripper, close the gripper in this Callback

beforeRelease

Before releasing a box on the pallet (target position).

  • Turn off vacuum

afterRelease

After releasing a box on the pallet (target position).

  • If using a parallel gripper, open the gripper in this Callback

  • Perform custom motion from the pallet towards the waiting position

afterZone

After leaving a completed layer or zone.

  • Action after a layer or zone

onSheet

When a shim paper needs to be inserted. Add your own manual waypoints to shim/slip paper tray, pick the paper and move to a position over the pallet to where paper should be placed. See shim paper article for more information.

  • Start the shim paper routine

afterPallet

After the pallet is completed.

  • Stop conveyor

  • Stop other machine

Variables

The user-defined commands can utilize the values of the following global variables:

note

All variable below is Pally defined variables.

All variable below is Pally defined variables.

note

Example of a pose: p[0,0,0,0,0,0]

Example of a pose: p[0,0,0,0,0,0]

List of global variables in Pally

List of global variables in Pally

note

Some typical examples of uses for user-defined commands are to insert a shim paper, start and stop the conveyor, sort out inappropriate boxes to a waste bin, perform custom motion in very special layouts, control light signals and signal external machines, etc

Some typical examples of uses for user-defined commands are to insert a shim paper, start and stop the conveyor, sort out inappropriate boxes to a waste bin, perform custom motion in very special layouts, control light signals and signal external machines, etc

Examples

1. Full pallet timer

Timer for counting how long a full pallet would take. The value is presented in the RUN screen

2. Shim paper routine

The entry point of a user defined shim paper routine is the onSheet callback. Put your code here to define a robot trajectory suitable for inserting shim papers between layers.

URP’s is added outside the program and called on from the onSheet Callback

For better readability, we have extracted the shim paper logic into two separated subprograms:

Picking shim paper from a tray is common for both left and right pallets

Moving the shim paper to each pallet may be impemented separately

3. Change optimizer parameters for the next box

The entry point for changing optimizer parameters is typically the onNextTask callback, which is executed before all calculations begin.


4. Custom path

Control the robot motion directly when specfic events occur.