forked from len0rd/rockbox
Remove NVRAM infavor of a separate cfg file
remove nvram and use the existing settings framework for it add a crc check to the user_settings data to see if we need to save the user setting file or if we can just save the status file (resume.cfg) move volume to the system_status struct so we don't write the whole settings file over volume changes allow user to still export volume with save sound settings allow the user to also export pitch and speed name the file .resume.cfg Rename all the SYSTEM_STATUS save file variables to TLAs to save space and discourage tinkering Cleanup DEBUG_AVAIL_SETTINGS output when saving user_settings it calls status_save as well this cause the resume file to be written twice. instead remove the callback for status_save when setting_save is called remove header text when saving .resume.cfg convert status_save() to status_save(bool force) add SYSTEM_STATUS_UPDATE_TICKS for ATA device set this to 5 minutes since we arlready wait for the disk to be up before saving we don't want to miss our window for all other every 15 minutes that way if the battery is too low by the time shutdown comes around you don't lose much progress Change-Id: I27214ffd6e5d5494ee5ca83b14f04a41ba426ad7
This commit is contained in:
parent
8e293b4948
commit
7100090f99
41 changed files with 299 additions and 340 deletions
|
|
@ -108,7 +108,7 @@ static void rmt_tuner_sleep(int state)
|
|||
iap_send_pkt(data4, sizeof(data3));
|
||||
/* set volume */
|
||||
unsigned char data2[] = {0x03, 0x09, 0x04, 0x00, 0x00 };
|
||||
data2[4] = (char)((global_settings.volume+58) * 4);
|
||||
data2[4] = (char)((global_status.volume+58) * 4);
|
||||
iap_send_pkt(data2, sizeof(data2));
|
||||
}
|
||||
else
|
||||
|
|
|
|||
|
|
@ -113,11 +113,12 @@
|
|||
#define CODEPAGE_DIR ROCKBOX_DIR "/codepages"
|
||||
|
||||
#define VIEWERS_CONFIG ROCKBOX_DIR "/viewers.config"
|
||||
|
||||
#define RESUMEFILE ROCKBOX_DIR "/.resume.cfg"
|
||||
#define CONFIGFILE ROCKBOX_DIR "/config.cfg"
|
||||
#define FIXEDSETTINGSFILE ROCKBOX_DIR "/fixed.cfg"
|
||||
|
||||
#define PLAYLIST_CONTROL_FILE ROCKBOX_DIR "/.playlist_control"
|
||||
#define NVRAM_FILE ROCKBOX_DIR "/nvram.bin"
|
||||
#define GLYPH_CACHE_FILE ROCKBOX_DIR "/.glyphcache"
|
||||
|
||||
#endif /* __PATHS_H__ */
|
||||
|
|
|
|||
|
|
@ -117,7 +117,7 @@ int sound_current(int setting)
|
|||
{
|
||||
#ifndef BOOTLOADER
|
||||
#ifndef PLATFORM_HAS_VOLUME_CHANGE
|
||||
SOUND_CUR_SET(VOLUME, global_settings.volume)
|
||||
SOUND_CUR_SET(VOLUME, global_status.volume)
|
||||
#endif
|
||||
#if defined(AUDIOHW_HAVE_BASS)
|
||||
SOUND_CUR_SET(BASS, global_settings.bass)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue