Rockbox Technical Forums

Support and General Use => Hardware => Topic started by: Gunbuster on July 05, 2013, 02:14:34 PM

Title: Memory access noise on Clip+
Post by: Gunbuster on July 05, 2013, 02:14:34 PM
Hello folks,

First I know this is a long known issue

http://www.rockbox.org/tracker/11907
http://forums.rockbox.org/index.php?topic=28150.0
http://www.hydrogenaudio.org/forums/index.php?showtopic=86306

But I found out that downgrading to 3.7 completely eradicated the issue for me, it may be still there but I can't ear it even if I try to !
Playing with different versions it seems the issue appeared since 3.8.1

Here is two record of what happen when I skip track rapidly and the buffer need to be refilled :

Clip+ on 3.13 : https://www.dropbox.com/s/y4t4c4xc3o663o5/clip%2B%20noise%203.13.wav
Clip+ on 3.7 : https://www.dropbox.com/s/ue58txa3lsbcaij/clip%2B%20noise%203.7.wav

The constant background noise is because of my bad line in, as you can hear the access noise present from the rockbox 3.13 record is completely absent from the 3.7 one.

I heave two memory cards, a 32gb class 4 from Sandisk and a 32gb class 10 from Transcend and the issue is the same for both of them, but the pitch of the hum vary depending of the album I play (may be related to the position of the file in the card.)

Now I can't help but wonder if the noise/flickering screen issue on the Fuze+ is related to this one. On the Fuze+ it's less annoying because the buffer is much bigger thus it needs to be refilled less frequently.
Title: Re: Memory access noise on Clip+
Post by: saratoga on July 05, 2013, 04:00:12 PM
Since this only happens on a small number of devices I think you'll be on your own figuring out a solution. Going to be hard for other people to help without access to your player.

That said I'd be surprised if older versions of Rockbox sound different.
Title: Re: Memory access noise on Clip+
Post by: Gunbuster on July 05, 2013, 05:22:57 PM
Hi saratoga, thank you for your answer.

I don't want to sound rude to you but I'm not sure denying/overlooking the problem exist is the way to go.

The problem exist and I proved that something changed that broken rockbox at least on my device since 3.8.1

The thing is I bought a Fuze+ considering that like you said, only a small portion of devices maybe affected, so I thought I would have more luck with another device...  but I'm a little baffled to encounter another issue that look very similar.

Not Rockbox fault though and I know this will be difficult to resolve if, again like you said, only a small number of devices is affected.

Then again I thought that bringing a new clew on this issue might revive some attention to it, maybe it wasn't that new after all  :'(

Would be nice if, since I'm not alone to have this issue, other peoples try the same thing as I did and test with an older version to see how it goes.
Title: Re: Memory access noise on Clip+
Post by: saratoga on July 05, 2013, 05:57:56 PM
Noise on SD access is common to a large number of sandisk players and has been for years now. No idea about the fuze plus but it wouldn't shock me.
Title: Re: Memory access noise on Clip+
Post by: [Saint] on July 06, 2013, 01:30:12 AM
I don't want to sound rude to you but I'm not sure denying/overlooking the problem exist is the way to go.

At no point did anyone do so.

Saratoga did not deny the fact that this issue exists, his second post goes on to acknowledge that on some devices this is a well known issue. All that was said was that this problem only seems to occur on some players, and that without having physical access to a player that presents the issue it is unlikely anyone will be able to do anything about it. These are truths.

He also stated that he would be surprised if prior revisions lessened the issue (and, I would be, too), but this again is not saying that it does not in fact do so, or that you are not experiencing the issue.


[Saint]
Title: Re: Memory access noise on Clip+
Post by: Gunbuster on July 06, 2013, 08:23:15 AM
Hi Saint,

Please consider that English is not my native language, and also the fact that it's hard to tell someone who have far more knowledge that I will ever have that I have strong convictions he may be wrong to assume things this way, without sounding like a total ass.

Again based on my experience, the records I provided, and more importantly my ears, I think you and saratoga are both wrong.

But I know you have reasons to assume things like this and it will be hard to convince you both.

I myself would be surprised if one could state the fact that my device is not affected by 3.7 and 3.8 but it is with all subsequent versions starting from 3.8.1 is a total accident and nothing can be learn from this.

I would be glad if I could help the community by lending my device to a developer.
Title: Re: Memory access noise on Clip+
Post by: [Saint] on July 06, 2013, 09:57:28 PM
Gunbuster,

I am aware of the fact that many people that use these forums do not speak English natively, and although I do try to adjust my language to suit this, it may be the case that misunderstandings occur. I understand this.

I want to make totally clear to you that no one is denying that you are experiencing issues with audible memory access. This issue has been reported multiple times, across different devices, it is not uncommon. It is a known issue.

No one is saying you are not experiencing this.

What is being said, is that it is basically impossible for a developer to do anything about this unless they have a device that shows the issue. Presently, to my understanding, no one does.

Another thing that was said is that it would be surprising if this issue presented itself in one version of Rockbox, but not another. I agreed with this. It is important to understand that this is not saying that you are incorrect or mistaken, it is simply saying it is surprising.

No one is saying you are incorrect.

Your findings are helpful, and appreciated, and no one said that it wouldn't potentially lead to the cause of the issue. What is being said, however, is that it is not something that can be reproduced on demand (many devices do not show this problem at all), which makes the issue incredibly difficult to fix unless a developer has a device that shows this issue. Recordings of the issue happening are great, but not useful for the purpose of solving the issue. The only thing the recordings would solve is doubt the issue exists, but there is no doubt of this.

I understand this must be frustrating for you, but it seems you think that we are denying the issue exists. We are not.


[Saint]
Title: Re: Memory access noise on Clip+
Post by: Gunbuster on July 07, 2013, 02:48:00 PM
I acknowledge my wording was unfortunate.

It was not my intention to make a fuss about this, and I apologize for all the misunderstandings.

Thank you for taking your time to explain me why it can't be solved that easily even though I'm pretty confident about my finding.

If a developer is somewhat interested about this issue, please let me know, I will send him my devices right away.
Title: Re: Memory access noise on Clip+
Post by: 404_user_not_found on July 08, 2013, 09:26:28 AM
I tried to test noise difference from 3.13 and 3.7 in my Clip+ 8 GB, but I can't downgrade to 3.7 due the error "No Partition Found. Insert USB Cable and fix".
Title: Re: Memory access noise on Clip+
Post by: Gunbuster on July 08, 2013, 12:45:06 PM
That's weird, is everything ok when you revert back to 3.13 ? How is 3.8 then ?
Title: Re: Memory access noise on Clip+
Post by: saratoga on July 08, 2013, 01:14:52 PM
Your player maybe too new a hardware revision to support such an old build.
Title: Re: Memory access noise on Clip+
Post by: Gunbuster on July 12, 2013, 11:50:06 AM
So I bought a brand new clip+ from Amazon, I rockbox it right out of the box with the latest stable (3.13) play a song and I can hear the "BZzzzzZZZBvbzZZZzzz" of the buffer being filled up so I'm a little astonished to say the least...

... But I'm not done yet, so I put 3.7 on the clip+ and guess what, it's dead silent now !

Tbh I can still hear a very little tiny sound that I couldn't hear with my 2 years old refurbished device, but it's still like 100 times quieter than the newer firmwares, I could never record that sound like I did with the 3.13 release.

At this point it can't be an accident, something definitely changed that broke rockbox at least on the clip+ since the 3.8.1 release.

(http://uppix.net/FDyKUA.jpg) (http://uppix.net/FDyKUA)
Title: Re: Memory access noise on Clip+
Post by: gevaerts on July 12, 2013, 01:19:07 PM
If I read this thread correctly, you said it was also silent with 3.8, but not with 3.8.1?

If so, http://git.rockbox.org/?p=rockbox.git;a=commit;h=d1fdb485b12676dc99db29ee9f9900c9c752c124 is almost certainly involved. If the commit message is correct and doesn't omit anything, that means it's one of

Now, I'm not an sd specialist and I don't have a clip+, so I can't verify much of this, but someone who knows the ams sd driver should be able to work with that information
Title: Re: Memory access noise on Clip+
Post by: Gunbuster on July 12, 2013, 01:35:46 PM
Yes I can certify with 100% accuracy that both of my devices are not affected with 3.7 and 3.8, well it is to a certain extent,  it appears that it can vary from devices to devices as I can still hear a tiny sound with the new device that I couldn't with the old one (it may still be present though, I just can't hear it)

But it's not even close to what I can hear with newer firmwares since 3.8.1.

Thank you for your research on this issue and I hope it can help someone resolving it.

I wish I could help more.
Title: Re: Memory access noise on Clip+
Post by: bertrik on July 12, 2013, 03:23:46 PM
IMO, the most likely candidates are (most suspicious first):
* http://git.rockbox.org/?p=rockbox.git;a=commit;h=5c4c691cd3465c3cbca83581aa079648fa2d8d04
* http://git.rockbox.org/?p=rockbox.git;a=commit;h=8351a1aa9db98bab1f66274ee7b7e33839a31c60
* http://git.rockbox.org/?p=rockbox.git;a=commit;h=7d74fdec020d1f54f0cab318c595d34dd2dc1a0c
* http://git.rockbox.org/?p=rockbox.git;a=commit;h=eab630a1e1463be244118613537f6a04d290f5e0

Can you try this rockbox build (it has 5c4c691cd3465c3cbca83581aa079648fa2d8d04 reverted)?
https://docs.google.com/file/d/0ByItZAj1MynOUHpndW0yTmMydVk/edit?usp=sharing
Select File/Download on the top left, save the rockbox.zip file and unzip over your existing installation on the clip+, such that it overwrites the files in <your-clip+-drive>:/.rockbox
Title: Re: Memory access noise on Clip+
Post by: Gunbuster on July 12, 2013, 05:31:50 PM
Hi bertrik,

I tried your new build, at startup it say Ver. 4fc4f4e-130712

Sadly I can't hear any improvement with both of my devices.

Thank you for your hard work and please don't hesitate to share new builds if you have other clues about this issue.
Title: Re: Memory access noise on Clip+
Post by: b0hoon on July 12, 2013, 06:41:59 PM
Hi.

I have a clip+, variant 0 and have no ANY noise with unbranded 2GB card, class 4. Rockbox version is 8723132-120830, so after 3.8. So my guess is that it depends on the hardware (sd card).
Title: Re: Memory access noise on Clip+
Post by: Gunbuster on July 12, 2013, 07:52:31 PM
Hi b0hoon,

It could be the card yes, as I have already stated I have two memory cards, a Sandisk class 4 and a Trenscend class 10 and I can't hear any difference one from another.

Two different brand, two different speed, the only redundancy is the size (32gb.)

So the size of the card could be one of the root of the problem, I will try to have access on a different card size this weekend to test this theory.

Still it don't explain why two different version of rockbox can sound different with the same hardware (both player and SD card.)

Edit : I just tried with a friend's 16gb class 10 (also Transcend), and still no difference.

(http://uppix.net/K6t202.jpg) (http://uppix.net/K6t202)
Title: Re: Memory access noise on Clip+
Post by: Gunbuster on July 13, 2013, 02:39:46 PM
So based on the research of bertrik and gevaerts I tried to mess with the sources and make build of rockbox with those patch reverted, and I found the culprit.

* http://git.rockbox.org/?p=rockbox.git;a=commit;h=8351a1aa9db98bab1f66274ee7b7e33839a31c60

What I did is :

Code: [Select]
Launch the VM
git clone git://git.rockbox.org/rockbox ./Desktop/rockbox
cd ./Desktop/rockbox
mkdir build
cd build
../tools/configure
62
patch -p0 -R < 8351a1aa9db98bab1f66274ee7b7e33839a31c60

However when Applied the patch it said :

Code: [Select]
--------------------------
|--- a/apps/plugins/SOURCES
|+++ b/apps/plugins/SOURCES
--------------------------
File to patch: ../apps/plugins/SOURCES
patching file ../apps/plugins/SOURCES
Unreversed patch detected!  Ignore -R? [n]

So only this patch has been applied

Code: [Select]
--- a/firmware/target/arm/as3525/sd-as3525v2.c
+++ b/firmware/target/arm/as3525/sd-as3525v2.c
@@ -549,40 +549,11 @@ static int sd_init_card(const int drive)
     /*  Card back to full speed  */
     MCI_CLKDIV &= ~(0xFF);    /* CLK_DIV_0 : bits 7:0 = 0x00 */
 
-    if (sd_v2)
-    {
-        /* Attempt to switch cards to HS timings, non HS cards just ignore this */
-        /*  CMD7 w/rca: Select card to put it in TRAN state */
-        if(!send_cmd(drive, SD_SELECT_CARD, card_info[drive].rca, MCI_RESP, &response))
-            return -7;
-
-        if(sd_wait_for_tran_state(drive))
-            return -8;
-
-        /* CMD6 */
-        if(!send_cmd(drive, SD_SWITCH_FUNC, 0x80fffff1, MCI_RESP, &response))
-            return -9;
-
-        /* This delay is a bit of a hack, but seems to fix card detection
-           problems with some SD cards (particularly 16 GB and bigger cards).
-           Preferably we should handle this properly instead of using a delay,
-           see also FS#11870. */
-        sleep(HZ/10);
-
-        /*  We need to go back to STBY state now so we can read csd */
-        /*  CMD7 w/rca=0:  Deselect card to put it in STBY state */
-        if(!send_cmd(drive, SD_DESELECT_CARD, 0, MCI_NO_RESP, NULL))
-            return -10;
-    }
-
     /* CMD9 send CSD */
     if(!send_cmd(drive, SD_SEND_CSD, card_info[drive].rca,
                  MCI_RESP|MCI_LONG_RESP, card_info[drive].csd))
         return -11;
 
-    /* Another delay hack, see FS#11798 */
-    mci_delay();
-
     sd_parse_csd(&card_info[drive]);
 
     if(drive == INTERNAL_AS3525) /* The OF is stored in the first blocks */


Edit : For anyone who want to test the build :
https://www.dropbox.com/s/vn3m816omnfli7e/rockbox.zip
Title: Re: Memory access noise on Clip+
Post by: 404_user_not_found on July 13, 2013, 10:03:47 PM
You should try a new patch http://gerrit.rockbox.org/r/#/c/512/
Title: Re: Memory access noise on Clip+
Post by: Gunbuster on July 14, 2013, 09:58:46 AM
Thank you 404_user_not_found, we need people to test this as for the moment I'm like the only person in the world who have noted this so I don't expect it to make it to the master branch.

Furthermore it's a very lazy approach as I am no developer, I just reverted some past changes and we need people who know about this like bertrik to investigate further.

All I know is it greatly reduced the noise to a state where it were prior 3.8.1
Title: Re: Memory access noise on Clip+
Post by: [Saint] on July 14, 2013, 10:12:55 AM
Perhaps my prior post was looked over, or something was lost in translation, but you are far from being the only person in the world to have noted this.

This has been noted a few times, across multiple devices.


[Saint]
Title: Re: Memory access noise on Clip+
Post by: Gunbuster on July 14, 2013, 11:55:04 AM
Saint, by any mean I didn't overlooked your post, I know you acknowledged the problem exist.

Still for the time being, and to my knowledge, I'm the only one who have noticed an improvement with older firmwares, this is a fact.

This is why it needs further testing from people who suffer from the same issue.

Sorry again for the misunderstanding.
Title: Re: Memory access noise on Clip+
Post by: 404_user_not_found on August 09, 2013, 04:48:21 AM
My steps to reproduce a noticeable memory access noise in rockbox 3.13 with a new revision of sansa clip+ 8gb. This noise is only noticeable at the start of each tracks and noise stops after some seconds of playing.
1) Play big files that requires a high extensive disk activity like wav files with uncompressed PCM codec or FLACs. The tracks should have a some seconds of empty sound at the start. Just set volume to zero.
2) Listen with in-ears headphones with low impedance with low sensitivity (I tested with Koss the plug headphones). I can't notice a memory access noise with other types of headphones.

So may be you can get a rid of noise by changing headphones to another with better quality?

Thank you 404_user_not_found, we need people to test this as for the moment I'm like the only person in the world who have noted this so I don't expect it to make it to the master branch.
With my steps to reproduce a noise this (http://gerrit.rockbox.org/r/#/c/512/) patch and your build changes nothing.

All I know is it greatly reduced the noise to a state where it were prior 3.8.1
can't test with this version because of new revision of my sansa clip+, but noticed that 3.8.1 can't detect my internal memory but detects sd card. So I will try to make some tweaks to run rockbox from sd card.
I successfully run 3.7 in my sansa clip+ from sd card. And with my steps to reproduce a noise nothing changes - I also can notice a same noise as it was in 3.13.
Title: Re: Memory access noise on Clip+
Post by: saratoga on August 09, 2013, 05:33:37 PM
The audibility of any analog noise will depend on the sensitivity of the headphones. Wither sensitivity the noise must be louder to be heard.

Regarding this issue, listening to the noise is not a great way to test since everyone has different headphones and different opinions. A better way would be to play silence, record the noise and then measure its amplitude.
Title: Re: Memory access noise on Clip+
Post by: db30 on February 14, 2014, 11:08:23 AM
Hello fellow Rockboxers!

I'm also affected by the memory access issue on Clip+, with and without the SD card connected.
The noise is present when the player is booting, on changing tracks and on seeking. During playback it isn't present at all or it's just inaudible.
Some noise can also be heard while the original firmware is used, but it's much less loud than on Rockbox and it's also present for shorter periods of time.

What I've done so far:
- checked on 3.7 - no changes
- checked on 3.13 - no changes
- checked on the build from post #18 - no changes

I see that there's a new patch in post #19, but I simply don't know how to compile it. If someone could put a precompiled version on the forums, I'd test it and submit the results with a great pleasure.

Cheers!
Title: Re: Memory access noise on Clip+
Post by: saratoga on February 14, 2014, 12:38:36 PM
I'm pretty sure this is just a hardware defect with some Clip+ players, so I don't think any patch is going to help you. 
Title: Re: Memory access noise on Clip+
Post by: mesb on February 17, 2014, 01:28:26 AM
I'm pretty sure this is just a hardware defect with some Clip+ players, so I don't think any patch is going to help you.
I have the same.
And almost not on sandisk fw.
Maybe there is sense to try any workaround even switchable through menu?
Title: Re: Memory access noise on Clip+
Post by: saratoga on February 17, 2014, 10:35:20 AM
If you discover a work around I think it makes sense to try it.