vMix Forums
»
General
»
3rd Party Software and Development
»
TCP command ASCII stucture and listening to return values
Rank: Newbie
Groups: Registered
Joined: 4/21/2020(UTC) Posts: 9 Location: California Thanks: 2 times Was thanked: 1 time(s) in 1 post(s)
|
HELLO ALL! Happy Holidays where ever you are. This is my first post.
Wanted to say THanks in advance for any light someone could shed on getting this to happen. I've got some good basic working knowlege of getting apps to talk to each other via TCP and using the API, I'm struggling here to get a return message from Vmix. I'm using COOLUX Widget Designer 6.1 to build an interface which will give me feedback on what is live to screen (Tally) and also if certain routes have been made. I see on the TCP API.
Here is one question. I see that there is a subscribe in the API. Do I have to subscribe to each event I'd like data on?
for Example sending ASCII text via TCP: "SUBSCRIBE TALLY\r\n" would return to me return feed from VMIX: "SUBSCRIBE OK TALLY\r\n" in ASCII.
For the request, I have not seen any feedback from VMIX at all. Does VMIX replay on a differrent port than 8099?
ALL THanks so much for any support or ideas you may have for me to try, I'm going to continue to chip away, will report back with any updates.
The end goal is to produce an "overlay" of the MULTIVIEW we let clients see, with some additional information provided by the scripting I will be doing.
Happy Holidays Chris
|
|
|
|
Rank: Newbie
Groups: Registered
Joined: 4/21/2020(UTC) Posts: 9 Location: California Thanks: 2 times Was thanked: 1 time(s) in 1 post(s)
|
OK So I found a solution to get VMIX talking to Widget Designer 6
Here is the basic sytax I had to use.
TCPSend(1,"SUBSCRIBE TALLY[CR LF]")
I had to swap the \r\n out for [CR LF] to get everything singing. Now to parse the info.
One Other Question was..... a list of items I can get feedback from.
I'm looking to get the VideoCallVideoSource data. SO I can produce an image for clients.
|
1 user thanked Cali_Chris for this useful post.
|
|
|
Rank: Newbie
Groups: Registered
Joined: 11/17/2020(UTC) Posts: 5 Location: Villach Thanks: 4 times
|
Hi Chris! Nice to see another Widget Designer user. I just tried your approach and got it working. Looks very easy to parse the info. I used a different approach to get the tally - via the http web API of vMix: http://127.0.0.1:8088/api/? gives you a respond with all vMix informations. I requested that every 500ms and wrote the respond into a variable. Than I filtered it until i only got the number of the active input. Today i found a much easier method to archieve this: Enable the HTTP listener in Widget Designer (Connections - Remoting) Create the following script in vMix to send any command to Widget Designer: Quote:Dim webStream As Stream Dim webResponse = "" Dim req As HttpWebRequest Dim res As HttpWebResponse req = CType(WebRequest.Create(" http://127.0.0.1:80/?{WDCustomScriptClick(1)}"), HttpWebRequest) res = CType(req.GetResponse(), HttpWebResponse) webStream = res.GetResponseStream() ' Get Response Dim webStreamReader As New StreamReader(webStream) While webStreamReader.Peek >= 0 webResponse = webStreamReader.ReadToEnd() End While Then trigger this script with OnTransiton in on any Input. I could't find a solution to get the VideoCallVideoSource data. How do you change / use it? Maybe you could trigger it with a shortcut that sends a simultanious feedback to Widget Designer. Best, Thomas
|
|
|
|
Rank: Advanced Member
Groups: Registered
Joined: 1/27/2019(UTC) Posts: 34 Location: Bern Thanks: 5 times Was thanked: 5 time(s) in 5 post(s)
|
Hi,
did you get able to change the colours then, e.g. on a button? I'm struggling on this, to "read out" the answer from vmix, and make than a change on colours for buttons (PGM/PVW).
Any hint for me? ;)
And for the VideoCallVideoSource - the command will be: TcpSend(1, "FUNCTION VideoCallVideoSource Input=x&Value=Output1[CR LF]") (or Output 2, Output x)
The Input X will be your VideoCall-Input
Thanks, and regards Thomas
|
|
|
|
vMix Forums
»
General
»
3rd Party Software and Development
»
TCP command ASCII stucture and listening to return values
Forum Jump
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.
Important Information:
The vMix Forums uses cookies. By continuing to browse this site, you are agreeing to our use of cookies.
More Details
Close