Re: A92: The results. (was TIOS: Can't live with is. Can't livewithout


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

Re: A92: The results. (was TIOS: Can't live with is. Can't livewithout it?)




> If what I understand about the ROMand RAM is true, then 1) there is 128Kb 
> (kilobytes) of ram, and the ROM stores the factory defaults in some 
> unreachable form.  2), when the calc is reset, the info in the ROM overrites 
> the RAM, and the factory defaults are restored.  3) that 62someodd kb of ram 
> that the OS "uses" *can* be messed with.  
> Then we could do something like this:
> The nontios boots up and compares the existing TIOS with the ROM's default 
> TIOS, it logs the differences, and then erases the existing TIOS. Then when 
> it's finnished, it puts TIOS back on, and re-impliments the changes, this 
> way, While the nontios is booted, it can use 128k, but otherwise, it can just 
> sit uselessly in the remaining RAM, with just a fer kb to store functions, 
> variables ect for TIOS.  

That's a waste.  There is no need to "log" any differences.  Unless you are some
kind of idiot, no one does things to their calculators without taking backups.
The TIOS in the ROM can rebuild itself.  Simply make sure that the Initial Reset
Program Counter ($04) is set to the ROM function it's at now.  This function is
responsible for setting up the system (filesystem and all).

Now, to simplify things try this: Take the object data for the new OS and store
it in a .92p as data along with a program that simply copies the data to the
"low" memory.  It also messes with the Stack Pointers.  Since the stack will
have some references to the TIOS, we will need to delete the entire stack.  The
new OS's startup function will be placed as the first LONG in the stack.  The
stack pointer is then set to point right in front of it.  Then the RTS at the
end of the loader program will cause the M68000 to then launch the new OS.  All
data transfer is done using the existing TIOS's send/receive functions.  We do
need to implement our own transfer functions since the TIOS uses it's own file
management routines.

The "2ND-HAND-ON" probably has a hardware reference to the RESET vector.  If we
change the RESET vector to somewhere in the new OS, we can prevent the calc from
getting reset back to the TIOS.  We just need a way to get that pointer back to
the ROM function or else the calc does become a paper weight.  That is why we
need a research team to play around with emulators and then the real calculator.


====
Aaron Hill (Redmond, Wash.)
Electronic Mail: serac@lightmail.com
IRC Nickname: serac (on EF-Net)
ActiveWorlds Citizenship: serac



References: