Programming AMX Controllers for a Kaleidescape System
Programming Events
When the AMX master receives a volume control message, it will pulse the
standard AMX channel (unless an alternate channel has been defined as described
above) for the command on the virtual device of the player that received the
command. Button events for these channels can be created and used to trigger
actions that can raise, lower, or mute the volume in the zone. The code snippet
below shows a sample button event from the Kaleidescape Multiple Panel Include file
that will raise the volume in Zone1 when KPLAYER1 receives a volume up message.
BUTTON_EVENT [KPLAYER1, 24]
{
push:
{
do_push_timed (KZone1, 24, 1)
}
hold [5, repeat]:
{
do_push (KZone1, 24)
}
release:
{
do_release (KZone1, 24)
}
}
Programming Feedback
Volume level feedback can be sent to Kaleidescape controllers that support
feedback by setting level 55 of the player’s virtual device. When the volume level
changes, playerVolumeProperties[].volLevel should be updated with the new volume
level. The stored volume will be sent in response to VOLUME_QUERY.
LEVEL_EVENT [KZone1, 1]
1
{
stack_var integer scaledVolume
scaledVolume = type_cast(level.value/2.55)
send_level KPLAYER1, 55, scaledVolume
playerVolumeProperties[1].volLevel = scaledVolume
}
1
Comments to this Manuals