Bugzilla – Bug 12756
Alarm clock function AM/PM difficult to set
Last modified: 2010-04-08 17:24:45 UTC
When setting up the alarm clock function using the small remote the hours and minutes setup easily. However the AM PM selection is very touchy when the remote key is pressed it rapidly cycles through AM PM multiple times often resulting in no change. Only with a very quick touch was I able to get it to update. This problem was only apparent while selecting AM or PM.
QA Confirmed. only happens with the IR remote, front panel knob is OK. Adrian: can you have a look at this one?
This is a problem with Slim::Buttons::Common::scroll_dynamic for short lists - this will always wrap the list when you go up/down. With the rubber button on the small remote its more likely you get two button presses which means it moves back to where you started with... I think this function should implement a pause at each end of the list all the time rather than only doing it when scrolling kicks in. Caleb?
How about ONLY allowing adjustment via the hours column. Scrolling hours is already handled as 24 hours with AM/PM being done automatically.
I was hoping Caleb would look at this as its not a problem with AM/PM its a problem with short lists. This is a symptom not the main problem..
I'm not sure this is due to scroll_dynamic. During the wait time (before getting to the min hold for accel), the value should remain constant. However, this param ($currentPosition) is being fed to scroll_dynamic from the caller. It is this param that is alternating and causing the AM/PM to toggle so fast. Basically, it's not toggling due to the scroll routine, but instead toggling on each repeat ir tick. I believe this is caused by the code which recalculates the time %%valueRef on each cycle. to be clearer, lets take minutes: first call sends 19 as current value. scroll_dynamic increases to 20. next call sends 20 scroll_dynamic returns 20 (until holdTime is exceeded). third call sends 20, etc Now, for am/pm: first call sends 0 scroll_dynamic increases to 1 second call sends 1 scroll_dynamic returns 1 next call...sending 0 The calculation after the scroll is the issue: $h = ($h + ($p ? 12 : -12)) % 24; Every time $p = 1, it adds 12 hours so you get a toggle. scroll_dynamic can do nothing to change that. S::B::I::Time::scrollTime needs to change the way it calculates, either by detecting the change, or subtracting from $h when $p is initted then adding it back in after if needed.
As another data point, I hacked up a two-item list by trimming the screensaver options to just two. They scroll and hold correctly. No lists on the ip3k players are currently able to roll over. They hold when the end is reached, until the button is pressed again to either go back or roll over.
Created attachment 5846 [details] proposed patch This simple patch make sure $p has changed before we calculate its effect on $h. If the scroll doesn't change (eg, when held) then the value remains the same.
== Auto-comment from SVN commit #29134 to the slim repo by kdf == == https://svn.slimdevices.com/slim?view=revision&revision=29134 == Bug: 12756 Description: check am/pm for changes before altering hours value. This way, holding the up/down button will no longer toggle.
== Auto-comment from SVN commit #29135 to the slim repo by kdf == == https://svn.slimdevices.com/slim?view=revision&revision=29135 == bug: 12756 description: changelog update
I believe this to be fixed in 7.5.0 trunk now that this patch is in. Please reopen if there are any issues.
This bug has been marked fixed in a released version of Squeezebox Server or the accompanying firmware or mysqueezebox.com release. If you are still seeing this issue, please let us know!