randomization/shuffle bug

There are many things that could be used to generate/modify the random number seed.  These include:

 - The clock (why not take the time at power on)

 - User button presses (why not use the time of each button press as well as the button number)

 - Noise from the FM radio (if no clock is available, why not take a brief sample of static and use it to make a number)

Ideally, the seed should be modified by as many sources as possible, although any one of the sources I mentioned would work just fine for the purpose of randomizing song playback.  To prevent the same song from being played twice, the player could just keep track of which ones have been played so far (rather than create an ordered list of songs once shuffle is turned on).  This would require 1 bit of data per song and could be integrated into the player’s database.

My point is that this is really simple stuff , and only an incompetent programmer would make such a lousy shuffle algorithm.

Well, I`m not very into this technical speaking, the fact is that my player is not working as i wanted to. At startup, after the song that plays is over follows the same song everytime, and with it the same list as before. I belive that the player is faulty. I formated mine and installed the latest firmware, but the same thing happens.

Hopefully someone could tell why this happens! A software or hardware problem?! How should it work? Not guesses. Maybe someone from Sandisk, or with more authority! I`ve lost hope that I can solve it, and I want to return mine or send it to be checked.

Maybe for some people this issue is not a big thing (as I had read the other problems users are experiecing), but I want that things that I pay for to work properly.

A software or hardware problem?  This is almost certainly a software problem.

How should it work?  According to page 7 of the manual, turning shuffle on should make the player “play songs in random order”.  I don’t think you will find an answer more specific than this.

I want to return mine or send it to be checked.  There is probably nothing wrong with your player specifically.  But go ahead and send it back to SanDisk.  Maybe if enough people do this, they will be encouraged to release a firmware that shuffles properly.  Be sure to accurately describe what the problem is and how to get it to reoccur.

I want that things that I pay for to work properly.  Me too.  But thanks to upgradable firmware, lazy manufacturers can release products before they are finished.

Thanks for the answers and your recommandations.

I’ve done some more testing, and found some interesting things.

First, try a short song list and shuffle. It didn’t repeat the list, as it went through it and started over. It kept giving new lists, with apparently random patterns. I only tried a three song list. Testing this with longer song sets would be more time-consuming.

Does it actually generate a new list, or is there a minimum size to the shuffle list, or what? I couldn’t tell from testing.

Going to shuffle off, then on again, while on the shuffle menu is enough to make a new list. So if this works right, even if you get the same list on powering up, it won’t take long to get a new one.

How random it is, I can’t say, because it would take more sampling to tell. While I get a feeling of repeated patterns, I can’t be sure whether it is true or illusion without writing down every song on every pass through a shuffle list.

well, i think the REAL problem is that sandisk isnt doing **bleep** about any of these problems
everyone has the same 3 or 4 complaints that the mods would not like to address
like this thread, i dont see a reply from a mod, but on threads with simple questions, mods answer the questions, they are simply dodging the problems

honestly, a firmware update to fix a randomization bug should be that hard, and they should address some other problems too
at least a reply from someone from sandisk would be nice, to see that the **bleep** they’re doing

I don’t know if it was fluke or what, but for a week or so, the player seemed to be working great. It was the same stinking fixed random order (?) but when I’d turn it back on, it would pick up where it left off instead of going back to the beginning of the list. Why oh why didn’t I leave well enough alone!

As for the random order order… just today, I finally tired of the first randomization order… it got to the point where I had to hit FF too many times to be practical, and so I did the shuffle on/off technique ala inkadinkadoo and then turned it off when I got to work. When I turned it back on when I was headed home… it fell back to the original randomization order. ARGH!!! I am driving (it’s playing through my car radio) and I can’t readily do all the button pushing involved to get it to do a new order

In general, I’ve found that the easiest way to deal with this, is to delete the first song or one close to the beginning (think alphabetical). The relief is temporary, but it beats swearing, crashing into other cars on the freeway and getting killed.

Message Edited by glaucus on 02-04-2008 06:34 PM

I am relieved that this thread seems to describe the problem I am having.  I take my Sansa Express to the indoor track for a daily workout.   With several CDs loaded in the player and randomizing selected in order to get a good variety of music, I was surprised to get the same set of songs played in the same order each time I turn on the player.   It does seem to resume at the last song when the player was turned off, but then goes to the very first song in some fixed randomized list. 

Has there been any response from Sansa support regarding this annoying bug?

Wellcome to the club!

In contacting Sansa support, I’m probably just repeating what others have already done.  But, here is the response I received from Sansa.  Looks like they don’t even regard it as a bug. 

Thank you for contacting SanDisk Technical Support.

At this time there are no plans on changing the algorithm that dictates the randomness of the tracks. We will however pass on your concerns to the development team for them to take a look at.

If you should come upon any additional issues please feel free to call us 4am-10pm PST 7 days a week @ 1-866-SANDISK.

Best regards,
Eric W.
SanDisk Technical Support



It’s not the algorithm that’s screwed up, it’s the fact that the player can’t remember where you left off and proceed from there instead of starting over at the beginning ever freaking time you turn it on.

First of all, the thechniques with pressing backwards or shuffle on/off don`t work to much for me. It seems to be a list within a list within a list (as it was said before).

But this is the technique I discovered to get new, random playlists:
When playing music, with shuffle on, from the “genres” submenu, I go and choose a song from the “songs” submenu, leaving the suffle on. Then I get new songs in a random order. So, everytime I turn my player on, and I want to listen a shuffle list, I go to the “genre” submenu, choose one song (it seems that it doesnt work with "play all") and than quickly I go and choose one from the "songs" submenu. So its only a couple of seconds…

So far it`s ok, but it needs more testing. In hope this will help you, I wait your feed-back.

The algorithm could use some improvement as well.  How difficult could it be to use the value of an internal count-up timer as a randomizing seed?   In that way, you could easily re-randomize the list of songs.

But, I agree the real problem is that the Play All begins at the very start of the random list each time the player is turned on.  Oh, it continues with the song which was being played when the player was turned off.   But, the very NEXT song goes to top of the list once again.

Yes, I agree, the algorithm IS the problem.

I have noticed that whenever I change any music on the player(add and/or delete songs), whether or not I have shuffle set to on or not, the player tends to begin playing alphabetically from the beginning. So this morning after deleting some songs and adding a few others, instead of turning shuffle on and off as I usually do when it plays alphabetically, I thought, “What the hell!”, alphabetical is fairly random so I let it go as I drove to work and I heard the A’s and the beginning of the B’s and when I got to work, turned it off. When I turned it back on 9 hours later to drive home, it finished the current song and then jumped forward to H’s. I stopped for an errand and instead of leaving it running as I usually do, I switched it off and then on again when I got back into the car. Lo and behold, it finished the song and then started repeating some of the pre-errand songs, but when I ff’d a few, it was in new territory. I turned it off when I got home and had the same experience when I turned it back on a few minutes ago… a couple of replays and then a whole new set. Hopefully this is not just a fluke. 

Message Edited by glaucus on 04-07-2008 06:47 PM

So much for that theory! It’s still repeating the same old songs. :angry:


I have noticed this shuffle problem too.

I think the algorithm is the problem too.

The SanDisk team should learn some code here :


several Random-number generator :
ParkMiller           – Park-Miller ‘minimal standard’

WichmannHill      – Wichmann-Hill portable RNG (algorithm AS 183)

LEcuyer             – Pierre L’Ecuyer’s MLCG of 1988

Ranlux               – Martin Luescher’s RANLUX

Taus88              – three-component combined Tausworthe RNG by L’Ecuyer

MRG32k3a          – combined multiple recursive 32-bit RNG by L’Ecuyer

MT19937           – Mersenne Twister by Matsumoto and Nishimura

These algo should generate very nice shuffle playlist… 

I did notice that with shuffle turned off, it does remember where it left off, so while it is playing alphabetically by title (hardly ranodm), at least it doesn’t start over at the beginning every time you turn it on. Better than nothin’.

The problem is not the randomizing algorithm which seems adequate.  Its that its only done one time.  The randomizing seed is constant so the order is always the same for a given play list  And the worst problem is that the player restarts from the top of the randomized list, so every time you turn on the player you get the songs in the exact same order.   I have an nonfunctioning iAudio G2.  Seems to me it would go thru the entire playlist in random order and then automagically generate a whole new random order on the second time through.  This is not rocket science here.  How difficult could it be to use the clock or a countup timer as the seed for randomizing?   The programming is trivial.  Getting SanDisk to fix it is the difficult part.

Having tried the whole variety os methods suggested to deceive (most appropriate word I believe) the SE random generator. came to cinclusion the best one is to have as many next or previous track clicks as possible. being enough persistent allows to generate a “new” algorythm.

another mean is to have a long-range shuffle on/off clicking procedure but it requires entering menu, thus it’s a little bit too power-consuming=).

how do u think? or would u prefer sth else instead? let’s form a certain conclusion

A long time ago I bought a TV pc card to watch tv on my computer. It had lots of bugs I kept trying to avoid and make the thing work. It was a constant battle.

Later on I bought another brand - it worked perfectly. Just plugged it in and never looked back.

If this thing has constant problems, I’ll go for the refund or trash can & avoid aggravation & wasting time. :slight_smile: