Home AMX User Forum AMXForums Archive Threads AMX Applications and Solutions

Modero programming

I'm trying to program a CV7 to enable/disable a button programatically.

I'm using the following command to attempt to change the status of the button on channel 120 but it's NOT working;

SEND_COMMAND dvTouchPanel, "'^BMF-120,0,%EN1'"

Any ideas, anyone?

Comments

  • The %EN1 or %EN0 will enable or disable the function of a button.

    With %EN0, the button will not do any operation when it's pushed, although it may have a channel code.

    With the ^BMF- commands, you can change almost anything of a button (color, border, etc...). But to change it from off to on state, you have to turn it ON by master

    Another way may be to set it with "%OTInvert" into the ON state, although the button's channel is still off, but... ;)
  • feedback port

    Also you can use the feedback loop port on the touchpanel to achieve the same effect rather than programming it in NetLinx Studio. Sometimes this can be handy. Just set the the command port of the button to 0 and then set your send_commands up in the Command output parameter in TPD4
  • The command looks correct, but you need to give the buttons you wish to address an "Address" code. It looks like you are trying to send the command to address 120, but you haven't given the button that address code. Address codes and Channel codes are separate. This is a comon mistake. Also when you disable a button all of the color information is removed from the button, this is similar to a windows button that is disabled.

    FYI: There is also "show" and "hide" these also disable/enable the buttons, however when a button is hidden it is made invisible.

    Hope this helps.
  • The command looks correct, but you need to give the buttons you wish to address an "Address" code. It looks like you are trying to send the command to address 120, but you haven't given the button that address code. Address codes and Channel codes are separate.
    Thanks, that was exactly what it was!
    This is a comon mistake.
    Phew! At least I'm not going barmy, then ;)
  • I'm glad I could assist you.
Sign In or Register to comment.