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

Code comment seems to conflict with code #17

Closed
peterhinch opened this issue Jan 13, 2021 · 2 comments
Closed

Code comment seems to conflict with code #17

peterhinch opened this issue Jan 13, 2021 · 2 comments

Comments

@peterhinch
Copy link
Contributor

peterhinch commented Jan 13, 2021

This doc and this code seem to conflict. This is of concern because it affects the Vcom voltage. I think the intention is to specify -1.0V where you may be setting -2.6V.

b"\x82\x81\x12\x32"  # VCM DC and delay 50ms

The doc implies that the delay is the third byte (0x12 == 18ms) with a single data value in the fourth byte (0x32, which happens to equal 50). I think the code should read:

b"\x82\x81\x32\x12"  # VCM DC and delay 50ms

The doc itself is ambiguous because it states

When the top bit of the second byte is 1, the next byte will be the delay time in milliseconds.

This implies that the third byte is the delay time, but it then goes on to say

The third through final bytes are the remaining command parameters.

I think that should read the fourth through final bytes, but clarification would be appreciated.

@tannewt
Copy link
Member

tannewt commented Jan 13, 2021

The doc is incorrect. I fixed this internally but didn't realize it was here as well. See the fix here: adafruit/circuitpython@9da9967#diff-cd8ed509bcd7add61d99b42d41f3674916a6f91a2302914d6fd6641acf021944

@peterhinch
Copy link
Contributor Author

Thank you, the code and code comments are therefore correct.

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

2 participants