AMX NetLinx NXB-KNX Instruction Manual Page 38

  • Download
  • Add to my manuals
  • Print
  • Page
    / 64
  • Table of contents
  • TROUBLESHOOTING
  • BOOKMARKS
  • Rated. / 5. Based on customer reviews
Page view 37
NetLinx Programming
32
NXB-KNX KNX Communications Gateway
DEFAULT: Counter = 0
}// Switch
IF (Counter)
{
Counter ++
}// IF (Counter)
}// WAIT
Example 2 - Structure of KNX-Table with SEND_COMMANDS
MODULE_NAME='KNX_Table_NXB_A'(DEV dvNxbKnx)
DEFINE_VARIABLE
integer counter
float waitVal
DEFINE_START
Counter=0
waitVal = .2
#INCLUDE 'KNX_Tools.axi'
DEFINE_EVENT
DATA_EVENT [dvNxbKnx]
{
ONLINE: //Start configuration upload when NXB-KNX comes online.
{
wait 10 //1 second delay
{
counter = 1
}
}
}
DEFINE_PROGRAM
WAIT waitVal
{
SWITCH(Counter) //Send config command in groups.
//Caution avoid sending large quantities of config commands
//without intermittent wait intervals.
{
CASE 1:
{
SEND_COMMAND DATA.DEVICE, "'ADD=5:Switch:1/1/4'" // Light 5 On/Off
SEND_COMMAND DATA.DEVICE, "'ADD=6:Switch:1/1/5'" // Light 6 On/Off
SEND_COMMAND DATA.DEVICE, "'ADD=11:Switch:1/1/34:PS'" // Light 5 status
SEND_COMMAND DATA.DEVICE, "'ADD=12:Switch:1/1/35:PS'" // Light 6 status
SEND_COMMAND DATA.DEVICE, "'ADD=20:Dim4:1/1/14'" // Dimmer relative light 5
SEND_COMMAND DATA.DEVICE, "'ADD=21:1Byte:1/1/24'" // Dimmer relative light 5
SEND_COMMAND DATA.DEVICE, "'ADD=22:1Byte:1/1/44:PS'" // Dimmer feedback light 5
SEND_COMMAND DATA.DEVICE, "'ADD=24:Dim4:1/1/15'" // Dimmer relative light 6
SEND_COMMAND DATA.DEVICE, "'ADD=25:1Byte:1/1/25'" // Dimmer absolute light 6
SEND_COMMAND DATA.DEVICE, "'ADD=26:1Byte:1/1/45:PS'" // Dimmer feedback light 6
SEND_COMMAND DATA.DEVICE, "'ADD=33:Switch:1/1/200'" // All lights ON/OFF
}
CASE 2:
{
SEND_COMMAND DATA.DEVICE, "'WHEN=5:22'" // Polltrigger
SEND_COMMAND DATA.DEVICE, "'WHEN=20:22'" // Polltrigger
SEND_COMMAND DATA.DEVICE, "'WHEN=21:22'" // Polltrigger
SEND_COMMAND DATA.DEVICE, "'WHEN=22:5'" // Polltrigger
SEND_COMMAND DATA.DEVICE, "'WHEN=6:26'" // Polltrigger
SEND_COMMAND DATA.DEVICE, "'WHEN=24:26'" // Polltrigger
SEND_COMMAND DATA.DEVICE, "'WHEN=25:26'" // Polltrigger
SEND_COMMAND DATA.DEVICE, "'WHEN=26:6'" // Polltrigger
SEND_COMMAND DATA.DEVICE,"'pollstart'" // Indicates to NXB-KNX that configuration
is complete
Page view 37
1 ... 37 38 39 ... 64

Comments to this Manuals

No comments