Skip to content

Disable sleep while in Paddle app#553

Closed
stoehraj wants to merge 1 commit intoInfiniTimeOrg:developfrom
stoehraj:develop
Closed

Disable sleep while in Paddle app#553
stoehraj wants to merge 1 commit intoInfiniTimeOrg:developfrom
stoehraj:develop

Conversation

@stoehraj
Copy link

@stoehraj stoehraj commented Aug 3, 2021

Paddle.cpp: Added systemTask to disable sleeping in the constructor and
re-enable sleeping in the destructor. Reformatted constructor function
header to match that of FlashLight.cpp due to added length.

Paddle.h: Added include for SystemTask.h. Added SystemTask parameter to
constructor function prototype and added a private SystemTask variable.

DisplayApp.cpp: Added systemTask pointer to make_unique() function call.

Paddle.cpp: Added systemTask to disable sleeping in the constructor and
re-enable sleeping in the destructor.  Reformatted constructor function
header to match that of FlashLight.cpp due to added length.

Paddle.h: Added include for SystemTask.h.  Added SystemTask parameter to
constructor function prototype and added a private SystemTask variable.

DisplayApp.cpp: Added systemTask pointer to make_unique() function call.
@stoehraj
Copy link
Author

stoehraj commented Aug 3, 2021

Problem mentioned in issue #398

@Riksu9000
Copy link
Contributor

InfiniTime won't sleep while touching the screen anymore after #492 was merged, so this isn't necessarily needed anymore.

@Dudemanjude
Copy link

I would still find this useful, as the screen will often timeout for me in the Paddle app, because I like my screen timeout set to 5 seconds.

@Riksu9000
Copy link
Contributor

It is true that the timeout should be longer than 5s while in the paddle game, but by disabling sleep altogether, there is the danger of forgetting to close it and the battery draining quickly. This is also an issue with Flashlight currently, and it should be fixed. There needs to be a more complete solution to this.

Closing due to inactivity.

@Riksu9000 Riksu9000 closed this Feb 7, 2022
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.

3 participants