UV_K5_playground icon indicating copy to clipboard operation
UV_K5_playground copied to clipboard

[Feature Request] Longer ABR time

Open SirioSechi opened this issue 1 year ago • 3 comments

Hi Currently in the menu ABR (settings for the time of the backlignt) is OFF; 1; 2; 3; 4; 5. My proposition is to give more time until 10 seconds, such: OFF; 2; 4; 6; 8; 10.

Thank you.

SirioSechi avatar Aug 03 '23 16:08 SirioSechi

@SirioSechi This is now possible with a uvmod-kitchen patch: https://github.com/amnemonic/Quansheng_UV-K5_Firmware/blob/main/uvmod_kitchen/mod_double_abr_values.py

Tunas1337 avatar Aug 09 '23 07:08 Tunas1337

The backlight is controlled by following code.

// Enable backlight function.
  uVar1 = ABR_time;
  if (uVar1 != 0) {
    set_bit(&GPIO_PORTB,6);
    uVar1 = ABR_time;
    screen_timer = uVar1 * 2 + 1; //tick seems 0.5s
  }
// turn off backlight, in somewhere of main loop.
      timeleft = screen_timer?;
      screen_timer = timeleft -1;
      if ((timeleft !=0) && screen_timer == 0 ) {
        clear_bit(&GPIO_PORTB,6);
      }

Another possible solution for backlight control is to mask out the turn off code section and create a separate function to handle the backlight's shutdown. In this case, we could get more control for backlight. Such as

  • never turn off backlight when charging
  • one key switch backlight auto turn off /never turn off.

tywtyw2002 avatar Aug 11 '23 22:08 tywtyw2002

Is it possible to integrate it by default in all new versions? I think it is a useful improvement.

SirioSechi avatar Aug 20 '23 10:08 SirioSechi