Introduction

IEC 62386-301 describes DALI control devices that are defined as push buttons.

DALI control devices according to IEC 62386-301 correspond to instance type 1. The type of an instance can be queried with the function block FB_DALI103QueryInstanceType.

Input value

The current state (inputValue) of the push button can be queried via the function block FB_DALI103QueryInputValue. The value is 16#FF when the push button is actuated. The value is 16#00 when it is not actuated.

Timer

IEC 62386-301 defines specific timers with which the sending of the different events can be influenced.

The respective time is calculated from

Introduction 1:

Time

Multiplier

Preset value of the multiplier

Tincr incremental value

Tdefault default value

Tmin lowest possible set value

Tmax highest possible set value

 Tshort

 tShort

 Max (25, tShortMin)

 20 ms

 Max (25, tShortMin) * 20 ms

 tShortMin * 20 ms

 5100 ms

 Tdouble

 tDouble

 0

 20 ms

 tDoubleMin * 20 ms

 tDoubleMin * 20 ms

 2000 ms

 Trepeat

 tRepeat

 8

 20 ms

 160 ms

 100 ms

 2000 ms

 Tstuck

 tStuck

 20

 1 s

 20 s

 5 s

 255 s

tShortMin: Vendor-specific (see tShortMin).

tDoubleMin: Vendor-specific (see tDoubleMin).

Introduction 2:

Set the times so that as few events as possible are sent. If too many events are sent, this can have a negative effect on the behavior of the application.

Event filter

DALI control devices are capable of sending different events. The event filter consists of an 8-bit value, where each individual bit defines whether an event is disabled or enabled. The event is enabled if the corresponding bit is set, otherwise it is disabled.

The function block FB_DALI103QueryEventFilter can be used to read the value of the event filter; the function block FB_DALI103SetEventFilter can be used to write to it.

The event filter (see eventFilter) must be configured accordingly in order to trigger time-controlled events.

Bit

Event

Description

 0

Button Released

The push button was released.

 1

Button Pressed

The push button was pressed.

 2

Short Press

The push button was pressed and quickly released again without being pressed again (short button press).

 3

Double Press

The push button was pressed, released and quickly pressed again (double button press).

 4

Long Press Start

The push button was pressed without being released in between times (long button press).

 5

Long Press Repeat

If the push button was pressed for a long period (Long Press Start) without being released in between times, this event is sent at regular intervals.

 6

Long Press Stop

This event is sent if the push button is released after a long button press.

 7

Button Free / Button Stuck

If the push button is pressed for a very long time, it is assumed that it has stuck and the Button Stuck event is sent. Button Free is sent when the push button is detected as not pressed again.

Introduction 3:

Release only those events that you need for the application. If too many events are sent, this can have a negative effect on the behavior of the application.

Input Notification event

With instance type 1 it is possible to release different events with the help of the event filter. All events are sent from the DALI control device by a Input Notification and can be received with FB_DALIGetInputNotification.

The possible events (Event Name column) and their binary representation (Event Information column) are listed in the following table.

Event Name

Event Information

Description

Button Released

2#00_0000_0000

The push button was released.

Button Pressed

2#00_0000_0001

The push button was pressed.

Short Press

2#00_0000_0010

The push button was pressed and quickly released again without being pressed again (short button press).

Double Press

2#00_0000_0101

The push button was pressed, released and quickly pressed again (double button press).

Long Press Start

2#00_0000_1001

The push button was pressed without being released in between times.

Long Press Repeat

2#00_0000_1011

If the push button was pressed for a long period (Long Press Start) without being released in between times, this event is sent at regular intervals.

Long Press Stop

2#00_0000_1100

This event is sent if the push button is released after a long button press.

Button Free

2#00_0000_1110

Button Free is sent when the push button is detected as not pressed again following the Button Stuck event.

Button Stuck

2#00_0000_1111

If the push button is pressed for a very long time, it is assumed that it has stuck and the Button Stuck event is sent.

Short Press event

Introduction 4:

The Short Press event is triggered when the push button is released again within the time Tshort and not pressed again for at least the time Tdouble. If the push button is pressed again within the time Tdouble, a new Short Press event can be triggered.

Double Press event

Introduction 5:

The Double Press event is triggered when the push button is released within the time Tshort and pressed again before expiry of the time Tdouble.

Long Press Start, Long Press Repeat and Long Press Stop events

Introduction 6:

The Long Press event is triggered when the push button still remains pressed after expiry of the time Tshort. The time Trepeat subsequently starts. The Long Press Repeat event is triggered if this time has expired. If the push button remains pressed, the time Trepeat starts again and the Long Press Repeat event is triggered after each expiry.

The Long Press Stop event is triggered by releasing the push button.

Button Free and Button Stuck events

Introduction 7:

The Button Stuck event is triggered as soon as the push button was pressed for the time Tstuck without being released in between times. The Button Free event occurs immediately if the push button is released after the Button Stuck event.

The minimum set value for this time is 5 s; the default value is 20 s (see table above).

Note that the Long Press event does not temporally overlap the Button Stuck event, therefore the value should not be set too small.