Running full-screen Android application with screen/backlight off

1.6k views Asked by At

Here's what I need to do. I want to use an Android tablet for science research, but I will need to programmatically control the screen/backlight. Specifically, there is a mode where my app will need to communicate with other systems via WiFi, play sounds, and have the touchscreen active, but the backlight must be completely off; in this mode, the device cannot emit any light, or it will interfere with the science. Obviously, this cannot be sleep mode! Is this feasible?

I've looked around a bit, and this sounds really promising, but it isn't crystal-clear (to me, anyway!) whether this will work. Can anyone vouch for that?

Finally, does it matter which tablet I choose? Basically, there seem to be three possibilities: the backlight is controlled with a switch (doubt that is done anymore), the CPU can only turn it on or off, or the CPU can adjust it fully. Writing this makes me feel rather silly about being concerned, but a Samsung rep yesterday told me I can't do this on the Galaxy. Anyone care to recommend a tablet?

Thanks!

2

There are 2 answers

3
CommonsWare On

Specifically, there is a mode where my app will need to communicate with other systems via WiFi, play sounds, and have the touchscreen active, but the backlight must be completely off

Android does not support "have the touchscreen active, but the backlight must be completely off". And, you do not have the ability to turn the backlight "completely off" programmatically.

I've looked around a bit, and this sounds really promising

That sets the backlight to be low. Some devices may elect to turn the backlight off when it is set low. That is up to the device manufacturer.

Finally, does it matter which tablet I choose?

See above.

3
Juan Cortés On

Since its a science research I'm going to assume you may not need to divulge this application and want it in a controlled environment. If this is the case, a little creative thinking suggests that since the touch screen will still react to even if covered by a thin layer of plastic (like the screen protectors for instance) you may be able to apply some opaque vinyl on top of the screen (easy to remove) for doing the experiments.

This may not be useful but since to me it sounded like it could I thought I'd share my thoughts with you on this one. Once you've covered the screen with the vinyl, the rest is as usual, keep screen on, and do your magic.

:)