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:

Rockbox Ports are now being developed for various digital audio players!

+  Rockbox Technical Forums
|-+  Support and General Use
| |-+  Hardware
| | |-+  How to boot Sansa into Rockbox with USB connected
« previous next »
  • Print
Pages: [1]

Author Topic: How to boot Sansa into Rockbox with USB connected  (Read 7350 times)

Offline jsiddall

  • Member
  • *
  • Posts: 4
How to boot Sansa into Rockbox with USB connected
« on: January 27, 2010, 02:07:40 PM »
I understand the reason these things boot into original firmware when USB is connected.  The problem is the assumption seems to have been that USB is only used for downloading.  However, when it is used in a car and USB is only used for charging then the default behaviour is not right and it really mucks up car mode.

Is it possible to have it look at what is connected to the USB port before deciding which firmware to boot?  Can anyone share some pointers on how I can disable the auto boot into original firmware when USB is connected?

UPDATE: Although I am not a developer I had a look at the source anyway.  Can I do something simple like comment out this?:

#define USB_HANDLED_BY_OF
« Last Edit: January 29, 2010, 12:58:14 AM by jsiddall »
Logged

Offline FlynDice

  • Developer
  • Member
  • *
  • Posts: 166
Re: How to boot Sansa into Rockbox with USB connected
« Reply #1 on: January 27, 2010, 03:00:18 PM »
Does anyone actually make use of the mmu and i/dcache info on the ViewHW info debug page anymore?  I'm thinking of removing that and adding  some more voltage related info that will be more helpful for future use.


@jsiddall:

I don't know if this will completely solve your problem but you can charge while running rockbox by holding a button down when connecting the usb cable.  You didn't mention which player so I don't know if telling you that it's the select button for an e200v2 helps....
It would be in the manual though.
Logged
e280v2    fuzev1 2gb   clip+4gb   8GB Transcend cl6 uSD    access to fuzev2 4GB       clip+2gb R.I.P.

Offline jsiddall

  • Member
  • *
  • Posts: 4
Re: How to boot Sansa into Rockbox with USB connected
« Reply #2 on: January 27, 2010, 04:15:42 PM »
@FlynDice:

I have a Clip V1.  The problem with having to hold down a button when the thing boots is that it pretty much defeats the usefulness of car mode for me -- and that defeats one of the main reasons for using RockBox at all.  My goal is to have the thing totally hands-off.  Throw it in the glove box and forget about it.  When I stop the car it stops too.  When I start the car, it picks up where it left off.

According to the docs RockBox doesn't do the turning on when plugged in part, but because the design of the Clip automatically turns on the device when USB is connected I _almost_ have the perfect solution -- except for starting the OF when USB is plugged in.
Logged

Offline saratoga

  • Developer
  • Member
  • *
  • Posts: 8974
Re: How to boot Sansa into Rockbox with USB connected
« Reply #3 on: January 27, 2010, 04:37:13 PM »
Quote from: jsiddall on January 27, 2010, 04:15:42 PM
The problem with having to hold down a button when the thing boots is that it pretty much defeats the usefulness of car mode for me

Good news.  You can't hold down a button to boot rockbox when powering on from external power.  You will always get the OF.

Quote from: jsiddall on January 27, 2010, 04:15:42 PM
According to the docs RockBox doesn't do the turning on when plugged in part, but because the design of the Clip automatically turns on the device when USB is connected I _almost_ have the perfect solution -- except for starting the OF when USB is plugged in.

You can edit mkamsboot to do this.  Be very careful if you decide to do so, any mistake there will brick your clip with no chance of recovery. 
« Last Edit: January 27, 2010, 04:39:00 PM by saratoga »
Logged

Offline jsiddall

  • Member
  • *
  • Posts: 4
Re: How to boot Sansa into Rockbox with USB connected
« Reply #4 on: January 28, 2010, 09:17:35 PM »
Quote from: saratoga on January 27, 2010, 04:37:13 PM
Quote from: jsiddall on January 27, 2010, 04:15:42 PM
The problem with having to hold down a button when the thing boots is that it pretty much defeats the usefulness of car mode for me

Good news.  You can't hold down a button to boot rockbox when powering on from external power.  You will always get the OF.

Quote from: jsiddall on January 27, 2010, 04:15:42 PM
According to the docs RockBox doesn't do the turning on when plugged in part, but because the design of the Clip automatically turns on the device when USB is connected I _almost_ have the perfect solution -- except for starting the OF when USB is plugged in.

You can edit mkamsboot to do this.  Be very careful if you decide to do so, any mistake there will brick your clip with no chance of recovery. 

Thanks for the tips.  Despite the fact that this all sounds precarious I really do want car mode to work so I am willing to risk the bricking.

I am not a programmer though so this is all a bit daunting.  I had a look at the code in rbutil/mkamsboot/dualboot/dualboot.S and near as I can tell if I change row 89 from this:

#elif defined(SANSA_CLIP) || defined(SANSA_CLIPV2)

to this:

#elif defined(SANSA_CLIPV2)

...and recompiled mkamsboot I should get what I am looking for.  Can anyone who knows this stuff confirm my guess?
Logged

Offline llhell

  • Member
  • *
  • Posts: 5
Re: How to boot Sansa into Rockbox with USB connected
« Reply #5 on: January 29, 2010, 06:23:16 AM »
@jsiddall:

I have the exact same issue with car mode, been waiting for a solution ever since I got my fuze over a year ago.

did you manage to edit mkamsboot to load rockbox on boot with external power, instead of the OF?
I'll be extremely grateful if you could share it with me :)
Logged

Offline jsiddall

  • Member
  • *
  • Posts: 4
Re: How to boot Sansa into Rockbox with USB connected
« Reply #6 on: January 29, 2010, 08:59:37 PM »
Good news!  With the help of a bunch of smart people on IRC I managed to create a couple of patches to get car mode working on my Clip v1.  The changes I made would apply to any Sansa AMS so they should work for you too.  Keep in mind though that these changes have never been tested on anything but my Clip and they do have a real chance of killing your player.  Proceed at your own risk!

I am posting them to Flyspray if you want to try them.
Logged

Offline lazpete

  • Member
  • *
  • Posts: 6
Re: How to boot Sansa into Rockbox with USB connected
« Reply #7 on: January 21, 2011, 04:15:55 AM »
Quote from: jsiddall on January 29, 2010, 08:59:37 PM
Good news!  With the help of a bunch of smart people on IRC I managed to create a couple of patches to get car mode working on my Clip v1.  The changes I made would apply to any Sansa AMS so they should work for you too.  Keep in mind though that these changes have never been tested on anything but my Clip and they do have a real chance of killing your player.  Proceed at your own risk!

I am posting them to Flyspray if you want to try them.

Is there any chanse that i could get a hold of theses patches, and in that case, will it work on the clip+?
regards

//Lasse
Logged

Offline iletunic

  • Member
  • *
  • Posts: 2
Re: How to boot Sansa into Rockbox with USB connected
« Reply #8 on: April 19, 2011, 04:07:07 PM »
Quote from: jsiddall on January 29, 2010, 08:59:37 PM
Good news!  With the help of a bunch of smart people on IRC I managed to create a couple of patches to get car mode working on my Clip v1.  The changes I made would apply to any Sansa AMS so they should work for you too.  Keep in mind though that these changes have never been tested on anything but my Clip and they do have a real chance of killing your player.  Proceed at your own risk!

I am posting them to Flyspray if you want to try them.

Bump for the patches... Would love to test them on Clip+
Logged

Offline saratoga

  • Developer
  • Member
  • *
  • Posts: 8974
Re: How to boot Sansa into Rockbox with USB connected
« Reply #9 on: April 19, 2011, 04:46:04 PM »
Quote from: iletunic on April 19, 2011, 04:07:07 PM
Quote from: jsiddall on January 29, 2010, 08:59:37 PM
Good news!  With the help of a bunch of smart people on IRC I managed to create a couple of patches to get car mode working on my Clip v1.  The changes I made would apply to any Sansa AMS so they should work for you too.  Keep in mind though that these changes have never been tested on anything but my Clip and they do have a real chance of killing your player.  Proceed at your own risk!

I am posting them to Flyspray if you want to try them.

Bump for the patches... Would love to test them on Clip+

They've been in SVN for almost a year.  Check the commit logs if you want to look at them.
Logged

Offline lazpete

  • Member
  • *
  • Posts: 6
Re: How to boot Sansa into Rockbox with USB connected
« Reply #10 on: April 19, 2011, 09:22:06 PM »
Excuse my stupidness, but what is SVN? And where do I find it?
Logged

Offline yapper

  • Rockbox Expert
  • Member
  • *
  • Posts: 794
Re: How to boot Sansa into Rockbox with USB connected
« Reply #11 on: April 19, 2011, 09:46:51 PM »
http://www.rockbox.org/wiki/UsingSVN
Logged
G2 iPod 20GB / Sansa c240 v1 + 2GB microSD / Sansa c250 v1 / Sansa e250 v1 + 8GB microSDHC / Sansa Fuze v2 + 32GB microSDHC

Offline lazpete

  • Member
  • *
  • Posts: 6
Re: How to boot Sansa into Rockbox with USB connected
« Reply #12 on: April 19, 2011, 09:51:51 PM »
thx a lot.
Logged

Offline saratoga

  • Developer
  • Member
  • *
  • Posts: 8974
Re: How to boot Sansa into Rockbox with USB connected
« Reply #13 on: April 19, 2011, 10:11:34 PM »
Alternatively, you can use the web interface linked from our front page.  The mkamsboot is under /rbutil
Logged

Offline iletunic

  • Member
  • *
  • Posts: 2
Re: How to boot Sansa into Rockbox with USB connected
« Reply #14 on: April 22, 2011, 05:57:27 PM »
Quote from: saratoga on April 19, 2011, 04:46:04 PM

They've been in SVN for almost a year.  Check the commit logs if you want to look at them.

Thanks. I compiled mkamsboot from SVN, but Clip+ still boots to OF when USB is plugged in.

I then tried changing dualboot.S:

Line 177: from "bne boot_of" to "beq boot_of"

but that just made it always boot to OF (I was hoping it'd boot into rockbox when USB is plugged in).

Then I tried changing the other jump at line 313, but that also didn't work (ie. still always boots to OF).

Anybody has an idea why? Should I just remove the jumps? I'm worried it will always boot to rockbox then, and I'll be left without USB.

Thanks.

Logged

  • Print
Pages: [1]
« previous next »
+  Rockbox Technical Forums
|-+  Support and General Use
| |-+  Hardware
| | |-+  How to boot Sansa into Rockbox with USB connected
 

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

Page created in 0.11 seconds with 14 queries.