Rockbox Technical Forums

Rockbox General => Rockbox General Discussion => Topic started by: cocopugg on October 29, 2007, 08:03:00 PM

Title: How can I save my ROCKbox settings on exit?
Post by: cocopugg on October 29, 2007, 08:03:00 PM
This may be a silly question but I have just rest my settings, and when I loaded my theme and saved all my settings again, when I power off then back on, the ROCKbox default theme loads and I lose all my settings. How can I save my theme and settings on exit? Thanks guys.
Title: Re: How can I save my ROCKbox settings on exit?
Post by: Chronon on October 29, 2007, 08:33:52 PM
Make sure you shut down rather than reset.  If you reset the player then settings will not be saved.  A proper shut down should save settings.
Title: Re: How can I save my ROCKbox settings on exit?
Post by: cocopugg on October 29, 2007, 08:44:24 PM
Make sure you shut down rather than reset.  If you reset the player then settings will not be saved.  A proper shut down should save settings.

Thanks Chronon. Next silly question...What's the proper way to shut down? I've been pressing and holding the menu button until the Sansa shuts off. Is that wrong? Thanks again.
Title: Re: How can I save my ROCKbox settings on exit?
Post by: Chronon on October 29, 2007, 08:52:00 PM
The manual says that a long press of Power should result in shutting down.
Title: Re: How can I save my ROCKbox settings on exit?
Post by: cocopugg on October 29, 2007, 09:16:43 PM
The manual says that a long press of Power should result in shutting down.

Yeah I'm doing it properly, but I keep losing all my settings when I power back up.
Title: Re: How can I save my ROCKbox settings on exit?
Post by: Chronon on October 29, 2007, 10:19:51 PM
Does it give you a message telling you this (e.g. Cleared) or not?  I'm wondering if you're doing something to cause the settings to be cleared at startup.
Title: Re: How can I save my ROCKbox settings on exit?
Post by: cocopugg on October 30, 2007, 09:21:57 AM
Does it give you a message telling you this (e.g. Cleared) or not?  I'm wondering if you're doing something to cause the settings to be cleared at startup.

No I don't get any such message. It just doesn't want to save any of my settings on exit.
Title: Re: How can I save my ROCKbox settings on exit?
Post by: bascule on October 30, 2007, 11:02:41 AM
Check if you have a file called config.cfg in /.rockbox? This is the automatically saved settings file.

If so, post the contents here, then delete the file and then see if it starts saving settings correctly.
Title: Re: How can I save my ROCKbox settings on exit?
Post by: cocopugg on October 30, 2007, 11:16:14 AM
Check if you have a file called config.cfg in /.rockbox? This is the automatically saved settings file.

If so, post the contents here, then delete the file and then see if it starts saving settings correctly.

Here it is:

# .cfg file created by rockbox r15351-071028 - http://www.rockbox.org

volume: 0
backlight timeout: 10
statusbar: off
time format: 12hour
foreground color: FFFFFF
background color: 000000
show files: all
show filename exts: on
folder navigation: on
gather runtime data: on
replaygain: on
replaygain type: track
replaygain noclip: on
crossfade: always
tagcache_autoupdate: on
warn when erasing dynamic playlist: on
show path in browser: full path
font: /.rockbox/fonts/chicago12.fnt
wps: /.rockbox/wps/ipod_Vision.wps
backdrop: /.rockbox/backdrops/iPod_Vision.bmp
iconset: /.rockbox/icons/tango_small.bmp
viewers iconset: /.rockbox/icons/tango_small_viewers.bmp
button light timeout: off

I also have all these files in the .rockbox root dir:

.glyphcache
.playlist_control
BigKeys.kbd
config01.cfg
database_0.tcd
database_1.tcd
database_2.tcd
database_3.tcd
database_4.tcd
database_5.tcd
database_6.tcd
database_7.tcd
database_8.tcd
database_changelog.txt
database_idx.tcd
nvram.bin
rockbox.mi4
rockbox-info.txt
tagnavi.config
viewers.config


Are all these files needed?


Also, I deleted the file config.cfg as you suggested, then booted in and set my theme, powered down, and when I powered back up it still didn't save the theme, loaded into the ROCKbox default theme with no saved settings.
Title: Re: How can I save my ROCKbox settings on exit?
Post by: bascule on October 30, 2007, 11:51:24 AM
Well, as you can see, the config file appears to be working OK (in the sense that it contains some non-default settings that presumably match settings you have made).

The paths also look OK for the WPS etc.

Is it just the WPS theme that appears to not be being saved? Does it definitely display in the WPS when you set it initially?

Do you get the 'Saving Settings' splash when you shut down (not a surefire diagnostic, as that may appear and disappear quicker than you can see it)?

And yes, all those other files are required (with the possible exception of rockbox.mi4, but that will not affect your problem).

All in all, it seems to me to be more of a theme problem - does the theme require a custom build? Are you in fact running a custom build?
Title: Re: How can I save my ROCKbox settings on exit?
Post by: pixelma on October 30, 2007, 11:58:12 AM
And yes, all those other files are required (with the possible exception of rockbox.mi4, but that will not affect your problem).
The rockbox.mi4 is the firmware file (like rockbox.ipod on Ipods etc.) so the most important one in the .rockbox directory!

I also don't see a problem in the posted config.cfg file, except one small if the theme you installed there doesn't ship the chicago12 font. It was removed from the official fonts package and Nimbus-13 (yes, no typo) replaces it. If chicago12 is not there in the fonts directory inside .rockbox then your menu probably won't change too.
Title: Re: How can I save my ROCKbox settings on exit?
Post by: Chronon on October 30, 2007, 12:26:35 PM
Can you also clarify whether or not the theme loads properly at all?  In other words, does it load properly then revert to the default after a successful shut down and boot?  Out of curiosity, what model of DAP do you use?
Title: Re: How can I save my ROCKbox settings on exit?
Post by: cocopugg on October 30, 2007, 01:00:15 PM
Well, as you can see, the config file appears to be working OK (in the sense that it contains some non-default settings that presumably match settings you have made).

The paths also look OK for the WPS etc.

Is it just the WPS theme that appears to not be being saved? Does it definitely display in the WPS when you set it initially?

Do you get the 'Saving Settings' splash when you shut down (not a surefire diagnostic, as that may appear and disappear quicker than you can see it)?

And yes, all those other files are required (with the possible exception of rockbox.mi4, but that will not affect your problem).

All in all, it seems to me to be more of a theme problem - does the theme require a custom build? Are you in fact running a custom build?

The theme I've been running is iPod vision, it was saving perfectly until I downloaded and installed the latest build. I tried another theme I have installed, Bold Aqua, and it too doesn't save any of the settings. As for the Saving Settings splash screen, I have yet to see it come up, and I've looked very carefully for it, so even if it showed for a split second I would've seen it.
Title: Re: How can I save my ROCKbox settings on exit?
Post by: cocopugg on October 30, 2007, 01:03:24 PM
Can you also clarify whether or not the theme loads properly at all?  In other words, does it load properly then revert to the default after a successful shut down and boot?  Out of curiosity, what model of DAP do you use?

The theme loads perfectly, and all the setting changes I make are saved perfectly while I keep the player on, but when I power down and turn the Sansa back on, it defaults to the ROCKbox default theme, and none of the settings were saved. Not sure what model of DAP I'm using, how can I find out? Thanks.
Title: Re: How can I save my ROCKbox settings on exit?
Post by: Chronon on October 30, 2007, 01:28:58 PM
DAP = Digital Audio Player.  I don't think what model of DAP you are using will matter much.  I was just curious.

You might try clearing your settings and then seeing if this behavior changes.

Oh, and please use the "Modify" button rather than double post.   :)
Title: Re: How can I save my ROCKbox settings on exit?
Post by: cocopugg on October 30, 2007, 01:45:15 PM
DAP = Digital Audio Player.  I don't think what model of DAP you are using will matter much.  I was just curious.

You might try clearing your settings and then seeing if this behavior changes.

Oh, and please use the "Modify" button rather than double post.   :)

I tried clearing settings. Still no dice. Since I'm not seeing any signs of a "saving settings" splash screen on exit, is there any way to verify whether it's actually saving the settings on exit?
Title: Re: How can I save my ROCKbox settings on exit?
Post by: Chronon on October 30, 2007, 01:58:39 PM
Many targets have a USB mode stored in flash that can be accessed in various ways.  On my gigabeat I can attach a USB cable and power on and it will enter a bootloader USB mode.  On iPods you hold Select + Play during boot.  This is where your actions will depend on the DAP you use.  

You can try saving some new settings -- both theme related and non-theme related.  Then turn off your player and initiate a USB session without booting into Rockbox (I believe this is possible on most targets).  Then you can check the contents of the config.cfg file on a PC and see if the settings were saved or not.  
Title: Re: How can I save my ROCKbox settings on exit?
Post by: bluebrother on October 30, 2007, 02:04:15 PM
I'd rather be interested what settings exactly aren't saved -- the config file you posted looks fine, and I don't see a reason why it shouldn't load. Does it make a difference if you select "reset settings" after bootup? I.e., are the settings after bootup the default settings? Or does your issue only affect the theme?
Title: Re: How can I save my ROCKbox settings on exit?
Post by: pixelma on October 30, 2007, 02:09:31 PM
Two questions:

1) For how long do you hold the "power" button? If you hold it too long (about 15 seconds) the hard power off kicks in and the player won't be able to save settings.

2) Even though the posted config.cfg showed the right paths but are you sure that the theme you are selecting is installed correctly, meaning the wps-file is in ".rockbox/wps", the theme's cfg-file is in ".rockbox/themes" and so on? Only then this setting will be remembered across reboots.
Title: Re: How can I save my ROCKbox settings on exit?
Post by: cocopugg on October 30, 2007, 02:53:56 PM
The paths are all correct for my theme's .cfg and wps files. The settings that aren't saved are any and all settings I change after the rockbox default load. I tried "reset settings" after bootup and it clears everything but after I make the new settings, when I reboot it still goes back to the rockbox default settings. I then tried going into the Sansa's firmware to see if it saves my last settings on reboot and yes it does. The problem is only in the rockbox firmware apparently.

UPDATE:

Still no luck. I'm still not getting my settings saved on exit. It does, however, save the "resume playback" position, but not any of the settings, nor the chosen theme. Anyone with anymore clues, I'd appreciate any input. Thanks.

Title: Re: How can I save my ROCKbox settings on exit?
Post by: bascule on October 31, 2007, 05:32:40 AM
Right, let's approach this in a slightly more methodical way...


Post any findings you have here.
If all the above works as described then your problem would seem very much to be theme-related
Title: Re: How can I save my ROCKbox settings on exit?
Post by: cocopugg on October 31, 2007, 09:05:27 AM
bascule, thanks for your help. I did everything as you requested, but it didn't save the .cfg file. When I reboot, none of the settings are saved, so I have to reset the show all files option to see the .cfg file, and it's empty. It's like the Sansa isn't writing the new info, yet it saves the resume playback position, so it's apparently wrting something, no?
Title: Re: How can I save my ROCKbox settings on exit?
Post by: bascule on October 31, 2007, 09:56:10 AM
OK, so it's a problem with writing the config file. The resume position is not saved to the config file.
You could try updating your build to the very latest version (as is required by the posting guidelines), although I don't see any recent commits in any way related to your specific problem, but sometimes just updating fixes a problem by magic!

The other option is to try to manually save a config file (config01.cfg, config02.cfg etc), then rename it to config.cfg (deleting your existing one if necessary) and see if that fixes the problem.

The final thing, potentially, is a damaged filesystem. Do a forum search for 'chkdsk'.
Title: Re: How can I save my ROCKbox settings on exit?
Post by: cocopugg on October 31, 2007, 10:56:43 AM
OK, so it's a problem with writing the config file. The resume position is not saved to the config file.
You could try updating your build to the very latest version (as is required by the posting guidelines), although I don't see any recent commits in any way related to your specific problem, but sometimes just updating fixes a problem by magic!

The other option is to try to manually save a config file (config01.cfg, config02.cfg etc), then rename it to config.cfg (deleting your existing one if necessary) and see if that fixes the problem.

The final thing, potentially, is a damaged filesystem. Do a forum search for 'chkdsk'.

Bingo! The current build update did it! Now that I've got it working right, I don't plan to update to anymore current builds unless a real bug pops up. If it isn't broke, don't fix it right? Thanks for all your help everyone, ROCKbox rules!
Title: Re: How can I save my ROCKbox settings on exit?
Post by: cc on October 31, 2007, 01:51:23 PM

Even if everything appears OK at the moment, I would still to the chkdsk thing bascule suggested. The only time my sansa started doing inexplicable things it turned out to be a corrupt file system.