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
translations translations
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
|-+  Rockbox Development
| |-+  New Ports
| | |-+  Cowon D2
« previous next »
  • Print
Pages: 1 2 [3] 4 5 ... 65

Author Topic: Cowon D2  (Read 678845 times)

Offline GodEater

  • Member
  • *
  • Posts: 2829
Re: Cowon D2
« Reply #30 on: October 23, 2007, 02:57:53 AM »
I could be wrong - but I don't think linuxstb meant for you to run lsusb on your Mac - that's not part of the test. I'd very surprised if there's a port of it for OSX, as the USB stacks are utterly different, and I doubt OSX presents it's USB devices in the same device tree as linux does.
Logged

Read The Manual Please

Offline man.dovvn

  • Member
  • *
  • Posts: 9
Re: Cowon D2
« Reply #31 on: October 23, 2007, 04:35:56 AM »
Huge help if we have the chip's manual.
Please keep poking around and I'll be in to help when I can.
Logged

Offline Yeeze

  • Member
  • *
  • Posts: 40
Re: Cowon D2
« Reply #32 on: October 23, 2007, 05:51:36 AM »
@punit:
When I understood this right, with a mac, you can access the D2 in USB-boot mode (When you connect it and hold the Menu button down), and then you can use Tcctool, to comunicate with the D2, while installing the firmware...

I hope linuxstb reads this, so he can tell you, what you need to do, and what he exactly needs!!
Logged

Offline GodEater

  • Member
  • *
  • Posts: 2829
Re: Cowon D2
« Reply #33 on: October 23, 2007, 06:29:15 AM »
Quote from: Yeeze on October 23, 2007, 05:51:36 AM
I hope linuxstb reads this, so he can tell you, what you need to do, and what he exactly needs!!

He's in France this week, so probably less active than usual. Have patience :)
Logged

Read The Manual Please

Offline linuxstb

  • Developer
  • Member
  • *
  • Posts: 1163
Re: Cowon D2
« Reply #34 on: October 23, 2007, 12:13:57 PM »
Here is what a Mac user needs to do to test tcctool (as GodEater speculated, lsusb isn't needed):

1) Download and install libusb.  I've put the packages I've used here (I've forgotten the original URLs):

http://www.davechapman.f2s.com/rockbox/libusb-10.4u.sdk.pkg.tar.gz
http://www.davechapman.f2s.com/rockbox/libusb.pkg.tar.gz

2) Download the tcctool source from the Rockbox SVN.  You'll need the "subversion" tool installed:

svn co svn://svn.rockbox.org/rockbox/trunk/utils/tcctool tcctool

3) Type "cd tcctool" followed by "make" to compile tcctool.

[NOTE: For the following steps, you will need to become root]

4) Connect your D2 to your Mac in USB boot mode - hold the MENU button as you switch the D2 on.  The LCD won't display anything.

5) Test tcctool by uploading the "d2N.bin" file from the original firmware.  You should test with the d2N.bin file from the same version of the original firmware that is installed on your device:

./tcctool -d cowond2 /path/to/d2N.bin


This will take a few seconds to upload the firmware file, and if tcctool is working, you should see the original firmware run.

I'm aware that the D2 firmware comes in two folders - "0" and "1".  I've no idea what the difference is, but I would probably try the one in "1".

Logged

Offline dalmane98

  • Member
  • *
  • Posts: 5
Re: Cowon D2
« Reply #35 on: October 23, 2007, 08:11:15 PM »
I am doing some speculating here about folder 0, but I believe I am close to what happens when you update the firmware.

Folder 0 contains files that are similar to the recovery program (FWDN). I say this because in some of the firmware updates Cowon did not have you use the contents of folder 0 unless you were using an older firmware version. You also did not lose any files you had transferred to the D2

i.e. if using 2.24 use folder 0, if using 2.26 use the contents of folder 1 and then apply the contents of folder 2. Just using folders 1 and 2 normally does not erase any of the data you have loaded on the D2.

The use of folder 0 always erases your data. Cowon has a warning that "all data in D2 will be deleted, so please back up your data." Here is a link to Cowon’s instructions:

http://www.cowonglobal.com/zeroboard/zboard.php?id=C08&page=1&sn1=&divpage=1&bmenu=download&sn=off&ss=on&sc=on&select_arrange=headnum&bmenu=download&desc=asc&no=281&bmenu=download

Almost all the D2’s that have been bricked are bricked after applying the contents of folder 0. The D2 is no longer recognized by the computer and the New Hardware Wizard appears.

The most recent updates have required that you use all 3 folders.

After dropping the contents of folder 0 into the D2, disconnecting it and turning it on to install the file, the D2 will display a firmware version of 0.00 if you turn it on after it shuts off as part of the firmware upgrade, without connecting it to the computer (this is not part of the upgrade process).

Folder 2 contains the files that are modified for themes and to apply a patch that makes the fonts larger on the D2.
Logged

Offline linuxstb

  • Developer
  • Member
  • *
  • Posts: 1163
Re: Cowon D2
« Reply #36 on: October 23, 2007, 08:25:56 PM »
dalmane98,

So if I'm understanding what you're saying, the "0" firmware is just a temporary firmware which is only needed in some circumstances in order to be able to upgrade to the "1" firmware?

In all cases, "1" is the final firmware file installed?

This would imply that the "1" firmware is definitely the one to use with tcctool.
Logged

Offline shotofadds

  • Developer
  • Member
  • *
  • Posts: 368
Re: Cowon D2
« Reply #37 on: October 24, 2007, 04:26:04 AM »
Having had a poke around with the disassembler, on a first glance both images look like executable-type image to be loaded into RAM (they're both unpacked and unencrypted for the curious).

I doubt very much that either of these images are flashed to ROM, given that (certainly in the case of the "1" image) the code needs read/write access to the data sections within it.

The "1" image certainly seems to contain the main software for the D2 - there are a LOT of useful strings in there....
Logged

Offline linuxstb

  • Developer
  • Member
  • *
  • Posts: 1163
Re: Cowon D2
« Reply #38 on: October 24, 2007, 05:16:30 AM »
Having read/write sections doesn't prevent code being flashed to ROM - it's common for code to be stored in flash ROM, and then copied to RAM and run from there.

On the Telechips devices I know about (which excludes the D2), the firmware appears to be stored in a "hidden" (i.e. not exposed via UMS) part of the main NAND flash disk.  It's then loaded to RAM by the small boot-ROM embedded in the telechips SoC and executed - "NAND boot mode".

So the installation of a new firmware involves writing it to this hidden part of the main NAND disk.  If this part of the NAND disk gets corrupted, or the firmware stored there is bad, then you need to use the recovery tool, which uses the "USB boot mode" to load and execute code via USB, instead of the NAND disk.
Logged

Offline dalmane98

  • Member
  • *
  • Posts: 5
Re: Cowon D2
« Reply #39 on: October 24, 2007, 06:26:08 AM »
Quote from: linuxstb on October 23, 2007, 08:25:56 PM
dalmane98,

So if I'm understanding what you're saying, the "0" firmware is just a temporary firmware which is only needed in some circumstances in order to be able to upgrade to the "1" firmware?

In all cases, "1" is the final firmware file installed?

This would imply that the "1" firmware is definitely the one to use with tcctool.

You are understanding me just fine.

Here is a link to instructions from Cowon that show it in more detail:

http://www.cowonglobal.com/zeroboard/zboard.php?id=C08&page=1&sn1=&divpage=1&bmenu=download&category=21&sn=off&ss=on&sc=on&select_arrange=headnum&bmenu=download&desc=asc&no=273&bmenu=download

I can send you detailed user observation (what happened at each step) for upgrading from to 2.46 and then to 2.50.
Logged

Offline Yeeze

  • Member
  • *
  • Posts: 40
Re: Cowon D2
« Reply #40 on: October 24, 2007, 07:24:54 AM »
I made some tests with the "0" firmware, and it is actually a basic firmware, I can play music and browse the content, but it is quite messed up, there are a lot of bugs with rendering, and not all features work...
Since I installed the resource file from 3.51, not all pictures are loaded, but I think, the the file in folder "1" only updates the firmware(installs the new features and stuff), so isn't the file in folder "0" the important one?

Anyways next I will see if a formated D2 can install only the file from folder "1", I'm just a little scared that this could brick my D2, what do you think?
Logged

Offline linuxstb

  • Developer
  • Member
  • *
  • Posts: 1163
Re: Cowon D2
« Reply #41 on: October 24, 2007, 10:00:35 AM »
Yeeze,

If I was you, I wouldn't play too much with the firmware updates, although the recovery tool looks like it should help you recover from any mishaps.

In terms of porting Rockbox (which after all is the subject of this thread), the most important thing is being able to test-run code without permanently installing it on the device (so you can easily recover when it inevitably crashes) - which is what tcctool should hopefully do.

Logged

Offline punit

  • Member
  • *
  • Posts: 7
Re: Cowon D2
« Reply #42 on: October 24, 2007, 12:50:34 PM »
Following linuxstb's instructions, I was successfully able to upload firmware d2N.bin from the "1" folder.

The D2 started successfully, after the upload.

I had to change tcctool.c to increase the maximum size of allowed firmware.

Hurray!

Now that we can upload programs to the D2 and transfer control to it - What's next on the agenda? Anybody have a working toolchain and a rockbox compiled binary for testing?
Logged

Offline saratoga

  • Developer
  • Member
  • *
  • Posts: 9369
Re: Cowon D2
« Reply #43 on: October 24, 2007, 01:09:19 PM »
Probably figure out how the LCD works and then write a driver for it so that you can print things to teh screen.
Logged

Offline Bagder

  • Member
  • *
  • Posts: 1447
    • Daniel's site
Re: Cowon D2
« Reply #44 on: October 24, 2007, 03:54:14 PM »
For toolchain, run the tools/rockboxdev.sh script in the rockbox source tree to get that setup.

Most often, we first work on getting the bootloader to build and run, and it more or less implies working LCD and button drivers, together with the ability to read the nand flash (so that rockbox can be read from it).
Logged

  • Print
Pages: 1 2 [3] 4 5 ... 65
« previous next »
+  Rockbox Technical Forums
|-+  Rockbox Development
| |-+  New Ports
| | |-+  Cowon D2
 

  • SMF 2.0.19 | SMF © 2021, Simple Machines
  • Rockbox Privacy Policy
  • XHTML
  • RSS
  • WAP2

Page created in 0.114 seconds with 18 queries.