Rockbox.org home
Downloads
Release release
Dev builds dev builds
Extras extras
themes themes
Documentation
Manual manual
Wiki wiki
Device Status device status
Support
Forums forums
Mailing lists mailing lists
IRC IRC
Development
Bugs bugs
Patches patches
Dev Guide dev guide
Search



Donate

Rockbox Technical Forums


Login with username, password and session length
Home Help Search Staff List Login Register
News:

Welcome to the Rockbox Technical Forums!

+  Rockbox Technical Forums
|-+  Support and General Use
| |-+  User Interface and Voice
| | |-+  set resume position in nvram.bin and .playlist_control
« previous next »
  • Print
Pages: [1]

Author Topic: set resume position in nvram.bin and .playlist_control  (Read 1994 times)

Offline JohnPrice

  • Member
  • *
  • Posts: 2
set resume position in nvram.bin and .playlist_control
« on: August 18, 2009, 04:16:30 PM »
Where can I find the format of the nvram.bin file? (and .playlist_control, but that seems mostly obvious)

What I'd like to do is be able to interpret the current setting of the MP3 player from PC when player is plugged in (Sansa e280), and use the PC to set them to different values.

The point of this is I listen to really long audiobooks, mostly in the car, but I'd like to also listen to them on my home PC/stereo system.  Playing the files is simple, but I'd like to resume on the PC exactly where I left off in the car using rockbox, and later in the car, resume exactly where I left off at home using WMP or whatever.  I can handle the programming part and setting/retrieving the position on the PC, but I couldn't find any documentation on the nvram.bin file. 

(I know, I could simply use line-in and play from rockbox, but the location of my PC/stereo system (in a closet) is not conveniently located to where I physically listen (out by the pool with remote PC control), so in order to play/pause, etc. it is inconvenient to go inside to hit the buttons, but I CAN remote control the PC.)
Logged

Offline Domonoky

  • Developer
  • Member
  • *
  • Posts: 205
Re: set resume position in nvram.bin and .playlist_control
« Reply #1 on: August 18, 2009, 05:22:07 PM »

the nvram.bin file is a binary format so its probably not so good to relay on that with external tools.
I think a better way to achieve your goal would be to generate a bookmark file with your resume position with the pc tool.
Logged

Offline JohnPrice

  • Member
  • *
  • Posts: 2
Re: set resume position in nvram.bin and .playlist_control
« Reply #2 on: August 31, 2009, 03:18:16 PM »
Thanks Domonoky,
I thought about using bookmarks too after I posted that.  Their format seems simple enough.  I would have to remember to set a bookmark before I stop using RockBox and start using the PC, but it would work.  That notwithstanding, I'm not afraid of binary files.  I might be able to figure it out from the source, but I expected some documentation on it.
Logged

Offline dreamlayers

  • Developer
  • Member
  • *
  • Posts: 425
  • Boris Gjenero
    • My Blog
Re: set resume position in nvram.bin and .playlist_control
« Reply #3 on: August 31, 2009, 03:31:59 PM »
I would probably use nvram.bin if I chose to write some small program just for myself.  However, it would be a bad idea to release something that reads nvram.bin.  It's not just that nvram.bin is binary.  You also have to consider that:
  • The file has a version number, and it can differ between versions.  (Within one version, settings can only be added to the end.)
  • The file differs depending on the device type.
  • Some devices have actual non-volatile memory, and so there is no nvram.bin file.

If you still want to read nvram.bin, see apps/settings_list.c.
Logged

Offline Llorean

  • Member
  • *
  • Posts: 12931
Re: set resume position in nvram.bin and .playlist_control
« Reply #4 on: August 31, 2009, 05:04:54 PM »
Not to mention bookmark on stop means the bookmark will always be up to date anyway.
Logged

  • Print
Pages: [1]
« previous next »
+  Rockbox Technical Forums
|-+  Support and General Use
| |-+  User Interface and Voice
| | |-+  set resume position in nvram.bin and .playlist_control
 

  • SMF 2.0.17 | SMF © 2019, Simple Machines
  • Rockbox Privacy Policy
  • XHTML
  • RSS
  • WAP2

Page created in 0.082 seconds with 15 queries.