For a while (I'm not sure exactly when it started happening, but I suspect it was after a recent update) wlsunset is not setting the temperature correctly on river-0.2.6:
$ wlsunset -t 4500
registry: adding output 34
calculated sun trajectory: midnight sun
setting temperature on output '34' to 6500 K
This is my actual display:
$ wlr-randr
eDP-1 "LG Display 0x40A9 (eDP-1)"
Make: LG Display
Model: 0x40A9
Serial: (null)
Physical size: 310x170 mm
Enabled: yes
Modes:
1920x1080 px, 59.977001 Hz (preferred, current)
1920x1080 px, 60.030998 Hz
1920x1080 px, 50.026001 Hz
1920x1080 px, 48.007999 Hz
1680x1050 px, 59.977001 Hz
1280x1024 px, 59.977001 Hz
1440x900 px, 59.977001 Hz
1280x800 px, 59.977001 Hz
1280x720 px, 59.977001 Hz
1024x768 px, 59.977001 Hz
800x600 px, 59.977001 Hz
640x480 px, 59.977001 Hz
Position: 0,0
Transform: normal
Scale: 1.000000
Adaptive Sync: disabled
This is happening with commit 80fb589
and wayland version 1.22.0 .
This is what happens when running with debug output:
$ WAYLAND_DEBUG=1 wlsunset -t 4500
[3875021.548] -> wl_display@1.get_registry(new id wl_registry@2)
[3875021.578] -> wl_display@1.sync(new id wl_callback@3)
[3875021.733] wl_display@1.delete_id(3)
[3875021.747] wl_registry@2.global(1, "wl_shm", 1)
[3875021.757] wl_registry@2.global(2, "wl_drm", 2)
[3875021.764] wl_registry@2.global(3, "zwp_linux_dmabuf_v1", 4)
[3875021.771] wl_registry@2.global(4, "wl_compositor", 5)
[3875021.778] wl_registry@2.global(5, "wl_subcompositor", 1)
[3875021.785] wl_registry@2.global(6, "xdg_wm_base", 2)
[3875021.792] wl_registry@2.global(7, "zwlr_layer_shell_v1", 4)
[3875021.800] wl_registry@2.global(8, "zwlr_foreign_toplevel_manager_v1", 3)
[3875021.806] wl_registry@2.global(9, "xdg_activation_v1", 1)
[3875021.815] wl_registry@2.global(10,
"zwp_primary_selection_device_manager_v1", 1)
[3875021.823] wl_registry@2.global(11, "zxdg_decoration_manager_v1", 1)
[3875021.835] wl_registry@2.global(12, "zxdg_output_manager_v1", 3)
[3875021.843] wl_registry@2.global(13, "zwlr_output_manager_v1", 4)
[3875021.850] wl_registry@2.global(14, "zwlr_output_power_manager_v1", 1)
[3875021.856] wl_registry@2.global(15, "ext_idle_notifier_v1", 1)
[3875021.862] wl_registry@2.global(16, "zwp_pointer_constraints_v1", 1)
[3875021.873] wl_registry@2.global(17, "zwp_relative_pointer_manager_v1", 1)
[3875021.882] wl_registry@2.global(18, "zwlr_virtual_pointer_manager_v1", 2)
[3875021.889] wl_registry@2.global(19, "zwp_virtual_keyboard_manager_v1", 1)
[3875021.897] wl_registry@2.global(20, "wl_seat", 8)
[3875021.905] wl_registry@2.global(21, "zwp_pointer_gestures_v1", 3)
[3875021.912] wl_registry@2.global(22, "zriver_control_v1", 1)
[3875021.919] wl_registry@2.global(23, "zriver_status_manager_v1", 4)
[3875021.926] wl_registry@2.global(24, "river_layout_manager_v3", 2)
[3875021.933] wl_registry@2.global(25, "zwp_idle_inhibit_manager_v1", 1)
[3875021.940] wl_registry@2.global(26, "ext_session_lock_manager_v1", 1)
[3875021.948] wl_registry@2.global(27, "wl_data_device_manager", 3)
[3875021.955] wl_registry@2.global(28, "zwlr_data_control_manager_v1", 2)
[3875021.962] wl_registry@2.global(29, "zwlr_export_dmabuf_manager_v1", 1)
[3875021.969] wl_registry@2.global(30, "zwlr_gamma_control_manager_v1", 1)
[3875021.978] -> wl_registry@2.bind(30,
"zwlr_gamma_control_manager_v1", 1, new id [unknown]@4)
[3875021.987] wl_registry@2.global(31, "zwlr_screencopy_manager_v1", 3)
[3875021.994] wl_registry@2.global(32, "wp_single_pixel_buffer_manager_v1", 1)
[3875022.001] wl_registry@2.global(33, "wp_viewporter", 1)
[3875022.009] wl_registry@2.global(34, "wl_output", 4)
registry: adding output 34
[3875022.024] -> wl_registry@2.bind(34, "wl_output", 4, new id [unknown]@5)
[3875022.034] wl_callback@3.done(4913)
[3875022.043] ->
zwlr_gamma_control_manager_v1@4.get_gamma_control(new id
zwlr_gamma_control_v1@3, wl_output@5)
[3875022.051] -> wl_display@1.sync(new id wl_callback@6)
[3875022.233] wl_display@1.delete_id(6)
[3875022.260] wl_output@5.geometry(0, 0, 310, 170, 0, "LG Display", "0x40A9", 0)
[3875022.273] wl_output@5.mode(1, 1920, 1080, 59977)
[3875022.280] wl_output@5.scale(1)
[3875022.286] wl_output@5.name("eDP-1")
[3875022.300] wl_output@5.description("LG Display 0x40A9 (eDP-1)")
[3875022.306] wl_output@5.done()
[3875022.313] zwlr_gamma_control_v1@3.gamma_size(4096)
[3875022.437] wl_callback@6.done(4913)
calculated sun trajectory: midnight sun
setting temperature on output eDP-1 (34) to 6500 K
[3875023.189] -> zwlr_gamma_control_v1@3.set_gamma(fd 7)
I'd be happy to provide more information if required. :-)
Turns out
-T
works. Either-t
used to work before, or I'm going insane!
Please feel free to close this.
On 3/24/24 08:40, ~Khalid Bin Walid wrote:
Turns out
-T
works. Either-t
used to work before, or I'm going insane!
-t
sets the low temperature target for dimming,-T
sets the high temperature target for normal operation.Make sure you set your position with
-l <lat> -L <long>
for automatic sun tracking, or alternatively specify manual sunrise/sunset times with-S
and-s
.
Thanks for your comment. I was aware of those options, but I wanted to always reduce blue light regardless of the time of day, and found that simply using the
-t
option worked.If it was indeed working with the
-t
option before, I think it did because it was assuming that it was night and hence time to set the low temperature, but now it assumes the opposite for some reason.On Sun, Mar 24, 2024 at 7:06 PM ~kennylevinsen outgoing@sr.ht wrote:
On 3/24/24 08:40, ~Khalid Bin Walid wrote:
Turns out
-T
works. Either-t
used to work before, or I'm going insane!
-t
sets the low temperature target for dimming,-T
sets the high temperature target for normal operation.Make sure you set your position with
-l <lat> -L <long>
for automatic sun tracking, or alternatively specify manual sunrise/sunset times with-S
and-s
.-- View on the web: https://todo.sr.ht/~kennylevinsen/wlsunset/13#event-337888
Unless you set
-s
/-S
, wlsunset runs in sun tracking mode. No lat/lon just means it runs assuming coordinates 0,0, making your test results dependent on time of day. Nothing should have changed in this regard.You can force a mode by sending SIGUSR1 to wlsunset, but that's meant for dynamic control. You can also just specify both -t and -T to the same value, but it's a little silly and I'm not sure if the math will break.
This is not really an intended usecase, as fixed color adjustments can usually just be made on the monitor.