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

Add ROTATE_180 constant that rotates the screen 180 degrees to allow screen to be mounted inverted #173

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

ClevelandTechnologist
Copy link

@ClevelandTechnologist ClevelandTechnologist commented Jul 28, 2024

…mounting the screen inverted

Fixes #<GitHub-issue-number>.

Make sure all boxes are checked (add x inside the brackets) when you submit your contribution, remove this sentence before doing so.

<Description of and rationale behind this PR>

@ClevelandTechnologist
Copy link
Author

I'm working on my own variation of the desk clock, but I ended up with a setup that has the screen pins at the top. So, I created this patch to support rotating the screen 180*.

@@ -848,6 +851,7 @@ uint8_t changeScreen(TS_Point p, uint8_t screen) {
// if (p.x <= dividerMiddle) Serial.print(" right "); // <= 120
// Serial.println();

#ifndef ROTATE_180
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I personally don't like inverted if/else conditions. Can you start with the truthy condition (ifdef)?

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

Successfully merging this pull request may close these issues.

2 participants