[comp.sys.cbm] Koalapic Memory Splitting on a C-128

sean1@garfield.UUCP (04/20/87)

I posted a request for info a few months ago on how to display a Koalapic on
a 128 using BASIC 7.0 and I got a detailed answer. But it involved having the
koala 40 block file already split up into its respective memory chunks,
residing at their proper addresses, as three seperate files.

Could someone please tell me what parts of the 40 block file go in what
locations? Perhaps someone could send a sequence of commands for the MONITOR
so I could load the file into memory, use the monitor to split up the sections
of memory and resave the sections at their proper locations?

I would appreciate any help in the matter.



          /|
         / /       //   Sean Huxter   |UUCP: {utai,cbosgd,ihnp4,akgua,
    ____/_/__ __  | |   P.O. Box 366  |    allegra}!garfield!sean1
 -=<_________|__|=|<|   Springdale    |CDNNET: sean1@garfield.mun.cdn
        \ \       | |   NF, Canada    |
         \ \       \\   A0J 1T0       | "THUNDERBIRDS are GO!"
          \|

fred@cbmvax.cbm.UUCP (Fred Bowen) (04/30/87)

> Could someone tell me what parts of the [Koala] 40 block file go in what
> locations? Perhaps someone could send a sequence of commands for the MONITOR
> so I could load the file into memory, use the monitor to split up the sections
> of memory and resave the sections at their proper locations?

Koala pics are stored in a PGM type file with a load address of $6000.  You
can follow the steps below to break it up and display it on the C128.  I am
assuming you have both 40 and 80 column screens (doesn't everybody?) to look
at, else you will have to type blind or modify the procedure to suit:

	GRAPHIC 3,1		:REM  MULTICOLOR BITMAP
	BLOAD"picture name"
	MONITOR

	T 6000 7F3F 2000	:MOVE BITMAP
	T 7F40 8327 1C00	:MOVE VIDEO MATRIX

	>1 74			:SWITCH TO MC NYBBLE BANK
	T 8328 870F FD800	:MOVE COLOR NYBBLES (IGNORE ERRORS!)
	>1 75			:RESTORE TEXT NYBBLE BANK

	>8710			:GET EXT/BG COLOR BYTE, SPLIT INTO msb/lsb
	>FD020 msb lsb		:PUT EXT/BG COLORS
	
And that should do it- the picture on you VIC screen should be correct.  Now,
to save the pieces, type:

	S "pic.bitmap",8,2000,4000	:SAVE BITMAP CHUNK
	S "pic.vidmat",8,1C00,2000	:SAVE VIDEO MEM CHUNK
	>1 74				:SWITCH NYBBLE BANK
	S "pic.colnyb",8,FD800,FDC00	:SAVE COLOR NYB CHUNK
	>1 75				:RESTORE NYBBLE BANK

You can now reLOAD the pic anytime using the example BLOADs I posted so
many moons ago.  You have to figure out what to do with the border and
background colors though.  Just remember to twiddle the nybble bank when
you PEEK/POKE or LOAD/SAVE the color nybbles yourself.  Oh yeah, and
remember the color nybbles are in BANK 15 (I/O space)!

You guys at garfield are some real Koala phreaks, eh?
--
--
-- 
Fred Bowen			uucp:	{ihnp4|seismo|caip}!cbmvax!fred
				arpa:	cbmvax!fred@seismo.css.GOV
				tele:	215 431-9100

Commodore Electronics, Ltd.,  1200 Wilson Drive,  West Chester,  PA,  19380