Unofficial Name: enoughmem
Call Address: 443A
Returns the amount of free user memory.
- HL : quantity to which you want to compare the current amount of free user memory
- carry flag : set if HL > current free memory
Let's say you need 1000 bytes of free ram as a temporary buffer. At the beginning of your program, you can test of there is enough memory, and stop if there isn't :
ld hl,1000 call _enoughmem ret c ; returns to the TI-OS or shell if there is not enough free memory