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

Projection Design (projector) GetPower function incorrect for certain models #6

Open
scroix opened this issue Sep 13, 2016 · 0 comments

Comments

@scroix
Copy link
Member

scroix commented Sep 13, 2016

Tested with the Projection Design F12, F32 & F35 models.

The local_action_GetPower() function has a couple of issues when used to communicate with some of the PD models.

Looking at the protocol manual, all GET commands require a ' ? ' argument. This is actually missing from the recipe's function.

screen shot 2016-09-13 at 9 48 46 am

local_action_GetPower()
currently: result = send_cmd('POST')
should be: result = send_cmd('POST', '?')

A correct response to this message takes the form of :
%001 POWR 000001

The final argument (000001) being the response rcvpack[1] referenced in the send_cmd function.

A valid response isn't prefaced by an ' ! ' as the code suggests :

  if(result=='!00000' or result=='!00001'):
    print 'power is off'

'!' refer to a series of error codes in response to invalid commands, such as missing an argument.
screen shot 2016-09-13 at 9 57 21 am

Additionally, sending a '?' argument nullifies the related assert statement in the send_cmd function. As the response doesn't contain this character, unlike if you sent a numerical argument.
if(arg): assert arg in rcvpack[1]

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

No branches or pull requests

1 participant