[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: *nix flash utility for BTC DVD recorders



On Thu, Apr 29, 2004 at 02:14:51PM +0200, Joerg Schilling wrote:
> Hi, nice idea!
> 
> But why didn't you use libscg to send the commands? This way, you would
> get portability to many operating systems.....

Ah, while I use the excellent cdrecord, I didn't know about libscg :)
I had been working with dvd+rw-booktype from dvd+rw-tools, so they
were at the top of my mind :)

> -rw-r--r--    1 root     cdrecord     6905 Apr 29 14:10 btcflash-0.1-sspm.tar.bz2
> 
> Is a SSPM file made from the Scgskeleton code and your code.
> Just untar it in the cdrtools source root directory and call "make install"

Thanks! I haven't had a chance to try it yet, but I think there's a
minor bug with the conversion. The idea is to write the firwmare to
the drive starting at offset 0x20, and write the checksum in offsets
0x00 to 0x1f. (I suspect the order doesn't matter, but the Windows
flash utility was writing the firmware first, then checksum, so I
followed it).

Also, if it no longer requires transport.hxx, no need to say it does
in the comments :)

--- btcflash.c.orig	2004-04-29 15:34:32.000000000 -0500
+++ btcflash.c	2004-04-29 15:35:24.000000000 -0500
@@ -11,9 +11,6 @@
  * USE AT YOUR OWN RISK! 
  * btcflash is provided AS IS, with NO WARRANTY, either expressed or implied.
  *
- * Requires "transport.hxx" from Andy Polyakov's DVD+RW tools:
- * http://fy.chalmers.se/~appro/linux/DVD+RW/tools/
- *
  * Firmware files may be obtained by running BTC's Windows flash
  * utility, then searching in the WINDOWS\TEMP or WINNT\TEMP directory
  * for a *.HEX file. It will probably be in a subdirectory named
@@ -228,7 +225,7 @@
 	for (offset = 0; offset < FLASHSIZE; offset += 0x1000) {
 		if (write_buffer(scgp,	6 /* Download Microcode with Offsets */,
 					0 /* Buffer ID 0 */,
-					offset, 0x1000, (char *)fwbuf + offset) < 0) {
+					offset + 0x20, 0x1000, (char *)fwbuf + offset) < 0) {
 			errmsgno(EX_BAD, "Cannot write microcode\n");
 			return 1;
 		}


-- 
Name: Dave Huang         |  Mammal, mammal / their names are called /
INet: khym@azeotrope.org |  they raise a paw / the bat, the cat /
FurryMUCK: Dahan         |  dolphin and dog / koala bear and hog -- TMBG
Dahan: Hani G Y+C 28 Y++ L+++ W- C++ T++ A+ E+ S++ V++ F- Q+++ P+ B+ PA+ PL++



Reply to: