Re: [cc65] Atari tgi update

From: Fatih Aygün <cyco1301yahoo.com>
Date: 2009-11-11 16:35:50
Hi,



Christian Grössler wrote:

> I've integrated it into svn now. I've renamed the atari.s files
> to atari-.s files (adding a dash).

Thanks!

> There seem to be some problems, maybe I made a mistake when
> intergrating. Please check the version from svn (or take the
> next snapshot).

I can't access SVN currently. I took the 11.11.2009 snapshot, it seems
to work. I'll check the next one when it's available

> - in tgidemo.c the circles get painted once and cleared once
>   and after some time the x lines vanish. When I compare it
>   to the c64 version, circles should be drawn and cleared
>   until a key is pressed. Also the later stages (checkerboard
>   etc.) aren't printed, only a completely white screen is
>   visible. You can type a key 4 times and then the program exits
>   (nothing painted on the screen in the meanwhile).

That's a palette issue. COLOR_BLACK and COLOR_WHITE doesn't
work for atari. You can change the lines 11 and 12 as

#define COLOR_BACK    0
#define COLOR_FORE    1

for now to test, until an agreement is reached on how to solve this problem.
You might want to check the previous discussions to voice your opinion about
what will work best for atari :)

> - some modes seem to crash after painting the circles. The
>   circles aren't cleared anymore and the program doesn't end.

Circles are not part of the driver anymore. I'll try to track down the problem and
let Uz know if I can find what's wrong.

> I first thought adding Atari specific error codes to tgi-error.inc
> is a bad idea. But then I got TGI_ERR_NO_MEM when I first tried
> the tgidemo sample. That's because I forgot to set __RESERVED_MEMORY__
> when linking. Getting this error saved me felt (gefühlte) 2 hours
> of debugging time where I would have needed to dig into the code
> in order to find out why the driver doesn't load. So I think this
> error code makes pretty much sense and therefore I added it together
> with the other 2 Atari specific error codes you defined. Uz, please
> comment about how you feel about it.

Actually, the drivers don't need TGI_ERROR_UNKNOWN anymore. I check if there is
enough memory before calling the OS routine, because it doesn't behave nicely when it
thinks that it doesn't have enough memory to turn back to gr.0 (text mode). So I don't 
check the returned error because, to my knowledge, the lack of memory is the only way
the call can fail. Please correct me if I'm wrong and I'll change it back.

You might want to check the archives for the __RESERVED_MEMORY__ discussion
I made with Uz. I suggested to make the default value 1, so that the OS can at least return
to the text mode in case of memory lack, and he suggested to use alternate config files instead.

> Thanks again for you efforts, Fatih.

You're welcome, happy to contibute :)

Regards,
Fatih.


      
----------------------------------------------------------------------
To unsubscribe from the list send mail to majordomo@musoftware.de with
the string "unsubscribe cc65" in the body(!) of the mail.
Received on Wed Nov 11 16:35:58 2009

This archive was generated by hypermail 2.1.8 : 2009-11-11 16:36:00 CET