Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Suggestion: AMCP Command UID #475

Closed
jesperstarkar opened this issue Sep 6, 2016 · 6 comments
Closed

Suggestion: AMCP Command UID #475

jesperstarkar opened this issue Sep 6, 2016 · 6 comments

Comments

@jesperstarkar
Copy link
Contributor

If you send multiple commands at once, you need a way of identifying responses to match against the commands being sent. AMCP is not synchronous in its responses.

We need to maintain backwards compatibility in adding a new optional parameter to each command. We could either add new UID to the end of each command, given that the format of this UID is distinguishable and can not be mistaken for another payload parameter at all. Or, we could optionally add a prefix value before each command, i.e:

REQ sdfkjxcvxcv PLAY 1-10
RES sdfkjxcvxcv 202 PLAY OK

jesperstarkar added a commit to SuperFlyTV/casparcg-connection that referenced this issue Sep 7, 2016
HellGore pushed a commit that referenced this issue Jan 17, 2017
…y command to identify the response with a client specified request id, allowing a client to know exactly what asynchronous response matched a specific request.
@HellGore
Copy link
Contributor

It is building now.

@jesperstarkar
Copy link
Contributor Author

W.O.W !! This is the greatest news in a while! Thank you so much!

@jesperstarkar
Copy link
Contributor Author

It works so well. Cool!

@super-ienien
Copy link

Yeah ! So cool !

ronag pushed a commit to nxtedition/casparcg that referenced this issue Jan 16, 2018
…efore any command to identify the response with a client specified request id, allowing a client to know exactly what asynchronous response matched a specific request.

Former-commit-id: d896f42
ronag pushed a commit to nxtedition/casparcg that referenced this issue Jan 16, 2018
…efore any command to identify the response with a client specified request id, allowing a client to know exactly what asynchronous response matched a specific request.

Former-commit-id: d896f42
Former-commit-id: 37204ebd98b515805d99ddddd0192d5f0e14b5d1 [formerly 46d3689]
Former-commit-id: 2f550b38851d05a03b07a0a161b2381a3e9e2b3d
ronag pushed a commit to nxtedition/casparcg that referenced this issue Jan 16, 2018
…efore any command to identify the response with a client specified request id, allowing a client to know exactly what asynchronous response matched a specific request.

Former-commit-id: d896f42
Former-commit-id: 37204ebd98b515805d99ddddd0192d5f0e14b5d1 [formerly 46d3689]
Former-commit-id: 2f550b38851d05a03b07a0a161b2381a3e9e2b3d
Former-commit-id: 1b8b9c4108cd827533dc69e78661b54e4277c78a [formerly 78f0a09]
Former-commit-id: 06d4ddf1861168050514a8b065562ca88f6378c8
ronag pushed a commit that referenced this issue Jan 16, 2018
…y command to identify the response with a client specified request id, allowing a client to know exactly what asynchronous response matched a specific request.
ronag pushed a commit that referenced this issue Feb 7, 2018
…y command to identify the response with a client specified request id, allowing a client to know exactly what asynchronous response matched a specific request.

Former-commit-id: 43f3400
ronag pushed a commit that referenced this issue Feb 21, 2018
…y command to identify the response with a client specified request id, allowing a client to know exactly what asynchronous response matched a specific request.

Former-commit-id: 5ae60ba [formerly 43f3400]
Former-commit-id: a4e64b0
ronag pushed a commit that referenced this issue Feb 21, 2018
…y command to identify the response with a client specified request id, allowing a client to know exactly what asynchronous response matched a specific request.

Former-commit-id: 0415ca4 [formerly 0415ca4 [formerly b5d853b]]
Former-commit-id: 1bc9897
Former-commit-id: cb04e23
@PeterAkakpo
Copy link

Current implementation of the REQ command only focuses on just the instant response from the server. I think there should be a corresponding RES command that can be use to later query a layer for the UID.
REQ 12 PLAY 1-2 AMB ----> RES 12 202 PLAY OK
RES 1-2 ------> 12
this will further help client applications to easily set the current playing item after a shutdown.

@jesperstarkar
Copy link
Contributor Author

Hi @PeterAkakpo.

If I understand you correctly you want to be able to read out state from the server. I don't think your approach to calculate state by evaluating command responses will work for a couple of reasons:

  • Multiple commands affect the current state of a given layer. A PLAY and a MIXER combined will not reflect in your approach.
  • A positive command response doesn't mean the state has mutated. You can have 202 PLAY OK back without the video playing.

What you want to do is currently best done over OSC, and it seems like INFO will be added back to 2.2/2.3, and that's also a nice and simple approach.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants