Third Party > Repairing and Upgrading Rockbox Capable Players

Reflashing H120 via BDM (done, with pics)

<< < (2/2)

kpapr1:
I have a few questions :

1. No xtal on the schematic. Do you use the 8MHz internal clock, or an external 16MHz clock like a readme file somewhere says?

2. I suppose bdm.hex is the program file to flash into the AVR

3. I need to compile usbdump.c but the libusb.h is missing. Where can I find it?

4. If I understand correctly the procedure is this:

a) connect wires+usb from H1x0 to AVR and power up. The H1x0 will enter hault mode.
b) power-off AVR (H1x0 will remain ON), disconnect usb from avr and connect to PC
c) run usbdump reflash.bin

Is it correct, or do I need to compile/do  anything else ( besides usbdump)?

Thanks

edit: I found the missing library, but now I get a lot of linker errors

ReK:
1. Err, forgot to put that in. 16mhz crystal with the usual capacitors to ground. You can use other crystals (12, 16, 20), but v-usb needs to be reconfigured and rebuilt.

2. Correct.

3. Install libusb, that should be the only dependency.

4. No, the reflashing is done through the AVR. Wire it all up, turn on the H120, and it should enter the halted state (the AVR will be on because it's getting power via USB). Then run usbdump on the attached PC and it should reflash. Offhand I think you can make the USB connection after the H120 has been powered up (the H120 powers the board), but I'm not sure.

kpapr1:
Thanks for the clarifications.

So, if I understand correctly, I need to have both AVR and iriver connected to the PC?

I put the libusb.h in the include directory but now I get a lot of linker errors. Is there something else I must configure in the C compiler?
 

ReK:
The iriver will be connected to the AVR, via the debug lines. The AVR will be connected to the computer via USB. You can't just include the header, you'll need to install the full libraries to link against them.

Navigation

[0] Message Index

[*] Previous page

Go to full version