Page 8 of 73 FirstFirst ... 567891011 18 58 ... LastLast
Results 71 to 80 of 728

Thread: Dell bios, how to decompose / mod.

  1. #71
    Administrator Yen's Avatar
    Join Date
    07 May 2007
    Location
    In your mind!
    Posts
    10,738
    Thanks Information

    Default

    Quote Originally Posted by Apokrif View Post
    Update:
    Compared “search & unpack” procedure between different Dell BIOSs – it’s same, except module type and length might be stored in 3 different ways - described few times early already in this thread.

    Unpack procedure size is 128 bytes asm code – it’s a "flavor" of LZ77
    I have wrote LZ77 decoder in C# already.
    If anybody can get/find C# source of ANY LZ77 encoder WITHOUT Huffman part – I can modify it to produce Dell compatible encoding.
    Alternatively, it should be piece of cake to get C/C++ source of LZ77 and do the same, but I’m not quite good in C/C++.

    Bottom line: without encoder we cannot do much anyway…
    LZ77 = Lempel-Ziv algo from 1977, you need it 'pure' so LHARC, LH, ARJ, PAK wouldn't work?

    Seems to be Chinese:
    http://read.pudn.com/downloads33/sou...1/lz.cpp__.htm

    Here you have to pay for:
    http://en.pudn.com/downloads33/sourc...106575_en.html

    You can PM andyp, his tools are using different kind of compressors. Maybe he knows where to get the source. It should be possible. Before we continue we should be able to encode again.
    "I have seen all the works that are done under the sun; and, behold, all is vanity and a striving after wind." ~Prophet OT
    The stronger a false idea the more suffer will be created to recognize it as illusion. ~Yen

    Consider to delete whatsapp!!! Alternatives ~Yen.

  2. #72
    MDL Senior Member
    Join Date
    30 Jul 2009
    Posts
    267
    Thanks Information

    Default

    Quote Originally Posted by Yen View Post
    LZ77 = Lempel-Ziv algo from 1977, you need it 'pure' so LHARC, LH, ARJ, PAK wouldn't work?

    Seems to be Chinese:
    http://read.pudn.com/downloads33/sou...1/lz.cpp__.htm

    Here you have to pay for:
    http://en.pudn.com/downloads33/sourc...106575_en.html

    You can PM andyp, his tools are using different kind of compressors. Maybe he knows where to get the source. It should be possible. Before we continue we should be able to encode again.
    What about this would this work? http://www.autoitscript.com/code/

  3. #73
    MDL Addicted
    Join Date
    08 Dec 2008
    Location
    F000:FFF0
    Posts
    542
    Thanks Information

    Default

    Quote Originally Posted by Yen View Post
    LZ77 = Lempel-Ziv algo from 1977, you need it 'pure' so LHARC, LH, ARJ, PAK wouldn't work?
    Cannot tell for sure, most likely not. All of them uses LZ77/LZSS + something on top like Huffman coding
    I need to get “pure” LZ77 and modify to match Dell one.

    >Seems to be Chinese:
    They both C/C++, I need C#...
    pudn.com has C# version also, but there is no preview avail – might be something useless completely.

    >You can PM andyp,
    AFAIR, he is C/C++ guy

    >Before we continue we should be able to encode again.
    For SLIC mod – yes.
    Or we can try to replace striped RAID module to full one to prove we can replace modules at all.

    Quote Originally Posted by wolf69 View Post
    What about this would this work?
    That’s C++ LZSS implementation.

    I guess, I can post Dell asm (and a little description?) so our experts can tell if compressor code exists already?

  4. #74
    Administrator Yen's Avatar
    Join Date
    07 May 2007
    Location
    In your mind!
    Posts
    10,738
    Thanks Information

    Default

    Here is another C code. C# seems hard to find:
    http://www.programmersheaven.com/dow...0/ZipView.aspx
    If you would compile it and try to check for its output?

    And here: Somebody 'complains: the language is just a wrapper.' it is written in assembly:
    http://www.programmersheaven.com/dow.../download.aspx
    "I have seen all the works that are done under the sun; and, behold, all is vanity and a striving after wind." ~Prophet OT
    The stronger a false idea the more suffer will be created to recognize it as illusion. ~Yen

    Consider to delete whatsapp!!! Alternatives ~Yen.

  5. #75
    MDL Addicted
    Join Date
    08 Dec 2008
    Location
    F000:FFF0
    Posts
    542
    Thanks Information

    Lightbulb

    Quote Originally Posted by Yen View Post
    Here is another C code. C# seems hard to find
    Exactly.
    >If you would compile it and try to check for its output?
    http://forums.mydigitallife.info/sho...3&postcount=39
    The post has example of compressed/uncompressed parts.
    Have you seen any compressor does something alike?

    Anyway, I’ll try to concentrate on compressor now.
    You, guys, tell what else we need to be able to replace a module in HDR file:
    1. Uncompress module – done.
    2. Compress module – in progress
    3. Replace module (could be done in winhex, better write program)
    4. One or two CRC32 fix-up (could be done in winhex, better write program)
    5. What else?

    We still need to understand HDR structure better.
    I have a feeling, something need to be fixed in the loader module (LM) too - it’s very similar between all Dell BIOSes.
    To prove, we need to decompose few BIOS versions for same Dell model and see how LM have changed between versions.
    Could somebody do this part?
    It should be done by person understanding to do manual dell bios mod (Yen, BBSC, Shakeyplace)
    I can write how to tell LM from others.

    Another proof, the loader module is very important – I haven’t found de-compressor code in any other modules. That makes me think, LM has all other modules map and knows if a module compressed or not and what to do with it.

    And we obviously need a project manager to coordinate all efforts, so we won’t do same thing twice.
    Anyone?

  6. #76
    MDL Addicted
    Join Date
    08 Dec 2008
    Location
    F000:FFF0
    Posts
    542
    Thanks Information

    Lightbulb

    Update: compressor version 0.01 is ready.
    It creates file compatible with Dell un-compressor, but about 10% bigger in general.
    To make further progress, I’ll need to implement something called the "lazy coding" or "non-greedy" selection – i.e. lots of work.

    BTW: Finally identified used algorithm - it's combination LZSS & RLE
    I guess, I can post (separately) how it works and give few code samples, if anybody wants to help with development

    Current results: (XPS 400 ACPI module)
    Code:
    00-02-02.rom - 23,165 (original)
    00-02-02.bin - 32,768 (unpacked)
    test.rom – 23,785 (repacked)
    I guess, once SLIC is inserted here, it’ll be even bigger…
    The good thing – it’s plenty of space available
    XPS 400 first section has 68,572 “FF filled” gap.

    If you consider yourself “Dell BIOS super-mods” AND ready to experiment – let me know, I’ll PM tools link.
    Once again, I would suggest system with BIOS recovery available first like Latitude D610.

  7. #77
    MDL Addicted
    Join Date
    08 Dec 2008
    Location
    F000:FFF0
    Posts
    542
    Thanks Information

    Lightbulb

    Fiddled with compressor a little bit more, made it work slightly better original.
    BTW: funny result - marker 2.1 can be compressed to exact size of marker 2.0
    I.e. only marker replacement + one (or two) crc32 correction(s) needed for SLIC upgrade
    Code:
                                original     custom
                 uncompressed compressed compressed
    00-B9K-48.rom         182        170        169 // marker 2.1
    00-BMK-48.rom         182        170        169 // marker 2.1
    00-M09-48.rom         182        170        169 // marker 2.1
    00-09-48.rom          182        169        167 // marker 2.0
    00-0A-49.rom          156        158        158 // pubkey
    00-01-01.rom        65536      36961      36510 
    01-1D-4D.rom       100912      66415      65374
    If anybody wanna try, I can post custom compressed SLICs

  8. #78
    MDL Member
    Join Date
    03 Nov 2008
    Posts
    118
    Thanks Information

    Default

    Great work Apokrif!

    If you want to share the load of putting a tool together, I'd be glad to help.

  9. #79
    MDL Addicted
    Join Date
    08 Dec 2008
    Location
    F000:FFF0
    Posts
    542
    Thanks Information

    Lightbulb Next steps...

    Quote Originally Posted by pix View Post
    Great work Apokrif!
    If you want to share the load of putting a tool together, I'd be glad to help.
    I’ll post some info (well known, most likely) and post tools than.
    I’ll try to describe as much as I can to avoid repetitive questions.
    Could you read and correct if you think I’m mistaken, please?
    I do it to make sure, we are on the same page before we broke anything because of misunderstanding…

  10. #80
    MDL Addicted
    Join Date
    08 Dec 2008
    Location
    F000:FFF0
    Posts
    542
    Thanks Information

    Lightbulb HDR file block structure

    All information below was posted at least few times. All credits goes to bbsc/rtfm

    How to get HDR file:
    Download BIOS update exe file (for windows) from Dell site and run it with –writehdrfile switch
    For XPS 400 it’s:
    xp051a07.exe -writehdrfile

    HDR file consists of one or two blocks: romfile and optionally kromfile.
    Easiest method to tell – run:
    xp051a07.exe -writekromfile
    will respond with either: “Invalid command line...” for romfile only HDR file
    or
    d630_a16.exe -writekromfile
    “File D630_A16.bin written” for romfile + kromfile one.

    One block structure example:
    Run xp051a07.exe -writehdrfile
    Get xp051a07.hdr

    Open in WinHex or your favorite hex editor. You will see:
    Code:
    000000-000007 - $RBUT version
    000008-00002F - copyright message
    000030-000032 - BIOS version
    000038-00003F - model number (?)
    
    000054-070053 - romfile
    070054-070057 - romfile crc32 (inverted)
    -----------------------------------------
    So crc32 of 000054-070057 - (i.e. romfile + crc32) = FFFFFFFF
    * To calculate crc32 in WinHex:
    1. Select block
    2. Menu -> Tools | Compute hash | CRC32 (32 bit)
    
    070058-07005B – whole file crc32 (inverted)
    -----------------------------------------
    So crc32 of 000000-07005B - (i.e. whole file) = FFFFFFFF
    Two block structure example:
    Run d620_a10.exe -writehdrfile
    Get d620_a10.hdr

    Code:
    000000-000007 - $RBUT version
    000008-00002F - copyright message
    000030-000032 - BIOS version
    000038-00003F - model number (?)
    
    000054-100053 - romfile
    100054-100057 - inverted crc32(romfile)
    -----------------------------------------
    So crc32 of 000054-100057 - (i.e. romfile + crc32) = FFFFFFFF
    
    100058-110057 - kromfile
    110058-11005B - inverted crc32(romfile + kromfile)
    -----------------------------------------
    So crc32 of 000054-100053 and 100058-11005B 
    (i.e. romfile + kromfile + crc32) = FFFFFFFF
    * Note that range 100054-100057 (inverted crc32(romfile)) is 
    excluded from calculation.
    If you want to calculate two range crc32, you have to write both 
    ranges to files, concatenate them and calculate crc32. 
    Or you can write a simple program to do it.
    
    11005C-11005F - whole file crc32 (inverted)
    -----------------------------------------
    So crc32 of 000000-11005F - (i.e. whole file) = FFFFFFFF
    Notes:
    * If you extract first block and padded it with FF – you will get very same romfile,
    the one you can get with –writeromfile switch.
    ** kromfile, extracted with –writekromfile, exists as is in hdr file,
    thus makes it easy to locate end of first block (the romfile)

    Bottom line:
    If you edit romfile content, you have to correct 2 crc32 for one block hdr file and 3 crc32 for two blocks hdr file.

Similar Threads

  1. Replies: 0
    Last Post: 20 Jun 2016, 22:10
  2. Replies: 4
    Last Post: 27 Jul 2013, 00:47
  3. Dell inspiron 1545, Phoenix Dell BIOS, MOD bios image question
    By techsupportspecialist in forum BIOS Mods
    Replies: 0
    Last Post: 18 Jul 2011, 12:49
  4. Replies: 3
    Last Post: 01 Aug 2010, 21:08
  5. Replies: 3
    Last Post: 06 Jun 2010, 07:05

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •