• Status Closed
  • Percent Complete
  • Task Type Patches
  • Category
  • Assigned To No-one
  • Operating System
  • Severity Low
  • Priority Very Low
  • Reported Version
  • Due in Version Undecided
  • Due Date Undecided
  • Votes
  • Private
Attached to Project: Rockbox
Opened by rb_dev - 2003-03-13
Last edited by linusnielsen - 2003-03-15

FS#1088 - Init paused flag in wps_show()

We must init paused mode to false when we enter wps_show(), else paused flag might be equal to true
while we are in play mode, causing some odd effects.

1) While a track is playing press pause
2) Browse to an mp3 file
3) Play the file

Now we are playing but paused=true, so pressing Fast Fwd or Rewind does not stop mpeg play because
ffwd_rew() thinks we are already paused.

Closed by  linusnielsen
2003-03-15 12:23
Reason for closing:  Accepted

Well, it seems that this patch fixes the problem described in
the example, but there is at least one time when we want to
enter wps_show() without reseting the paused flag. We need
some method to reset it only in cases where we know that we
should not be in paused mode (like when wps_show() is called
after a file is played), because we can enter browse mode
while paused, and in that case we should not reset the paused
flag when we call wps_show() after done browsing.

Submitted patch file #2 to replace the original patch file. This patch fixes the pause state problem without causing
the problems that the first patch caused, but I had to do a 100 tick wait because it takes that long for the pause
state returned by mpeg_status() to transition from paused to not paused, and I couldn’t figure out how to make it
transition faster.

With Linus’ suggestion, I made a change that causes the pause
flag to be updated faster so I was able to remove the wait
before reading the mpeg status. Patch file #3 has a complete
working patch including this improvement.


Available keyboard shortcuts


Task Details

Task Editing