Log inRegister an accountBrowse CSDbHelp & documentationFacts & StatisticsThe forumsAvailable RSS-feeds on CSDbSupport CSDb Commodore 64 Scene Database
You are not logged in - nap
CSDb User Forums


Forums > C64 Coding > BASIC Demo - using sid ??!
2007-02-27 17:06
zenda

Registered: Nov 2006
Posts: 22
BASIC Demo - using sid ??!

Hi.

I would like to use this tune in a Basic-demo, but don't know if it is/how it is possible ?? http://www.c64.org/HVSC/MUSICIANS/H/Haard_Lars/Captured.sid

and how do I "capture" it into the basiccode ??

/zenda

17 years ago I could make an asm-demo - now I can do a
10 ? "yes sir I can boogie"
20 goto 10
;-)
2007-02-27 17:33
null
Account closed

Registered: Jun 2006
Posts: 645
afaik, you'll either have to link the tune+player to BASIC with some ASM, or ask someone to do it for you (like I did...)

------------------------------------
Knoeki/DigitalSoundsSystem/SwappersWithAttitude
2007-02-27 18:46
Mace

Registered: May 2002
Posts: 1799
Linking this tune to your BASIC program isn't very hard:

1) load the tune in memory
2) type NEW
3) program your basic file
4) poke 45,186:poke46,128 (for this particular tune)
5) SAVE"basic + music",8

But this still leaves you without a player.

AND DON'T TYPE ANOTHER BASIC LINE AFTER YOU DID THE POKES!
Or the memory is screwed.
2007-02-27 19:41
SIDWAVE
Account closed

Registered: Apr 2002
Posts: 2238
You will have to install a interrupt music player in memory somewhere, and SYS it from the basic program.

Do you know how to make assembler in a monitor ?

Or else I can do it for you, just send me the basic program on a D64.

jan.harries@get2net.dk
2007-03-01 20:03
zenda

Registered: Nov 2006
Posts: 22
Hi

thanx for the replies...

Rambones - I'll send you a d64...

/Zenda
2007-03-01 20:50
Graham
Account closed

Registered: Dec 2002
Posts: 990
@rambones: Avoid $8000-$9FFF for player, because many cartridges with BASIC extensions will crash if you combine BASIC + music then.
2007-03-01 21:22
null
Account closed

Registered: Jun 2006
Posts: 645
/me knows that all to well... but you can also just kill the cartridge after loading... works good enough

anyways, I'm curious about when it's done... =)
------------------------------------
Knoeki/DigitalSoundsSystem/SwappersWithAttitude
2007-03-02 08:43
SIDWAVE
Account closed

Registered: Apr 2002
Posts: 2238
Hehe, graham, the music IS at 7800-8300..

Now i need to ask a question, he wants a STOP function built in. So how do i properly STOP the IRQ ?

first i did:

sei
lda $0315
sta $c000
lda $0314
sta $c001
lda #>irq
sta $0315
;setup irq and play music
...


then..:

stop:
sei
lda $c000
sta $0315
lda $c001
sta $0314
lda #0
sta $d418
cli
rts


but this dont work, as the basic then halts..

How to to it clean and proper ?
2007-03-02 08:59
Mace

Registered: May 2002
Posts: 1799
Usually, the IRQ is just $EA31, so why not just reset those values in $0314/$0315?

Also, you only set $0315 in the example above.
2007-03-02 09:01
SIDWAVE
Account closed

Registered: Apr 2002
Posts: 2238
Got it working now.
I had installed a raster irq, and that wouldnt stop properly, now i just used plain CIA (which the music is anyway).

all ok :)
2007-03-02 09:03
JackAsser

Registered: Jun 2002
Posts:
Just redirect $0314/15 to their default values (i.e. $ea31), also stop the raster IRQs from being generated ($d01a=0). Your stop routine garbages the A-register, I dunno if that's the cause to your problems.

try:

stop:
sei
pha
lda #<$ea31
sta $0314
lda #>$ea31
sta $0315
lda #$00
sta $d418
sta $d01a
pla
cli
rts
 
... 3 posts hidden. Click here to view all posts....
 
Previous - 1 | 2 - Next
RefreshSubscribe to this thread:

You need to be logged in to post in the forum.

Search the forum:
Search   for   in  
All times are CET.
Search CSDb
Advanced
Users Online
psych
Thierry
Raf/Vulture Design
Guests online: 109
Top Demos
1 Next Level  (9.7)
2 13:37  (9.7)
3 Mojo  (9.7)
4 Coma Light 13  (9.6)
5 Edge of Disgrace  (9.6)
6 What Is The Matrix 2  (9.6)
7 The Demo Coder  (9.6)
8 Uncensored  (9.6)
9 Comaland 100%  (9.6)
10 Wonderland XIV  (9.6)
Top onefile Demos
1 No Listen  (9.6)
2 Layers  (9.6)
3 Cubic Dream  (9.6)
4 Party Elk 2  (9.6)
5 Copper Booze  (9.6)
6 X-Mas Demo 2024  (9.5)
7 Dawnfall V1.1  (9.5)
8 Rainbow Connection  (9.5)
9 Onscreen 5k  (9.5)
10 Morph  (9.5)
Top Groups
1 Performers  (9.3)
2 Booze Design  (9.3)
3 Oxyron  (9.3)
4 Censor Design  (9.3)
5 Triad  (9.3)
Top Organizers
1 Burglar  (9.9)
2 Sixx  (9.8)
3 hedning  (9.7)
4 Irata  (9.7)
5 Tim  (9.7)

Home - Disclaimer
Copyright © No Name 2001-2024
Page generated in: 0.042 sec.