A.D.A. Amiga Demoscene Archive

        Welcome guest!

  

  

  

log in with SceneID

  

Demos Amiga Demoscene Archive Forum / Coding / Easy way to playback modules?

 

Author Message
Oerg866
Member
#1 - Posted: 15 Sep 2009 22:38
Reply Quote
Hello. I am a bit familiar with 68k from Sega-console-side, so, as kind of an amiga fan, I got myself an A4000/030 and ASMOne and I can't get MOD playback to work in it at all. I've tried many many playback routines, only one kinda outputs something that sounds like my modules (but it doesn't stop the samples when they're, you know, done and keeps reading on until a new note plays), but I forgot which one it was. Some don't work at all, some show some black BG and a few colored lines on screen, but yeah, none work. I tried StarTrekker, ProTracker, NoiseTracker, SoundTacker and IceTracker routines but I can't get this to work at all. Note that I am a complete amiga code beginner. I also tried ThePlayer 6.1A - didn't play anything (It did quit when it was supposed to though: after clicking both mouse buttons).

All routines expect you to KNOW how to call VBlanks or Interrupts or whatever they want, but as a complete beginner I don't know all this stuff yet, and I can't find a beginners routine that just works. What I mean is, tack an incbin at the end, assemble it, run it.

Can someone please help me in any way?

Regards,
Oerg866
dodke
Member
#2 - Posted: 16 Sep 2009 00:21 - Edited
Reply Quote
who knows if i fucked something up here. well, at least i didn't figure out how to show tabs in the forum so you'll have to fix that. You can also add a timer very easily in the VBI so you should have this anyway even if your mod player didn't need it.


vbiroutine:
movem.l d0-a6,-(sp)

; ***** insert code that you want to run in every vertical blank HERE ***

movem.l (sp)+,d0-a6
rts



SetVBI:
lea vbiroutine, a0
moveq #5,d0
lea intstruct,a1
move.l 4,a6
jsr -$00a8(a6)
rts

RemVBI:
moveq #5,d0
lea intstruct,a1
move.l 4,a6
jsr -$00ae(a6)
rts

intstruct: dc.l 0,0
dc.b 2,0
dc.l inttiname
dc.l 0
intadr: dc.l 0
inttiname: dc.b 'ninja',0
even
yoki
Member
#3 - Posted: 16 Sep 2009 02:51 - Edited
Reply Quote
using theplayer6.1 would be the easiest way though, just use the interrupt-version (it's a define somewhere in the start of the code) and jsr to the start-address in the player.. you don't have to call the interrupts by yourself or something like that :)

if you are using a vbl-player, be sure to save down the module as VBLANK in protracker or it will play at wrong speed..

(when using theplayer6.1, don't forget to convert your mod to p61-format before you use it, with the converter in the archive, otherwise things will not work)
kasie
Member
#4 - Posted: 16 Sep 2009 10:06
Reply Quote
@Oerg866
Yoki are right. ThePlayer6.1 are very easy to use. Many demos used Player6.1 back in the past. Can be found on aminet, and there is latest bugfix for.
Oerg866
Member
#5 - Posted: 16 Sep 2009 16:40 - Edited
Reply Quote
Thank you very much for your kind answers so far! It might be my Amiga's fault but ASM-One v1.4x doesn't work (Error #8000004 upon startup)

EDIT: Oh hey, it works. I recorded it for everyone to see: http://www.youtube.com/watch?v=i6Q4qHw9xCY
xeron
Member
#6 - Posted: 16 Sep 2009 20:13
Reply Quote
Congrats!

BTW, you don't need to write the executable to disk to test it, just "a" followed by "j" will run the code.
z5_
Member
#7 - Posted: 16 Sep 2009 22:31
Reply Quote
I unlocked the topic again.

The first succesful program compile is always a big moment :)

So... when can we watch your first demo? :)
Oerg866
Member
#8 - Posted: 17 Sep 2009 09:17 - Edited
Reply Quote
Hehehe, thank you for unlocking it :)

Well, basically, I'm going to read this big guide on programming the Amiga that xeron gave me a link to, as soon as I have much time on my hands. Which, probably, will be when the autumn holidays start.

Maybe I have something ready in time for Breakpoint 2010 *dreams*... Probably not enough time to learn until then though I guess :P - I spent almost 3 years learning stuff about the Mega Drive and still don't have a hang of it :P
yoki
Member
#9 - Posted: 17 Sep 2009 12:00
Reply Quote
which guide are you referring to? the hwref? :)
Oerg866
Member
#10 - Posted: 18 Sep 2009 11:05
Reply Quote
I don't have the link here but let me see if I find it on google...

Ah, here it is: http://www.mways.co.uk/amiga/howtocode/

 

  Please log in to comment

  

  

  

 

A.D.A. Amiga Demoscene Archive, Version 3.0