udifuchs / icc-brightness

Control OLED display brightness by applying ICC color profiles.
MIT License
170 stars 25 forks source link

ERROR: device-make-profile-default #13

Open MantasMikal opened 4 years ago

MantasMikal commented 4 years ago

I'm getting this error after running ./icc-brightness watch on Razer Blade 15 2019 OLED Kubuntu 19.04 Kernel: 5.3.0-050300-generic

ERROR: device-make-profile-default
Traceback (most recent call last):
  File "./icc-brightness", line 136, in main
    icc_brightness_apply()
  File "./icc-brightness", line 108, in icc_brightness_apply
    icc_brightness(brightness, max_brightness)
  File "./icc-brightness", line 85, in icc_brightness
    subprocess.check_output(['colormgr', 'import-profile', icc_filepath])
  File "/usr/lib/python3.7/subprocess.py", line 395, in check_output
    **kwargs).stdout
  File "/usr/lib/python3.7/subprocess.py", line 487, in run
    output=stdout, stderr=stderr)
subprocess.CalledProcessError: Command '['colormgr', 'import-profile', '/tmp/brightness_8400_24000.icc']' returned non-zero exit status 1.
^CTraceback (most recent call last):
  File "./icc-brightness", line 157, in <module>
    main()
  File "./icc-brightness", line 145, in main
    time.sleep(1000000)

What could be the issue here?

ncharles commented 4 years ago

I often have it when the default device is not the screen, but rather something else. Removing the device with colormgr may solve the issue

Davidnet commented 4 years ago

@ncharles how to remove the device?

ncharles commented 4 years ago

Running (as root) # colormgr get-devices lists all devices

For some reasons, other device may have priority over your screen, you can check which one is used by looking at the device with icc/brightness profiles

If you notice that it's not your screen that have it (most notable failure: the printer), you can remove the device with colormgr delete-device Object_Path_as_returned_by_colormgr

it may help

Note that since last week, icc_brightness doesn't work as I have an ACPI bios errors in my logs ( ACPI BIOS Error (bug): Could not resolve symbol [_SB.PCI0.PEG0.PEGP.BRT6.LCD], AE_NOT_FOUND (20190703/psargs-330) ), not related to icc-brightness but to a change in my firmware