Jump to content
IGNORED

when I do not use FP routines... are those ZP locations free?


Recommended Posts

I need some ZP locations...

 

I don't use the FP routines, and Mapping the Atari tells me it is safe to use $D4 to FF then. I'm a bit 'scared' ... but please tell me mapping is right.

 

I also don't use BASIC. Can I also use D2 and D3 then?

 

I'm asking this, because I thought that everything from CB and up was free to use. So if it is not... I have to rewrite a few things.

 

Thanks

M.

Link to comment
Share on other sites

I need some ZP locations...

 

I don't use the FP routines, and Mapping the Atari tells me it is safe to use $D4 to FF then. I'm a bit 'scared' ... but please tell me mapping is right.

 

I also don't use BASIC. Can I also use D2 and D3 then?

 

I'm asking this, because I thought that everything from CB and up was free to use. So if it is not... I have to rewrite a few things.

 

Thanks

M.

 

If you are not using Basic you can safely use $80-$D3, and if you aren't using FP then $D4-$FF should also be safe.

 

Dan

Link to comment
Share on other sites

I need some ZP locations...

 

I don't use the FP routines, and Mapping the Atari tells me it is safe to use $D4 to FF then. I'm a bit 'scared' ... but please tell me mapping is right.

 

I also don't use BASIC. Can I also use D2 and D3 then?

 

I'm asking this, because I thought that everything from CB and up was free to use. So if it is not... I have to rewrite a few things.

 

Thanks

M.

 

If you are not using Basic you can safely use $80-$D3, and if you aren't using FP then $D4-$FF should also be safe.

 

Dan

If you do not believe him, I can confirm that as I use the locations from $80 upwards since years. As any assembler on A8 does :)

If you go a step further and do not even use teh Os you can use a lot more (maybe all?) locations.

Link to comment
Share on other sites

... if you're using CC65 (which I think not) then you can have problems with some of the ZP being used (as I found).

 

You should be declaring your variables as .zeropage, and then the compiler will allocate them into zeropage for you... no need to guess what's being used and where. I assume from your statement that you aren't doing this? (Well, to each his own, but there is an easier way to manage zeropage variables-really you shouldn't care (or even have to know) what zeropage address is actually being used by a CC65 variable.)

Link to comment
Share on other sites

... if you're using CC65 (which I think not) then you can have problems with some of the ZP being used (as I found).

 

You should be declaring your variables as .zeropage, and then the compiler will allocate them into zeropage for you... no need to guess what's being used and where. I assume from your statement that you aren't doing this? (Well, to each his own, but there is an easier way to manage zeropage variables-really you shouldn't care (or even have to know) what zeropage address is actually being used by a CC65 variable.)

 

Hi Shawn,

Thanks for your suggestion here. I wasn't actually using variables as such, I was POKE'ing directly to some locations and using these as "virtual variables". I've stopped doing this now, so it isn't a problem any longer.

 

Thanks, Steve

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...