Rockbox Technical Forums

Support and General Use => Audio Playback, Database and Playlists => Topic started by: orbidia on September 24, 2010, 09:30:13 PM

Title: Sansa Fuze v1 Playback problems above build 27996
Post by: orbidia on September 24, 2010, 09:30:13 PM
I searched and haven't seen this discussed anywhere yet so I started a new topic.

I've been using Rockbox on 5 different Fuze v1s (family etc) for a while.
The latest major change in the builds was the addition of full USB support which is very welcome.
Unfortunately for that to work, one must load the latest rockbox v1 firmware with mkamsboot. And then the last official rockbox release (3.6) no longer works. So I'm stuck using a build AFTER rockbox version 3.6 if I want the USB support.

It seemed like everything was going well up until build 27996.
But from 28001 nothing seems to work properly.

The same problems exist from r28001 until today's build r28159 (9/24/2010). I've tried a bunch of builds after r27996 on 3 different Fuze v1s with the same result. To fix everything, I need to format the drive and copy back r27996. Then everything works as intended.

Here is what I'm seeing on builds r28001 to r28159:
When I try to play any mp3, sometimes, it will work - but often it will just will show 0:00 on both sides of the status meter and nothing will play. On the very latest build, the left side played really low and it just played a low garbly static.
The times on the play status meter would often show the played time/elapsed time jumping from what seems like the correct time to a very large number (ten thousand minutes for example) and then back again quickly...
The battery meter would sometimes jump all over the place with thousands of percent being flashed.
I would play with it more but it is totally unusable.

Hopefully, someone can figure out what happened between r27996 and r28001.
I just want to make sure someone is aware this happened to the fuze v1 port...
Maybe some bad code got in by mistake and the automatic builds aren't being tested.

Does anyone else have the same problems with the latest builds on a fuze v1?
Title: Re: Sansa Fuze v1 Playback problems above build 27996
Post by: Lear on September 25, 2010, 10:37:23 AM
The change that looks most likely is r28000 (FS #11597 : decrease FCLK frequency when unboosted).

Automatic builds are used, so if it was a common problem it should've been noticed by now, I think.
Title: Re: Sansa Fuze v1 Playback problems above build 27996
Post by: orbidia on September 25, 2010, 10:09:51 PM
Yes, I agree that the problem should have been noticed. That's why I posted the problems.

Like I said, I've tried this on 3 different v1 fuzes. All of them have the updated rockbox firmware which supports full USB support. Maybe there is some incompatiblity with the updated firmware and the latest builds that no one has really tried.

I just know that I've tried 4-5 different builds since r27996 and they are all unusable.

Right now, I have r27996 and all the audio plays back fine.
So I know (hopefully) that I did the mkamsboot firmware update properly for Boot Ver. 2.0.
The USB support works fine too.

Here goes a current experiment  ------ Starting with r27996:
I just plugged in the Fuze.
The internal memory shows up fine.
I select the Internal "SANSA FUZE" drive (M:) and I do a quick format - fat32.
Format complete.

I go download the latest r28166 for Fuze v1. Its on the desktop.

Unzip the folder to the Fuze v1. Done.

I'm trying to make this as clean as possible.

I've safely ejected the Fuze.

I'm shutting down and rebooting the Fuze.

On the bottom of the display, the info flashes:
First:  Boot ver 2.0
Second: r28166-100926
Then it goes to main menu.

I'm trying to play a 320 mp3 song. No AUDIO is coming out.

Cabbie v2 is the theme because this was a fresh install.
The times for elapsed and total time looked correct but they are flashing:
It goes from 0:00 to 3452346234652457 (or something crazy big) and then jumps back to 0:00 for a second and then flashes again.

The screen goes blank because I haven't hit any buttons.
I tap the center button and the screen comes back on and now both sides of the status bar show
(elapsed) 0:00   (remaining) 0:00

No audio. No fast forward. I can get back the main menu just fine.

Let me try a flac file. Same exact thing. No Audio.

I tried to look at some album art. Seems to work.

I tried Minesweeper and Rockblox. They work but I don't here any audio (I don't know if they have any - probably now.)

I try to play another song from another album. The whole thing locked up on me. No buttons work. Wheel Volume - nope.

(Please note all the same stuff has been happening since r28001 with BOOT VERSION 2.0 i.e. Full USB Support)

The shut down button worked. Yeah!

Plugging in the fuze to the computer.

I format the Internal "SANSA FUZE" Memory the same as before.

I unzip r27996 back onto the Fuze v1.

I eject the Fuze.

Reboot Fuze? Yes
Bottom of screen flashes: Boot ver. 2.0 and then r27996-100904

Back to normal. Music plays back fine.
Status meters show (elapsed time) and (remaining time) properly.

So, I don't know if I'm doing something wrong or if something went wrong in the builds for the Fuze v1 from r28001 until r28166.

Can anyone confirm there is a problem? Maybe this is only a problem with Rockbox Boot version 2.0.

And if its me doing something wrong - I'm open to suggestions.



Title: Re: Sansa Fuze v1 Playback problems above build 27996
Post by: darlredfish on September 26, 2010, 06:06:54 PM
Only playback problems I've had that's keeping my Fuze at 27995 is that I get a crackling white noise on track change using crossfade. It started after updating to the 8000+ build as well.
Title: Re: Sansa Fuze v1 Playback problems above build 27996
Post by: BigPapi on September 26, 2010, 06:53:11 PM
My Fuze V1 with boot 2.0, build 28154-100923, is working just fine. I did not ever do the mkamsboot thought...I've always used the Utility.
Title: Re: Sansa Fuze v1 Playback problems above build 27996
Post by: orbidia on September 26, 2010, 10:46:49 PM
Okay. Thanks darlredfish and BigPapi for confirming the latest builds work on your end.

Now, I don't know what to do. I must have messed up somewhere.
I'm just trying to get everything back to normal.

I still can't get anything to work past 27996...

Here's what I did:

First, I booted into the official firmware and connected the fuze v1 to the computer.
I slow formatted the internal contents (way too long).
Then I loaded up the latest Official Sansa Firmware 1.02.31 into the root.
I unplugged the Fuze and let the Official firmware update.

After I turned it back on, everything seems like its back to original Sandisk spec.

I connected the fuze to the computer and I loaded up the latest Rockbox Utility 1.2.8.

I did a "Complete Installation" to install the last stable version 3.6.
Everything installed fine.

Now, last time I tried using the Rockbox Utility (before r27996) it did not install the latest Rockbox Boot Rom ver. 2.0. That's why I used mkasmboot last time to make the firmware. I wanted the full USB support. This time, I notice the Rockbox Utility is now loading up the Boot Version 2.0 during the complete installation.

I unplug the fuze and the Official firmware says the firmware is being updated. The fuze turns off. I turn it back on to Rockbox Boot ver 2.0 and Rockbox 3.6.

It all works nice and stable - EXCEPT:

The problems start now.
When I go to plug it back into the computer from either an "Off" state OR from the Rockboxed "On" state, the fuze keeps trying to connect to the computer and then it reboots and then tries to connect again... and again in a infinite loop.

This is why I didn't want to use 3.6. Because the full USB support doesn't work...
Without Full USB Support, I need to go into the official firmware whenever I want to change any music and deal with the "Database updates" and all those useless folders the official firmware creates.

*****
QUESTION:
Using stable Rockbox v3.6 and Fuze v1 Boot ver 2.0, does anyone else have properly working Full USB Support?
Or, with Rockbox v3.6, Boot ver 2.0, does the Fuze v1 endlessly reboot when trying to connect?
*****

When I then go to a build AFTER official version 3.6, the USB connection works perfectly - right up to the present build. This makes me think Boot Version 2.0 Firmware was not really meant to work with Rockbox v3.6 -OR- something is really wrong with my Fuzes (I have the exact same problem with 3 tested Fuze v1s).

I then used the Rockbox Utility to update to the latest build and I still get all the same problems from my original post. I went back to r27996 and its all working again.

I get this bad feeling I'm just gonna be stuck on r27996 forever because the firmware got messed up permanently somehow... I guess that's still a heck of lot better than the official firmware.

In summary: I tried completely flushing the system and just used the Rockbox Utility to reload everything. But all the latest builds for the last few weeks are unsusable.

----------------------------

Does anyone know what would have broken in my fuze to make it non-functional with builds after 27996 and boot ver 2.0? And what else could I try to fix it?

I guess I could just wait until the next stable release but I don't know why it would just start working at that point...

Any ideas?
Title: Re: Sansa Fuze v1 Playback problems above build 27996
Post by: saratoga on September 26, 2010, 10:49:04 PM
3.6 does not have USB support on the Fuze:

http://www.rockbox.org/wiki/MajorChanges
Title: Re: Sansa Fuze v1 Playback problems above build 27996
Post by: manequin on September 27, 2010, 05:56:00 AM
You can try my build with reverted r28000 changes. On my fuze I had a problem playing ogg vorbis files using official build. Remember to make a copy of ".rockbox" folder before extracting archive to your player. If something goes wrong, just remove .rockbox folder and revert your backup. However, it works great on my device. Here is the link: http://dl.dropbox.com/u/554609/Rockbox%20archive/rockbox-full-fuze-28177-manequin.zip
Title: Re: Sansa Fuze v1 Playback problems above build 27996
Post by: darlredfish on September 27, 2010, 01:30:36 PM
I tested your build manequin and it works for me fixing the cross fade crackling. I also tested the newest svn to see if it was maybe something I might have done but it was still there.
Title: Re: Sansa Fuze v1 Playback problems above build 27996
Post by: orbidia on September 27, 2010, 08:17:30 PM
Manequin,

You the Man!

I loaded your .rockbox folder onto my problem fuze and...

IT WORKS PERFECTLY!!!

When I load Manequin's build, it starts with:
r28177M-100927

I can't believe it - it is just as stable and perfect running as r27996.
I compared it with the current daily build which shows up with:
r28177-100926

In direct comparison, the official r28177 build for me is UNUSABLE!
As I fast forward through songs or rewind, the status bars keep flashing ridiculously high numbers.
The battery indicator used to flash absurd numbers too but that seems to depend on the theme.
The audio works intermitantly if at all.
Also, I've been getting straight out crashes with a White Screen of Death:

3 or 4 of these:
Data abort
at 30065388
FSR 0x8
(domain 0, fault 8 )
address 0xB7D094A0

and 1 of these:
Data abort
at 30057D78
FSR 0x8
(domain 0, fault 8 )
address 0xA5D90320

But with Manequin's version of the same r28177 build - r28177M - it all works again.

Me and my family have 7 Sansa Fuzes in total - two of them are Fuze v2s and five of them are Fuze v1s.
And I tried a number of builds after r27996 on a few of the Fuze v1s.

**************
Last night I tried r28177 official build on another Fuze. It turns out that whatever the problem is - It affects some Fuze v1s more than others!
One of them I have is more or less stable and seems to be okay. But I managed to get it to freeze up after some fast forwarding and rewinding and moving between menus and tracks. I also noticed the status time flashed a 0:00 once when fast forwarding. When I rebooted it seemed more stable and I couldn't get it to crash again. Another fuze v1 I have is somewhere between unstable and stable. And then the first one I was using is totally unstable.

But Manequin's build fixes the worst Fuze v1 until it is just as stable as the best one. Rock solid. Can't make it crash.

So, whatever code you reverted Manequin was precisely the culprit code!

Lear - the developer responded earlier -
"The change that looks most likely is r28000 (FS #11597 : decrease FCLK frequency when unboosted)."
Was that the main change Manequin or was there more?

Even though I don't code, I really appreciate this community effort in making Rockbox...

Now, what do we do to get that reverted fix back into the official builds so I can use my Fuze v1s with the latest builds again??
Title: Re: Sansa Fuze v1 Playback problems above build 27996
Post by: manequin on September 27, 2010, 08:39:55 PM
I have only reverted changes from 28000. The truth is I don't even know C. As far as I know, r28000 changes were really important for clip users, on Fuze power saving isn't so noticeable (I didn't have possibility to test it on my player :)). If there is a way to revert changes from 28000 for Fuze users and keep them for Clip, it would be a good solution, at least for some time. Until the problem is solved, I will build my version from time to time and I can share it with users who have similar problems, but don't want to compile Rockbox. If someone wants to build Rockbox on his own, there is a patch file from my changes:
http://dl.dropbox.com/u/554609/Rockbox%20archive/sansa-bruteforce-fix.diff
Title: Re: Sansa Fuze v1 Playback problems above build 27996
Post by: orbidia on September 27, 2010, 10:09:54 PM
I was thinking this may be a power issue. Totally speculating here but:
Darlredfish was having problems with cross-fading.
Manequin has problems with Ogg Vorbis playback.
I have problems with everything on two fuze players and not so much on another tested.

Maybe there's not enough power now or its really on the brink and any CPU intensive tasks don't work well. Maybe the working memory is getting corrupted as its being used. That sort of seems like what's happening when I see the display for the status "playing time/remaining time" flashing weird numbers.

All I know is the official r28711 does not work at all on some Fuze v1s, and the revised r28711M with reverted code from r28000 works perfectly. Obviously, a little extra battery life for the fuze is not worth having it become unstable.

Hopefully, a developer will fix this in the official builds soon.
Title: Re: Sansa Fuze v1 Playback problems above build 27996
Post by: ku-ku on September 27, 2010, 11:53:56 PM
I too have problems with playing ogg files - there is noise instead of music when playing my vorbis files. With the build with reverted r28000 changes all seems fine.
Title: Re: Sansa Fuze v1 Playback problems above build 27996
Post by: BigPapi on September 28, 2010, 12:34:15 AM
I just loaded a couple of albums in Vorbis....with the same build as my previous post...boot 2.0, build 28154-100923....and it seems to be playing just fine.
Title: Re: Sansa Fuze v1 Playback problems above build 27996
Post by: saratoga on September 28, 2010, 01:03:09 AM
I'm not really sure how the that code works, but it might be neat to know if commenting out "CGU_PROC = ((0xf << 4) | (0x3 << 2) | AS3525_CLK_MAIN);" (but leave the rest of the changes in place) from r28000 so that we could see if its the fclk change that breaks things or something more complicated.
Title: Re: Sansa Fuze v1 Playback problems above build 27996
Post by: orbidia on September 28, 2010, 03:39:07 AM
If a developer wants to make a build with any modifications, I would happily test it so we can figure out what's happening.

I'm still trying the modified r28711M build and its working great after a few hours of use.
Title: Re: Sansa Fuze v1 Playback problems above build 27996
Post by: manequin on September 28, 2010, 08:04:40 AM
I have reverted all my changes and commented out this line. Unfortunately it doesn't solve problem.
Build is available here:
http://dl.dropbox.com/u/554609/Rockbox%20archive/rockbox-sansa-20100928-1400.zip
Title: Re: Sansa Fuze v1 Playback problems above build 27996
Post by: orbidia on September 29, 2010, 03:33:42 AM
Confirmed.

The build with the single line commented out does not work right.

The sound is terrible though. One thing I notice is that the sound on FLAC is unplayable but with MP3s it sort of plays garbled.
Does playing Flac files take more CPU power/memory than playing MP3s?

More testing - everything acts the same. When I fast forward/rewind, there seems to be a bit less "crazy random numbers" in the status "played/remaining time" fields.

What procedure is possible to narrow down what the problem code is?

We seem to have narrowed down the bad code change between r27996 and r28000. I think it would be beneficial to narrow down exactly what the very last stable version before there was a problem.

So if r28000 was stable and r28001 (tested to be bad) was totally unusable, then the differences between those builds are where the problem exists. I don't have r27997, r27998, r27999, r28000 or r28001. But I remember testing r28001 and I know it was bad so I deleted it hoping the next day it would be fixed...

Manequin, can you post the official r28000 and r28001 build so I can test that and be sure that was the problem jump?

How much changed from r28000 to r28001? If we narrow this down to a single build, we should be able to work out the exact problem.

Title: Re: Sansa Fuze v1 Playback problems above build 27996
Post by: manequin on September 29, 2010, 08:45:00 AM
I have already tested revisions from 27995 to 28001. I couldn't make a patch without it ;). In 27999 everything was ok, 28000 was first build that stopped working properly on my hardware. If someone wants to check this on his own hardware, builds from unpached source are available here:
http://mpiesio.pl/sansa-fuze/unpatched/rockbox-27999.zip
http://mpiesio.pl/sansa-fuze/unpatched/rockbox-28000.zip
Title: Re: Sansa Fuze v1 Playback problems above build 27996
Post by: saratoga on September 29, 2010, 03:37:05 PM
I have already tested revisions from 27995 to 28001. I couldn't make a patch without it ;). In 27999 everything was ok, 28000 was first build that stopped working properly on my hardware. If someone wants to check this on his own hardware, builds from unpached source are available here:
http://mpiesio.pl/sansa-fuze/unpatched/rockbox-27999.zip
http://mpiesio.pl/sansa-fuze/unpatched/rockbox-28000.zip

If you go into the debug menu and turn up the boost counter to 1 so that the CPU is always boosted, do it solve the problem without needing to patch anything?
Title: Re: Sansa Fuze v1 Playback problems above build 27996
Post by: manequin on September 29, 2010, 04:29:25 PM
I have tried this already and it doesn't help.
Title: Re: Sansa Fuze v1 Playback problems above build 27996
Post by: darlredfish on September 29, 2010, 04:34:48 PM
I tried 28000 with and without setting the boost counter to 1 and got the crackling with both, I then tried 27999 and was working fine either way.  So 8000 seems to be where my playback problems started as well.


Title: Re: Sansa Fuze v1 Playback problems above build 27996
Post by: orbidia on September 29, 2010, 09:00:34 PM
Well, I think at least we have a bit of consensus about where the problem code was inserted.

Official r27999 works perfectly stable on my "difficult to please" fuze v1.
Official r28000 is unusable. When I try to play Flac files, it is all garbled. All the same problems from my original post.

When I go to the debug mode with r28000, for CPU frequency setting, at first I see:
Frequency: 62000000
boost_counter: 0

A first, I couldn't figure out how to change the setting to 1.
So I just started pressing each button quick/long press. Turn the dial etc.
Finally I think there must be a way to select the it (press play/pause 'Up?') and then turn the dial to make the change. It doesn't seem like anything is selected.

And immediately, the 1 was flashing with all kinds of huge numbers.
It would show:
boost_counter: 1 (about half a second)
boost_counter: 1207753193 (very quick flash of the number - i think that was the actual number because it would repeat randomly often enough but its hard to follow because it flashes too quickly.)
boost_counter: 1 (about half a second)
boost_counter: 1186775311  (very quick flash of the number - close to the one that flashed but not exact. They all seem to be 10 digit numbers.)
boost_counter: 1 (half a second)
boost_counter: 1203651191  (very quick flash of the number)
etc.
The frequency of the flashing is about 2-3 times per second. It also seems like its actually only flashing about 5 specific numbers. They all start with either 118xxxxxxx or 120xxxxxxx

This is very difficult to change the number for some reason - the dial doesn't work and if the screen blanks out, when it goes back, it is at 0 again.
I see, I just have to turn the dial to bring the screen back and still have the option selected. continuing...

Also, with boost at 0 it is always: "Frequency: 62000000"
The moment I change boost to 1, it shows:
Frequency: 248000000 (3-4 seconds)
Frequency: 143xxxxxxx (REALLY FAST BLINK - 10 digit number that seems to start with 143 but it blinks so fast I can't be sure - seems like the last digit is always an even number 0, 2, 4, 6, or 8 )
Frequency: 248000000 (3-4 seconds)

The flashing  of the frequency number is much slower than the boost_counter number. The random frequency flashes once every 3-4 seconds.

This time, the screen went blank and I had to reboot...

If I keep turning the scroll wheel counterclockwise, the main boot_counter setting will increase 1 every few seconds of turning the wheel. I spun the wheel for about a minute and I got it to read out like this:

boost_counter: 28 (about half a second)
boost_counter: 1186775311  (very quick flash of the number - close to the one that flashed but not exact. They all seem to be 10 digit numbers.)
boost_counter: 28 (half a second)
boost_counter: 1203651191  (very quick flash of the number)

If I scroll clockwise, the setting will decrease by 1 every few second until it gets back to 0 and seems stable (no blinking).
The actual quick flashing numbers seem to be the same 5-6 specific 10 digit numbers that start with either 118 or 120. The flashing numbers and frequency of the flashing seem to be the same for settings 1 and above.

------

A few of these other settings in the debug menu also seem to have oscillating numbers:
For example in: View I/O Ports
[DBOP_DIN]
DBOP_DIN: 887F (starting number)
If I turn the wheel or click any buttons, it will change to
DBOP_DIN: C87F
But sometimes, E87F or A87F will flash briefly.
All other numbers on that screen are solid.

On View Hardware Info:
MMU:    on CVDDP: 12000 (flashes 12025 2-3 times a second or more if use scroll wheel.)

------

At least we've settled on the build that the faulty code appeared. So what could it be in r28000 that is bad? What other tests can we do to find the problem?

Note: if it would help, I could probably figure out exactly what all of the flashing numbers (possibly using video and pausing to see the number clearly). Is that worth the effort or is this just a random by product of the bad code?


Title: Re: Sansa Fuze v1 Playback problems above build 27996
Post by: saratoga on September 29, 2010, 09:06:46 PM
^^  You don't need to describe the debug menu, we've all used it before.  Just state the final out come, did setting the boost counter to one to disable frequency scaling improve playback?  A simple yes or not will work . . .
Title: Re: Sansa Fuze v1 Playback problems above build 27996
Post by: orbidia on September 29, 2010, 09:17:10 PM
With Official r28000 and boost_counter setting: 1, everything is unusable and the audio is garbled plus all the other weird stuff described in the first post.
With Official r27999 everything works perfectly.

What I was describing was the crazy effect increasing the boost_counter had immediately on the setting screen itself...
Just changing the setting to 1, everything gets very weird.
I thought some of the actual weird numbers that were being displayed would help with the debugging.
Title: Re: Sansa Fuze v1 Playback problems above build 27996
Post by: orbidia on October 07, 2010, 09:40:51 AM
I just tested the latest build r28217. It still has all the same problems. Flac files play back sounding terrible on my fuze.

2 other Fuze v1 owners have reported similar problems (and I have more than one fuze v1 which exhibits the problem!). The problems for the other posters also starting exactly with build r28000 as well! I don't know what other proof is needed that something bad happened with r28000 and the bad code is in all the builds since then.

I understand that Manequin made a non-official build which reverted only the r28000 changes but kept the code for the later builds. And everything works perfectly with that non-official build. It fixed all 3 users problems.

I'm sure there are others who are having subtle problems as well but they may just be getting little annoying pops in the audio or something which they aren't even aware is caused by the bad code introduced in r28000. The problem does affect some fuze v1s more than others - I don't know why.

How can this be fixed with the official current builds?
We've identified the exact build the problem began in (r28000)... What else can I do to help fix the problem so the current build can be used?

Is this going to still be a problem when the next "Stable" rockbox version is released?
Title: Re: Sansa Fuze v1 Playback problems above build 27996
Post by: funman on October 07, 2010, 01:54:03 PM
Please move discussion of this bug on Flyspray (http://www.rockbox.org/tracker/task/11608)