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

BUG - PTU::getMode() returns wrong value (flir D48E) #28

Open
marklewis3000 opened this issue Sep 6, 2016 · 0 comments
Open

BUG - PTU::getMode() returns wrong value (flir D48E) #28

marklewis3000 opened this issue Sep 6, 2016 · 0 comments

Comments

@marklewis3000
Copy link

EASY FIX: compare to uppercase

The D48E responds to the 'C' query control mode with an uppercase 'P' or 'I', but the driver.cpp compares to lowercase, resulting in an error returning (-1) :
if (buffer[2] == 'p')
return PTU_VELOCITY;
else if (buffer[2] == 'i')
return PTU_POSITION;

This could be fixed like this:
(buffer[2] == 'p' || buffer[2] == 'P' )
(buffer[2] == 'i' || buffer[2] == 'I' )

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