xboxscene.org forums

Author Topic: Subfdisk Enhanced  (Read 285 times)

ldotsfan

  • Archived User
  • Hero Member
  • *
  • Posts: 2072
Subfdisk Enhanced
« on: February 26, 2010, 07:37:00 AM »

Code was written by Hector Martin <[email protected]> in 2007.

http://pastebin.com/09HprdBy

Had some ideas on enhancing the xboxhdm-like capabilities and xbpartitioner-like capabilities in this tool and since Python is supported on many OS, it opens up many possibilities. This is WIP and may never be finished. I'm not really a Python coder.

Lines to modify

Line 193, to add BRFR signature.
CODE

                sector = self.device.read(3)
                sig = sector[0:4]
                if sig!="BRFR":
                        raise RuntimeError("Invalid XBOX Config Area signature: '%s'"%repr(sig))



Line 265 , for 32k/64k cluster size support
CODE


if self.numclusters >= 0xfff4:

                        self.fatbits = 32

                        self.arraycode = "I"

                        self.fat_unused = 0x00000000L

                        self.fat_eoc = 0xfffffff8L

                        self.fat_eoc_set = 0xffffffffL

                        self.fat_reserved = 0xfffffff0L

                        self.fat_bad = 0xfffffff7L

                else:

                        self.fatbits = 16

                        self.fat_unused = 0x0000

                        self.fat_eoc = 0xfff8

                        self.fat_eoc_set = 0xffff

                        self.fat_reserved = 0xfff0

                        self.fat_bad = 0xfff7

                        self.arraycode = "H"


Line 211: variable F/G partition sizes
CODE


  if self.useFG:

                                        table.append(Partition(self.device,0x00EE8AB0,0x10000000-0x00EE8AB0,self.prefix+"F","XBOX Extended"))

                                        table.append(Partition(self.device,0x10000000,self.devicesize-0x10000000,self.prefix+"G","XBOX LBA48 Extended"))

                                else:

                                        table.append(Partition(self.device,0x00EE8AB0,self.devicesize-0x00EE8AB0,self.prefix+"F","XBOX Extended"))

                        


There are many parts of the code I am still trying to figure out. If you are familiar with Python, please feel free to contribute.

LBA48 code for my reference: http://forums.xbox-s...&...st&p=764185
Logged