z88dk forums

z80 Development Kit

You are not logged in.

  • Index
  •  » Misc
  •  » Just want to let you know z88dk ROCKS !!!

#1 2008-04-21 03:27:58

norecess
Member
From: Montreal, Canada
Registered: 2008-03-20
Posts: 73
Website

Just want to let you know z88dk ROCKS !!!

Hey guys,

I think sometimes it's important for a project to receive some user-feedback, not only bug-reports or feature-requests, but simple statement of released work.

Thanks to z88dk (and some precious docs !) I'm now able to uncompress in realtime 2 RGB444-colors-based images (using advanced hardware features of Amstrad CPC 6128 Plus), resized to fullscreen (overscan) or vertical-screen (still overscan !), all of this playing a ZX-Spectrum converted music.

Best of all, this is the source of the main application.... seriously, I just want to say z88dk ROCKS !! it's incredible to see how fast it is now to program this brave Z80... yikes)

Code:

// ----------------------------------------------------------------------------
void callbackUnpack( )
{
    crSYNCWaitVBL( );
    crCRTCFlipScreen( );

    crAYPlay( );
}

// ----------------------------------------------------------------------------
void main( )
{    
    crLIBInit( );

    crSYNCDisableSysInterrupts( );
        asm( "ld sp, $0400" );

    // if end of application > 0x8000, choose 0xc000 as dest-cache
    crAYSetupPlayer( 0xc000 );

    memset( 0x8000, 0, 0x8000 );

    crGASetColor( BORDER, COLOR_BLACK );
    crGASetMode( 0 );
    
    while( 1 )
    {
        crCRTCSetupScreen( OVERSCAN_FULLSCREEN, SCREENSTART_8000, SCREENSTART_8000 );

        crASICSetPalette( crDATAGetPointer( DATA_CHAOS_PAL ) + 8 );
        crPACKERUnpackWithCallback( 0x8000, crDATAGetPointer( DATA_CHAOS ), callbackUnpack );
        
        crCRTCSetupScreen( OVERSCAN_VERTICAL, SCREENSTART_C000, SCREENSTART_C000 );

        crASICSetPalette( crDATAGetPointer( DATA_ALONE_PAL ) + 8 );
        crPACKERUnpackWithCallback( 0xC000, crDATAGetPointer( DATA_ALONE ), callbackUnpack );
    }
}

Offline

 

#2 2008-05-15 19:25:18

norecess
Member
From: Montreal, Canada
Registered: 2008-03-20
Posts: 73
Website

Re: Just want to let you know z88dk ROCKS !!!

Yeah, and few weeks after starting using z88dk, I still think z88dk is really a fresh air in z80 development ! smile

Offline

 

#3 2008-05-16 00:19:41

alvin
Administrator
Registered: 2007-07-16
Posts: 338

Re: Just want to let you know z88dk ROCKS !!!

I agree... it is a much better way to develop z80 code.  It's hard to convince others of this though, but as the tool matures I think it will be harder to ignore the advantages.  I especially look forward to a time when the compiler can seemlessy handle >64k projects.  It would be interesting to see z88dk compiled for an actual z80 target big_smile

Offline

 

#4 2008-05-16 01:14:37

norecess
Member
From: Montreal, Canada
Registered: 2008-03-20
Posts: 73
Website

Re: Just want to let you know z88dk ROCKS !!!

You know, what really bores me with asm code is init - always dealing with registers / memory address / etc. I like using C for these stuff, but still keeping my innerloops in pure ASM for performance reasons.

As a plus, prototyping in C then optimizing in ASM on same target machines is really nice !!

And regarding the tools, it's so nice to pack data on PC and just write the unpacker on target computer !!

Offline

 
  • Index
  •  » Misc
  •  » Just want to let you know z88dk ROCKS !!!

Board footer

Powered by PunBB
© Copyright 2002–2005 Rickard Andersson