1

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!

Community
  • 1
  • 1
Bob
  • 587
  • 8
  • 17

2 Answers2

1

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.

CommonsWare
  • 986,068
  • 189
  • 2,389
  • 2,491
  • Turning "completely off" would have to be a hack, then? And that obviously gets into the device specific realm, no? – Bob Jun 08 '12 at 15:21
  • @Bob: It's conceivable that there is some means to proactively turn off the backlight via non-SDK means, but I haven't a clue what they would be, and it is rather likely that such an approach would not work for all devices. – CommonsWare Jun 08 '12 at 15:26
  • Wouldn't have to work for all devices, just the one I'm using! So it seems I've got two options: 1) find a device that turns backlight off, or is good enough; 2) hack below the SDK. – Bob Jun 08 '12 at 15:35
1

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.

:)

Juan Cortés
  • 20,634
  • 8
  • 68
  • 91
  • Thanks, but that won't work, as I need to turn the screen off and on many times during an experiment; the subject isn't going to like having to do that! Good thinking, though. – Bob Jun 08 '12 at 15:38
  • @Bob I'm going to assume that `Settings.System.putInt(this.getContentResolver(), "SCREEN_BRIGHTNESS", 0);` doesn't work, right? – Juan Cortés Jun 08 '12 at 18:30
  • I don't know - I haven't purchased a tablet yet! That will be one of the first things I do try; from what @CommonsWare says, that may or may not work - device specific behavior. So unless someone has a tablet, tries that, is successful, and tells me, I'll have to experiment... – Bob Jun 08 '12 at 20:03