Note that there are some explanatory texts on larger screens.

plurals
  1. POAndroid SDK function not implemented
    primarykey
    data
    text
    <p>I apologize if this gets a bit vague, so please let me know if you'd recommend I rephrase or close the question.</p> <p>I'm running an Android device where one of the SDK functions isn't implemented. I'm attempting to dim the screen via a documented SDK call. This call works as expected on other devices, but does nothing on this one, which suggests to me that the function is not properly implemented on this phone. More confusingly, I can dim the brightness by directly manipulating writing to the /sys/class/backlight/... file from ADB (which is, as far as I can tell, as close as I can get to the driver for this system).</p> <p>The java code being called is below (brightness is some integer), and this is being targeted for Android 4.2.2.</p> <pre><code>Settings.System.putInt(getContentResolver(), Settings.System.SCREEN_BRIGHTNESS_MODE, Settings.System.SCREEN_BRIGHTNESS_MODE_MANUAL); Settings.System.putInt(getContentResolver(), Settings.System.SCREEN_BRIGHTNESS, brightness); </code></pre> <p>Basically, there's a disconnect somewhere, and I'm not sure where that would most likely be.</p> <p>Since this is a Dalvik app and is execiting Dalvik byte code, my first thought was, "well, maybe Dalvik wasn't compiled with the proper reference to the display driver". That would suggest that each android phone has its own uniquely-compiled version of Dalvik, which seems silly. My best current guess is that Dalvik goes through the hardware abstraction layer, and the HAL isn't aware of the brightness driver handle, while ADB file directly controls the brightness. Does this sound like a reasonable cause of such an issue? Does anyone have any other likely causes of such a class of bug? Thanks for your help.</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload