Import music from FamiStudio to ASM Project

Are you new to 6502, NES, or even programming in general? Post any of your questions here. Remember - the only dumb question is the question that remains unasked.

Moderator: Moderators

Post Reply
TheMangoEffect
Posts: 3
Joined: Fri Mar 12, 2021 4:39 pm

Import music from FamiStudio to ASM Project

Post by TheMangoEffect » Fri Mar 12, 2021 4:48 pm

I'm very new to 6502 assembly, I'm using ca65 on a Mac.
I made a track in FamiStudio, and exported it to FamiStudio music code ca65, but I'm not entirely sure what memory address to reference the .s file to in my main assembly file.
I know this is kind of a stupid question that's probably been asked already, I just haven't found anything on it. Do I have to import a library or something for the FamiStudio file to run?

tepples
Posts: 22327
Joined: Sun Sep 19, 2004 11:12 pm
Location: NE Indiana, USA (NTSC)
Contact:

Re: Import music from FamiStudio to ASM Project

Post by tepples » Fri Mar 12, 2021 5:58 pm

Does the .s file .export any symbols (such as labels or constants)? If so, you'll probably need to add the .s file to your makefile (or other build script) and .import those symbols from your other .s files.

TheMangoEffect
Posts: 3
Joined: Fri Mar 12, 2021 4:39 pm

Re: Import music from FamiStudio to ASM Project

Post by TheMangoEffect » Fri Mar 12, 2021 6:20 pm

tepples wrote:
Fri Mar 12, 2021 5:58 pm
Does the .s file .export any symbols (such as labels or constants)? If so, you'll probably need to add the .s file to your makefile (or other build script) and .import those symbols from your other .s files.
It has a .export for the music data, and a .global for FAMISTUDIO_DPCM_PTR. I tried importing the music data into my main .asm file and it didnt work, not sure how to get this working. I checked the nesdev wiki and i still don't get it :/

tepples
Posts: 22327
Joined: Sun Sep 19, 2004 11:12 pm
Location: NE Indiana, USA (NTSC)
Contact:

Re: Import music from FamiStudio to ASM Project

Post by tepples » Fri Mar 12, 2021 9:13 pm

What do you mean by "doesn't work"? Do you get an error message, or just no sound? If no sound, then you might not be calling the audio driver's init, start song, or update routine.

Someone might be able to give you more than conjectures if you post code.

TheMangoEffect
Posts: 3
Joined: Fri Mar 12, 2021 4:39 pm

Re: Import music from FamiStudio to ASM Project

Post by TheMangoEffect » Fri Mar 12, 2021 10:04 pm

tepples wrote:
Fri Mar 12, 2021 9:13 pm
What do you mean by "doesn't work"? Do you get an error message, or just no sound? If no sound, then you might not be calling the audio driver's init, start song, or update routine.

Someone might be able to give you more than conjectures if you post code.
No sound, like I said I have no clue what number to call. I tried calling the ones $4011-$4015 or something with the information and it didn't play anything. Ik its a stupid question just asking how to code it in I just haven't been able to find anything anywhere for ca65

Post Reply