ROMExtensions

ROM Extensions, often abbreviated REx, contain parts of the Newton OS 2.x which are automatically loaded at boot time.

RExes are numbered from 0 to 3. Every original 2.x ROM image includes REx0, which contains many of the built-in packages, diagnostic routines, and hardware configuration.

RExes can be created and unpacked using specific tools. The structure of a REx is relatively simple: a binary header, containing metadata and a simple table of part types, offsets and lengths.

Because RExes are in the ROM address space, any executable code contained within them must be located to its offset in ROM (or to the page that it is mapped to by the MMU?)

Details about the contents of specific REx0 by version: eMate 737041 REx0 MP2x00 717006 REx0? MP130 525314 REx0?

Known valid entry tags for REx parts, from the ROMExtension.h header and extracted REXes:

tagsymbol namerelated base structDescription
'ram 'kRAMConfigTagRAMConfigTableRAM address / bank configuration
'ralc'kRAMAllocationTagRAMAllocTable 
'diag'kDiagnosticsTagnoneMeant for self-contained diagnostics code
'jump'kCPatchTableTag? 
'fexp'kFrameExportTableTag? 
'fimp'kFrameImportTableTag? 
'pkgl'kPackageListTag Stores NewtonOS (NewtonScript) packages in ROM
'pad 'kPadBlockTagnoneInserts empty space in the middle of a REx, to ensure other parts are aligned on block boundaries
'ptpt'kPatchTablePageTableTag  
'glpt'kGelatoPageTableTag Something specific to the MP120 "Gelato" - unique because it could run either OS 1.3 or 2.0
'romt'kROMTimingConfigTagROMTimingConfigTable 
'fsht'kFlashTimingConfigTagFlashBankTimingConfigTable 
'fshb'kFlashTimingBankTagFlashBankConfigTable 
'fshd'kFlashDriverConfigTagFlashDriverConfigTable 
'fdrv'kFlashDriverEntryTagFlashDriverConfigTable or TClassInfo:SFlashDriverEntryOnly defined to have entries for Cirrus/Voyager platforms
'flsa'kFlashAddressTag  
'gpio'unknown Exists in the eMate 300 and MP2x00 REx0, use unknown.

to be continued