Programming Pally Module

This article is written for Pally Module for Doosan cobot

To make a palletizer program, you’ll need to open the Task Editor.

Init Pally program node

This node is optional. You can configure callbacks and get access to the Pally context via this node.

Define Pally context global variable

This is required in order to access the Pally variables.

Define a global variable for Pally and initialize it to 0. The examples here use Global_pally_context.

Set up callbacks

Create your own subroutines that will be called at specific events during palletizing. Enter the name of each subroutine in the corresponding edit-box, or leave the edit box empty.

image (9)-20240719-114422.png
Configure Pally callbacks

 

Currently the following events are available:

  • beforePallet: Before starting a new empty pallet.

  • beforeZone: Before entering a new zone.

  • onNextTask: Before starting all calculations for the next box(es)

  • beforeGrab: Before lifting up a box from the pickup position.

  • afterGrab: After lifting up a box from the pickup position.

  • beforeRelease: Before releasing a box on the target position.

  • afterRelease: After releasing a box on the target position.

  • afterZone: After leaving a completed zone.

  • onSheet: When a shim paper needs to be inserted.

  • afterPallet: After the pallet is complete.

Access the Pally context

The Init Pally program node will return a variable called Global_pally_context which points to an object with configuration data inside the Pally module.

You can use Global_pally_context anywhere in the callback subroutines or below the Init Pally program node in the main program to change any Pally settings in runtime.

 

image-20240506-104759.png
Use Global_pally_context

 

In all Pally callbacks you can get access to the following variables via Global_pally_context:

  • ProductName: name of the current pattern

  • ProductCount: actual number of boxes on the pallet

  • PalletNr: actual pallet (1: right, 2: left)

  • ZoneNr: actual zone

  • LayerNr: actual layer

  • LayerAlt: distance from empty pallet to current layer

  • LayerHeight: height of the current layer (box height or shim paper height)

Currently there are some (experimental) settings in the Pally context that can be changed. Parameters and their default values are shown below:

max_speed = 1300
max_acceleration = 1300
precise_speed = 200
precise_acceleration = 200
grip_delay = 0.2
grip_release_delay = 0.2
blend = 0.3
force_palletizing_mode = False
trace_program_callbacks = False
gui_ip = "127.0.0.1"
set_workpiece_weight = False
gripper_weight = 2.6
gripper_cog = [0.0, -100.0, 50.0]

l1_sensors = [ [0, 1], [0, 2] ]
l2_sensors = []

pick_signals = [ [1, 1] ]
drop_signals = [ [1, 2] ]
vacuum_sensor = [1, 1]