[A82] Re: ROM-offset
[Prev][Index][Thread]
[A82] Re: ROM-offset
> You probably mean this routine (from vertigo 0.94):
Yes.
> If I look at place in page 0 it looks like there's no RET after the code.
> Or is this kinda like the ROM's own ROM_CALL()? Like the bcall() stuff on
> the Ti83+?
>
> So for $3620-$1A that would be:
> call $2E60 ;
> .dw $4233 ; Adress (?)
> .db $02 ; Page (?)
I haven't looked at the TI83+, but the system is the same on all the TI
calcs I have seen. The end of page contains a list of small function which
is used to call routines on other ROM pages. The call is done by the
function at 2E60, which eads the address to call and the ORM page from the 3
bytes after the call. To save space the function 2E60 pop the address from
the stack so no return is needed. So have a look a the three bytes after the
call, and you can see whether actual function is placed. (This function can
be used in normal assembler programs and it is nice to have for code which
is not in the table, but it is important to remember that it does an
automitic ret)
> But what do they do? When I try to follow what's going on inside
> Vertigo my
> head turns all jelly... (But that's what they call "vertigo", isn't it?)
Vertigo is not easy to understand, too many ifdefs :-)
> I guess "ROM_CALL(3620h-1Ah)" deletes the inputbuffer. Does it set the
> pointers to zero or what? I'll just need to try... And
When the shell is started all user mem is used for the imput buffer. The
system RAM contains several pointers which indicates start, end current
position etc. Calling the routine deletes the buffer and sets the pointers
to whatever values the system expects.
> "ROM_CALL(38EAh-1Ah)" presumably recreates the buffer. Could this one be
> called 'stand-alone'? Or do you need to delete the inputbuffer first?
Yep, that one recreates it (allocates the mem and sets the pointers). I have
not tried calling that on by it self, but it should work fine.
>
> BTW: Whew, this game contains lots of info about all Z80 calcs...
>
It does, too bad some of it is not documented elsewhere.
Dines
References: