Help a n00b make a music disk! YAY! :D

All 680x0 related coding posts in this section please.

Moderators: simonsunnyboy, Mug UK, Zorro 2, Moderator Team

Post Reply
User avatar
YQN
Obsessive compulsive Atari behavior
Obsessive compulsive Atari behavior
Posts: 124
Joined: Sat Jul 22, 2017 6:01 pm
Location: Meaux
Contact:

Help a n00b make a music disk! YAY! :D

Post by YQN »

Hi,

In order to make a music disk (with a menu, a scroller and something to visualize YM levels), I'm teaching myself assembly, using mostly Perihelion's and MarkeyJester’s 68K tutorials. To make sure I understand how pixels are organized in the graphic memory I made a little program that displays some text using a 8x8 pixels font stored in a PI1 file, which you can see in glorious action here: https://www.youtube.com/watch?v=DxUPrjhfeQk

The program works as expected (after countless hours of debugging with MonST indeed), the next step would be to display the characters in a 8x8 grid (to check if I got the characters alright I went for the faster way of displaying them, every 16px), but before I proceed I wanted to submit my code for review because it seems messy to me, and I wanted guidance on how to organize it better, not to mention the fact that I came up with this way of using a 8x8 font which is unlikely to be the best way, I'm sure I'm writing stupid code that wastes cycles so all help is appreciated! My end goal with this is to be able to scroll slowly an 8x8 font.

Here's the code to criticize, it compiled successfully with vasm:

Code: Select all

;;;;;;;;;;;;;;;;;;;;;;;;;;;
;	display 8x8 blocks
;;;;;;;;;;;;;;;;;;;;;;;;;;;

	section	text
	
	jsr initialise

	movem.l	font+2,d0-d7		; get palette
;	movem.l	d0-d7,$ff8240		; apply palette

	
	move.w	#2,-(a7)			; get physbase
	trap	#14					; XBIOS
	addq.l	#2,a7				; clear stack
	
	move.l	d0,screen			; store screen memory
	
main
	move.w	#37,-(sp)			; wait vbl
	trap	#14
	addq.l	#2,sp	

	move.l	msgpointer,a0		; pointer into the message
	clr.l	d0					; clear, just to be sure
	move.b	(a0),d0				; put letter ascii value in d0

	cmp	#0,d0					; end of message?
	bne	not_end					; if not, branch
	bra.w	keypress
	
	; move.l	#txt,msgpointer	; reset msgpointer
	; move.l	msgpointer,a0
	; clr.l	d0					; clear, just to be sure
	; move.b	(a0),d0			; put letter ascii value in d0
	
not_end
	move.l	screen,a1
	cmp		#1,d0				; new line?
	bne no_new_line
	addi.l	#160*8,cur_y_pos
	move.l	#0,cur_x_pos
	addi.l	#1,msgpointer		; point to next character
	move.l	msgpointer,a3
	move.b	(a3),d0
	
no_new_line
	move.l	#font+34,a0			; skip res+palette data
	add.l	#1,msgpointer		; point to next character
	subi.l	#$20,d0				; offset so that ' ' is 0
	divu.w	#40,d0				; divide by the # of columns
	clr.l	d1
	move.w	d0,d1				; copy quotient to d1
	cmpi.l	#0,d1
	beq		rowzero				; if quotient is 0: no need to offset vertically
	mulu.w	#160*8,d1
	add.l	d1,a0
	
rowzero:
	clr.l	d2
	move.l	cur_x_pos,d2			;	DEBUG
	add.l	d2,a1
	move.l	cur_y_pos,d2
	add.l	d2,a1

	clr.w	d0					; clear quotient only (w)
	swap	d0					; swap with remainder
	divu.w	#2,d0				; div by 2: new quotient = position of 16 px cluster
	bra		loophorizoffsetcheck

loophorizoffset:
	add.l	#8,a0
	sub.w	#1,d0
loophorizoffsetcheck:
	cmpi.w	#0,d0
	bne		loophorizoffset
	
	swap	d0					; get remainder
	cmpi.w	#0,d0				; if no remainder then even number of 16 px clusters
	beq		skipoddletter
	
	move.l	#7,d1				; 8 pixels tall
loopoddletter:
	move.b	1(a0),(a1)
	move.b	3(a0),2(a1)
	move.b	5(a0),4(a1)
	move.b	7(a0),6(a1)
	add.l	#160,a0
	add.l	#160,a1
	dbra	d1,loopoddletter
	bra.s	skipevenletter
	
skipoddletter:
	move.l	#7,d1				; 8 pixels tall
loopevenletter:
	move.b	(a0),(a1)
	move.b	2(a0),2(a1)
	move.b	4(a0),4(a1)
	move.b	6(a0),6(a1)
	add.l	#160,a0
	add.l	#160,a1
	dbra	d1,loopevenletter

skipevenletter:

	addi.l	#8,cur_x_pos			; update cursor position

	;	KEYPRESS FOR DEBUG
	; move.w	#7,-(sp)			; wait for keypress
	; trap	#1					; GEMDOS
	; addq.l	#2,sp
	

keypress:
	cmp.b	#$39,$fffc02	;space pressed?
	bne	main

	
	

; keypress:
	; move.w	#7,-(sp)			; wait for keypress
	; trap	#1					; GEMDOS
	; addq.l	#2,sp
	
	jsr restore
	
	clr.l	-(a7)
	trap	#1					; GEMDOS

	
	include	'initlib.s'
	
	section data

screen	dc.l	0

font
	incbin	'0012r.PI1'

line1	dc.b	"HELLO WORLD!",1
		dc.b	"                ",1
		dc.b	"                ",1
		dc.b	"LEARNING ASSEMBLY :)",1
		dc.b	"                ",1
		dc.b	"                ",1
		dc.b	"I HAS A NU TRACK:",1,1
		dc.b	" ",1
		dc.b	"CQREFREE/CQRELESS",1,1
		dc.b	"                ",1
		dc.b	"ON SOUNCDCLOUD",1
		dc.b	"                    ",1
		dc.b	"                    ",1
		dc.b	"                    ",1
		dc.b	"                    ",1
		dc.b	"                    ",1
		dc.b	"                    ",1
		dc.b	"ALSO, cluck BITPLANES",0
	even
	
msgpointer	dc.l	line1

cur_x_pos	dc.l	0
cur_y_pos	dc.l	0
Thank you very much if you can help!
Last edited by YQN on Wed Aug 28, 2019 7:36 pm, edited 1 time in total.
User avatar
Cyprian
10 GOTO 10
10 GOTO 10
Posts: 1939
Joined: Fri Oct 04, 2002 11:23 am
Location: Warsaw, Poland

Re: Help a n00b! YAY! :D

Post by Cyprian »

nice code, maybe a bit complicated

I would use movep instead of :
1)

Code: Select all

   move.b   (a0),(a1)
   move.b   2(a0),2(a1)
   move.b   4(a0),4(a1)
   move.b   6(a0),6(a1)
and

2)

Code: Select all

   move.b   1(a0),(a1)
   move.b   3(a0),2(a1)
   move.b   5(a0),4(a1)
   move.b   7(a0),6(a1)
something like that
1)

Code: Select all

movep.l 0(A0),D0
movep.l D0,0(A1)
and

2)

Code: Select all

movep.l 1(A0),D0
movep.l D0,0(A1)
Last edited by Cyprian on Thu Aug 22, 2019 7:18 pm, edited 1 time in total.
Portfolio / Lynx II / Jaguar / TT030 / Mega STe / 800 XL / 1040 STe / Falcon030 / 65 XE / 520 STm / SM124 / SC1435
SDrive / PAK68/3 / Lynx Multi Card / LDW Super 2000 / XCA12 / SkunkBoard / CosmosEx / SatanDisk / UltraSatan / USB Floppy Drive Emulator / Eiffel / SIO2PC / Crazy Dots / PAM Net
Hatari / Steem SSE / Aranym / Saint
http://260ste.appspot.com/
mikro
Hardware Guru
Hardware Guru
Posts: 2200
Joined: Sat Sep 10, 2005 11:11 am
Location: Kosice, Slovakia
Contact:

Re: Help a n00b! YAY! :D

Post by mikro »

There's nothing fundamentally wrong with your code. Over the time you'll learn to use subroutines (bsr + rts) more, some optimisation tricks (divu.w #2,d0 -> lsr.w #1,d0, cmp.w #0 -> tst.w d0 or even no test at all, since move is a test itself) but that's just sugar.

Remember the most important rule: get it working first, then optimise / refactor (restructure) the code. Never the other way around. :)
User avatar
calimero
Fuji Shaped Bastard
Fuji Shaped Bastard
Posts: 2346
Joined: Thu Sep 15, 2005 10:01 am
Location: STara Pazova, Serbia
Contact:

Re: Help a n00b! YAY! :D

Post by calimero »

offtopic: what kind of filter did you use on video...? :)
using Atari since 1986.http://wet.atari.orghttp://milan.kovac.cc/atari/software/ ・ Atari Falcon030/CT63/SV ・ Atari STe ・ Atari Mega4/MegaFile30/SM124 ・ Amiga 1200/PPC ・ Amiga 500 ・ C64 ・ ZX Spectrum ・ RPi ・ MagiC! ・ MiNT 1.18 ・ OS X
User avatar
YQN
Obsessive compulsive Atari behavior
Obsessive compulsive Atari behavior
Posts: 124
Joined: Sat Jul 22, 2017 6:01 pm
Location: Meaux
Contact:

Re: Help a n00b! YAY! :D

Post by YQN »

Thanks guys! :D

I was planning to use subroutines to make it clearer, like I could push the ACSII value to the stack and retrieve it from a subroutine to display it?

Also I'm wondering how to cleverly choose labels, Devpac doesn't seem to deal with local labels, are there rules of thumbs or good practices I should know about?
calimero wrote:offtopic: what kind of filter did you use on video...? :)
It's just a b+w filter from Instagram ("Moon" maybe?) :)
User avatar
thomas3
Captain Atari
Captain Atari
Posts: 160
Joined: Tue Apr 11, 2017 8:57 pm
Location: the people's republic of south yorkshire, uk.

Re: Help a n00b! YAY! :D

Post by thomas3 »

Devpac is fine with local labels. You need a dot before the name (e.g. .label) and you need a global label first. Try it!
User avatar
Zorro 2
Administrator
Administrator
Posts: 2220
Joined: Tue May 21, 2002 12:44 pm
Location: Saint Cloud (France)
Contact:

Re: Help a n00b! YAY! :D

Post by Zorro 2 »

Hi mister n00b :)

There is an example of intro which used display cursor texts with music.
Member of NoExtra Team
User avatar
YQN
Obsessive compulsive Atari behavior
Obsessive compulsive Atari behavior
Posts: 124
Joined: Sat Jul 22, 2017 6:01 pm
Location: Meaux
Contact:

Re: Help a n00b! YAY! :D

Post by YQN »

Zorro 2 wrote:Hi mister n00b :)

There is an example of intro which used display cursor texts with music.
NoExtra sources, might check them all :) Merci!
thomas3 wrote:Devpac is fine with local labels. You need a dot before the name (e.g. .label) and you need a global label first. Try it!
Tried again, works indeed thanks! I must've messed somehow the first time I tried!
User avatar
YQN
Obsessive compulsive Atari behavior
Obsessive compulsive Atari behavior
Posts: 124
Joined: Sat Jul 22, 2017 6:01 pm
Location: Meaux
Contact:

Re: Help a n00b make a music disk! YAY! :D

Post by YQN »

Just to let you know, I got my text display working fine, now I'm scrolling a line of text at 8 px/vbl, need to slow it down to 1 or 2 px/vbl! Assembly is a lot of fun! If only I had had access to such tutorials when I was a teen! :)
wietze
Captain Atari
Captain Atari
Posts: 312
Joined: Fri Mar 01, 2013 10:52 pm

Re: Help a n00b make a music disk! YAY! :D

Post by wietze »

YQN wrote:Just to let you know, I got my text display working fine, now I'm scrolling a line of text at 8 px/vbl, need to slow it down to 1 or 2 px/vbl! Assembly is a lot of fun! If only I had had access to such tutorials when I was a teen! :)
Thats the spirit. Before you know it, you got yourself a demo!
User avatar
Zorro 2
Administrator
Administrator
Posts: 2220
Joined: Tue May 21, 2002 12:44 pm
Location: Saint Cloud (France)
Contact:

Re: Help a n00b make a music disk! YAY! :D

Post by Zorro 2 »

YQN wrote:If only I had had access to such tutorials when I was a teen! :)
You are always a teenager ;)
Member of NoExtra Team
User avatar
YQN
Obsessive compulsive Atari behavior
Obsessive compulsive Atari behavior
Posts: 124
Joined: Sat Jul 22, 2017 6:01 pm
Location: Meaux
Contact:

Re: Help a n00b make a music disk! YAY! :D

Post by YQN »

wietze wrote:Thats the spirit. Before you know it, you got yourself a demo!
Ha! not quite yet! But I'm working on it :)
Zorro 2 wrote:
YQN wrote:If only I had had access to such tutorials when I was a teen! :)
You are always a teenager ;)
:cheers:
User avatar
YQN
Obsessive compulsive Atari behavior
Obsessive compulsive Atari behavior
Posts: 124
Joined: Sat Jul 22, 2017 6:01 pm
Location: Meaux
Contact:

Re: Help a n00b make a music disk! YAY! :D

Post by YQN »

Hi all,

I'm stuck again! I got to scroll some text @ 1px/vbl, and I wanted to add some music indeed, which is the reason why I'm learning assembly. I searched sources on github and could play SNDH tunes with SID voices and buzzer, but when I try to play a tune that has digidrums (almost all my tunes use them), the ST seems to be stuck in the init routine. I still have the keyclick and no bombs. Nothing happens, the 'demo' doesn't start. My sndh's can be played with gwEm's example code or any sndh player, they are not packed, so they're unlikely to be the problem. I even made a sndh that has one small digidrum, and no song data, to make sure it wasn't a matter of file size (what do I know?) and that file won't play either. The sources I could play my files with have a lot of inits I don't understand:

Code: Select all

	move.l  4(sp),a5                ; address to basepage
        move.l  $0c(a5),d0              ; length of text segment
        add.l   $14(a5),d0              ; length of data segment
	add.l   $1c(a5),d0              ; length of bss segment
        add.l   #$1000,d0               ; length of stackpointer
	add.l   #$100,d0                ; length of basepage
	move.l  a5,d1                   ; address to basepage
	add.l   d0,d1                   ; end of program
	and.l   #-2,d1                  ; make address even
	move.l  d1,sp                   ; new stackspace

	move.l  d0,-(sp)                ; mshrink()
	move.l  a5,-(sp)                ;
	move.w  d0,-(sp)                ;
	move.w  #$4a,-(sp)              ;
	trap    #1                  	;
	lea 	12(sp),sp               ;  
I stumbled across these lines in various sources so I guess they're- wait I gotta try something

-----

I'm back! I copied these lines at the very beginning of my code and it works now (I tried copying them in perihelion's initlib.s, which I'm using, but it gave me bombs). I always have to start writing a long forum post to get an idea I haven't tried :) You have no idea how many posts I wrote and deleted before submitting! Anyway, "my" code works now but I don't know why, would any of you charitable folks take the time to explain what these lines do, and how they influence digidrum initialisation?! Or tell me what I should read to get that knowledge? Thank you very much!
User avatar
Grazey / PHF
Atari Super Hero
Atari Super Hero
Posts: 512
Joined: Fri Jun 21, 2002 12:50 pm
Location: Montreal, Quebec
Contact:

Re: Help a n00b make a music disk! YAY! :D

Post by Grazey / PHF »

Hi ya.

Yes you need these memory set up commands to play most maxymiser tunes as gwEm uses system calls to reserve buffer space for samples.

Grazey
http://phf.atari.org - demo coders since 1983
http://sndh.atari.org - Maintainer of the Atari ST chip music archive
http://www.scenemusic.net - Nectarine Administrator
User avatar
YQN
Obsessive compulsive Atari behavior
Obsessive compulsive Atari behavior
Posts: 124
Joined: Sat Jul 22, 2017 6:01 pm
Location: Meaux
Contact:

Re: Help a n00b make a music disk! YAY! :D

Post by YQN »

Grazey / PHF wrote:Hi ya.

Yes you need these memory set up commands to play most maxymiser tunes as gwEm uses system calls to reserve buffer space for samples.

Grazey
Thx Grazey!
User avatar
YQN
Obsessive compulsive Atari behavior
Obsessive compulsive Atari behavior
Posts: 124
Joined: Sat Jul 22, 2017 6:01 pm
Location: Meaux
Contact:

Re: Help a n00b make a music disk! YAY! :D

Post by YQN »

Ok, so I've already been further than I thought I could, so far I have a program that:
- displays pictures
- plays SNDH's
- changes track according to user input
- polls Zync codes from the SNDH's
- displays YM levels
- scrolls text @ 1pixel/vbl
- prints text to screen

Very basic stuff indeed but being a bad coder and an asm newbie I'm rather happy with my progress so far :)
Some tracks have unreasonable amounts of timer effects (custom waveforms and digidrums at high sampling rate) so I already have to start optimizing and would appreciate some guidance!

1. Printing text to screen seems to cost a lot of CPU, I'm currently copying each character from a PI1 font to both screens, I thought of these ways to reduce CPU work:
- print 1 char per vbl (probably the easy way)
- store the characters individually in memory before I steal the vbl, not sure how to do that, or make a table of the addresses of the characters in the font, to avoid calculating each time.
Am I being stupid or is it the way to go? What's an efficient way to print text on screen?

2. I have a little trouble polling the keyboard. I have 2 loops, one called @ each vbl with everything that's happening, and one where I'm polling the keyboard:

Code: Select all

	move.w	sr,d0				;store sr
	move.w	#$2700,sr			;stop all ints
	move.l 	 $70.w,old_70			; backup $70
	move.l 	 #main_vbl,$70.w		; ----------------- OCCUPY VBL !!!!!!!!!!!!!!!!!!!!!!!!!!!!
	move.w	d0,sr				;restore sr

the_loop
	
	tst.w	menu_active
	beq.s	.no_menu
	; move.w	#7,-(sp)				; wait for keypress
	; trap	#1						; ! this block causes problems when skipping songs automatically
	; addq.l	#2,sp					;
	
	cmp.b	#$4d,$fffffc02.w		; RIGHT ARROW
	bne.s	.not_right
	jsr		erase_cursor
	add.w	#1,tune_number
	jsr		change_tune
	jsr		draw_cursor
.not_right
	
	cmp.b	#$4b,$fffffc02.w		; LEFT
	bne.s	.not_left
	jsr		erase_cursor
	sub.w	#1,tune_number
	jsr		change_tune
	jsr		draw_cursor
.not_left
	
.no_menu
	cmp.b	#$39,$fffffc02.w		;check for space
	bne.s	the_loop
The keyboard worked fine this way when the "wait for keypress" lines were not commented out, but since I added the feature to skip a track once it has looped I had to comment out these lines (and I have no idea how they interfere). Now the automatic skipping of the tracks works well but as a result, when polling the keyboard the tracks skip as long as the key is pressed. Am I doing something wrong or should I just store the previous state of the keys I'm testing? When I was checking the keys in the vbl loop, the mouse would return keyboard events :/ How does an experienced developer do?

Thanks in advance for all input!
User avatar
dma
Atari God
Atari God
Posts: 1087
Joined: Wed Nov 20, 2002 11:22 pm
Location: France
Contact:

Re: Help a n00b make a music disk! YAY! :D

Post by dma »

Great progress, you're even able to synch music with visuals now, congrats. :)
User avatar
thomas3
Captain Atari
Captain Atari
Posts: 160
Joined: Tue Apr 11, 2017 8:57 pm
Location: the people's republic of south yorkshire, uk.

Re: Help a n00b make a music disk! YAY! :D

Post by thomas3 »

YQN wrote: 1. Printing text to screen seems to cost a lot of CPU, I'm currently copying each character from a PI1 font to both screens, I thought of these ways to reduce CPU work:
- print 1 char per vbl (probably the easy way)
- store the characters individually in memory before I steal the vbl, not sure how to do that, or make a table of the addresses of the characters in the font, to avoid calculating each time.
Am I being stupid or is it the way to go? What's an efficient way to print text on screen?
This should be a very low CPU task, so without seeing your code, it's hard to comment, BUT...

1) definitely store the characters individually rather than copying from the pi1. In your init, copy your characters from the pi1 to a new buffer where they are organised serially rather than spread across y lines/bitplanes. That way, you can then write to screen (a0 in the example below) faster (for an 8x8 one colour char, pointed to in your serially organised buffer by a1) just with:

a set 0
rept 8
move.b (a1)+,a(a0)
a set a+160
endr

As each char is 8 bytes, you can therefore easily find the place in the buffer without much fuss - with character # in d0.w, just do lsl.w #3,d0 (to multiply by 8 ) followed by adda.w d0,a1, where a1 is the pointer to the start of your charbuffer.

2) from what you've said you're doing, do you even need to be drawing two screens? as long as you write to a place on the screen BEFORE the electron beam has reached it each frame, you don't need to double buffer. just make sure you draw your graphical elements in order from top of the screen to bottom of the screen in your main loop. this way, you then only need to write chars once each vbl.
User avatar
YQN
Obsessive compulsive Atari behavior
Obsessive compulsive Atari behavior
Posts: 124
Joined: Sat Jul 22, 2017 6:01 pm
Location: Meaux
Contact:

Re: Help a n00b make a music disk! YAY! :D

Post by YQN »

thomas3 wrote: This should be a very low CPU task, so without seeing your code, it's hard to comment, BUT...

1) definitely store the characters individually rather than copying from the pi1. In your init, copy your characters from the pi1 to a new buffer where they are organised serially rather than spread across y lines/bitplanes. That way, you can then write to screen (a0 in the example below) faster (for an 8x8 one colour char, pointed to in your serially organised buffer by a1) just with:

a set 0
rept 8
move.b (a1)+,a(a0)
a set a+160
endr

As each char is 8 bytes, you can therefore easily find the place in the buffer without much fuss - with character # in d0.w, just do lsl.w #3,d0 (to multiply by 8 ) followed by adda.w d0,a1, where a1 is the pointer to the start of your charbuffer.
Thanks Tom! I need to learn about that syntax with that kind of "local variable" a, I haven't seen any tut' on this, what is it called? I watched your interpreter demo recently, when I'm done with this music disk I'll make chiptunes with fewer timer effects and then try to walk a step further into the demo realm :) Anyway it's good to know I was on the right track. I could even store the font into another file and avoid including the pi1 at all since I don't need 4 planes, would have to learn how to make such a file!
thomas3 wrote:2) from what you've said you're doing, do you even need to be drawing two screens? as long as you write to a place on the screen BEFORE the electron beam has reached it each frame, you don't need to double buffer. just make sure you draw your graphical elements in order from top of the screen to bottom of the screen in your main loop. this way, you then only need to write chars once each vbl.
Well I'm using two screens because of the scroller, I figured it was necessary since it's in perihelion's scroller tutorial... But i haven't tried a scroller without a screen buffer. If I manage to save enough vbl time I'd like to make some effects in sync with the music, so I guess I'll keep it for now anyway, I'd like my disk to be somewhat cooler than just a menu and a scroller :) But it's good to know I should be able to do without it, my scroller being at the bottom of the screen! Thanks again! :)
wietze
Captain Atari
Captain Atari
Posts: 312
Joined: Fri Mar 01, 2013 10:52 pm

Re: Help a n00b make a music disk! YAY! :D

Post by wietze »

YQN wrote: Thanks Tom! I need to learn about that syntax with that kind of "local variable" a, I haven't seen any tut' on this, what is it called? I watched your interpreter demo recently, when I'm done with this music disk I'll make chiptunes with fewer timer effects and then try to walk a step further into the demo realm :) Anyway it's good to know I was on the right track. I could even store the font into another file and avoid including the pi1 at all since I don't need 4 planes, would have to learn how to make such a file!
Hear, hear! Its good to see you're getting into the demo coding!

There are a few ways to generate files, you can use GEMDOS calls like FCreate, followed by FWrite (http://frummel.org/~weedz/atari/docs/Th ... endium.pdf), after you generated the data in a buffer as you'd like to have it.
Depending on the development tools, you could possibly also directly dump the memory contents to a file.
User avatar
thomas3
Captain Atari
Captain Atari
Posts: 160
Joined: Tue Apr 11, 2017 8:57 pm
Location: the people's republic of south yorkshire, uk.

Re: Help a n00b make a music disk! YAY! :D

Post by thomas3 »

Hey YQN!

The rept/endr/set thing.... These are what are called macros. They are just directives for the assembler, rather than actual code that gets assembled. Rept and endr simply repeats the text in between them before assembly, and the a variable similarly is replaced by its value before the code is assembled.

In other words, these directives just save time for you because they mean you don't have type everything out. The above code is identical to...

Move.b (a1)+, 0(a0)
Move.b (a1)+, 160(a0)
Move.b (a1)+, 320(a0)
etc.

Try it out - assemble it and look in a debugger and you'll see what I mean.

I'm still super proud of the Interpreter Demos! But like you, I'm now working in assembly now. It's not as hard as you'd think once you get into it, is it? ;)

Looking forward to hearing your awesome tunes in a release! :D
Post Reply

Return to “680x0”