Jump to content
IGNORED

Can I store audio in another bank?


pacgreg

Recommended Posts

Trying to do audio for the first time, I guess my real question would be can you gosub jump to another bank and still use sread normally? Can you use two sdata groupings at the same time for different sounds and music playing at the same time? Attached is the code I was trying to play with to use music and bankswitching.

Thanks

default.bas

Edited by pacgreg
Link to comment
Share on other sites

I usually have the least amount of weirdness if I put the VisualbB generated sound engine and music data in the last bank. Same thing goes for the titlescreen kernel data and titlescreen loop.

 

Technically you can call the routines from anywhere but, yeah. Personal preference and experience.

 

 

UPDATE: Sorry, it's a little more than personal preference. It seems keeping the data and the routines that use it close is a real good idea. I experience the same phenomenon in sega genesis programming. Dunno the exact reason in assembly it works that way.

Link to comment
Share on other sites

I usually have the least amount of weirdness if I put the VisualbB generated sound engine and music data in the last bank. Same thing goes for the titlescreen kernel data and titlescreen loop.

 

Technically you can call the routines from anywhere but, yeah. Personal preference and experience.

 

 

UPDATE: Sorry, it's a little more than personal preference. It seems keeping the data and the routines that use it close is a real good idea. I experience the same phenomenon in sega genesis programming. Dunno the exact reason in assembly it works that way.

 

Since a bunch of things already go in the last bank, it might be better to stick sound in a different one (if you are using more than two banks).

 

 

 

Trying to do audio for the first time, I guess my real question would be can you gosub jump to another bank and still use sread normally? Can you use two sdata groupings at the same time for different sounds and music playing at the same time? Attached is the code I was trying to play with to use music and bankswitching.

Thanks

 

This example program uses sdata:

 

randomterrain.com/atari-2600-memories-batari-basic-commands.html#ex_sound_with_bg_music

 

Looks like I forgot to mention on the bB page that it uses sdata. I'll fix that now and I'll also add a link to the example from the sdata section.

  • Like 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...