Page 1 of 1

Repeating TCP/IP commands

Posted: 20 Mar 2023 18:06
by mixmog
I use a TCP/IP command to trigger an (software-based) on-air lamp (https://www.voceware.co.uk/products-vclock.aspx).

Is it possible to repeat such a command until cancelled?

The problem: should the PC which runs the on-air lamp restart, the lamp will return to it's default state (off) which doesn't necessarily reflect the state it should be.

The goal: to repeat or otherwise trigger the command until it is cancelled so that the on-air status is accurate.

Re: Repeating TCP/IP commands

Posted: 20 Mar 2023 19:19
by radio42
A command can not be repeated, as it is triggered by an event. So you can do two strategies:
1) Set the state at startup of ProppFrexx, ie. use the related Application event.
2) use an event which happens regularly to update your state. Eg. use a timer event (see the TI button at the bottom to eg. set this every 15 seconds or so…) OR use the Playlist.OnTrackPlay event, which happens with each new track being played.

Re: Repeating TCP/IP commands

Posted: 21 Mar 2023 10:15
by mixmog
Thanks Bernd.

I can see the timer. Could you possibly give an example of how this might work with a command?

Re: Repeating TCP/IP commands

Posted: 21 Mar 2023 10:36
by radio42
When you click on the TI button you can set a time interval to raise the "Application.OnTimer" event - e.g. set this to 15000 ms for every 15 sec.
In the Application.OnTimer event you can now specify the command to execute every 15 sec. (note, that global macros can be used here).
In the example below the command "PING Test" is being send.
Application.OnTimer.png

Re: Repeating TCP/IP commands

Posted: 21 Mar 2023 12:38
by mixmog
Much clearer, thank you

Ok, so I wonder if the timer event could be used to trigger a command to evaluate a parameter and result in an action?

Something like IF MIXER_INPUT_VOLUME_GET=1, EXEC_SEND_TCP?

Re: Repeating TCP/IP commands

Posted: 21 Mar 2023 22:57
by radio42
Conditional command-execution can be performed with the EXEC_COMMAND2 command. See the user manual appendix for details.
Conditional commands use macros to evaluate a condition.

There is currently no explicit macro for getting a specific mixer volume (note, that your example is lacking a mixer name)...
BUT there is a specific mixer event for this existing: make a right-click on a mixer name and select 'Edit Control-Command Event...'
Mixer.OnTimer.png
In this dialog you also have an OnTimer event and this executes on the specific mixer channel, e.g. you can use all mixer related macros!, like the ${mixervolume} - See the user manual appendix for further mixer macros.
E.g. here you could specify the following;

Code: Select all

EXEC_COMMAND2 ${mixervolume}|Equals(1)|SHOW_ALERT_WINDOW TEST
You'll see, it only executes, if this mixer channels volume is fully up (i.e. = 1).
Replace the SHOW_ALERT_WINDOW TEST command with your TCP call, as needed...

Re: Repeating TCP/IP commands

Posted: 28 Mar 2023 06:03
by mixmog
Thanks so much for the info, very useful!

Re: Repeating TCP/IP commands

Posted: 28 Mar 2023 07:36
by radio42
Note, that the new version contains a new macro function to conditionally execute a command and Evan its result, see:
EXEC_CONMAND2 [EXEC:{MIXER_INPUT_VOLUME_GET MIC1}]|Equals(1)|…