TonyA Posted March 1, 2008 Share Posted March 1, 2008 (edited) Hi, I was wondering if anyone might be able to show me some simple examples of using the sound registers. Would like to produce sound with the joystick, and increase and decrease the volume. Tried some stuff like this: rem ----test code 1---- AUDV0=0 main AUDC0=3 AUDF0=3 if joy0up then AUDV0=AUDV0+1 if joy0down then AUDV0=AUDV0-1 goto main How can I successively increment the volume higher with joy up, and successively decrease the volume with joy down? Thanks for any help. T Edited March 1, 2008 by TonyA Quote Link to comment Share on other sites More sharing options...
Gorf Posted March 1, 2008 Share Posted March 1, 2008 See if this can help..... http://www.atariage.com/forums/index.php?showtopic=77106 Quote Link to comment Share on other sites More sharing options...
TonyA Posted March 1, 2008 Author Share Posted March 1, 2008 See if this can help.....http://www.atariage.com/forums/index.php?showtopic=77106 Thank you. It will be helpful. T Quote Link to comment Share on other sites More sharing options...
+Random Terrain Posted March 1, 2008 Share Posted March 1, 2008 See if this can help.....http://www.atariage.com/forums/index.php?showtopic=77106 Thank you. It will be helpful. T I'm working on a new version of Tone Toy which I hope will have more options. I'm still trying to figure out the bast way to go about it, but I hope to have a rough version done before April of 2008. Quote Link to comment Share on other sites More sharing options...
TonyA Posted March 1, 2008 Author Share Posted March 1, 2008 See if this can help.....http://www.atariage.com/forums/index.php?showtopic=77106 Thank you. It will be helpful. T I'm working on a new version of Tone Toy which I hope will have more options. I'm still trying to figure out the bast way to go about it, but I hope to have a rough version done before April of 2008. Thanks. Looking forward to seeing it. Good luck. Tony Quote Link to comment Share on other sites More sharing options...
Fort Apocalypse Posted March 1, 2008 Share Posted March 1, 2008 (edited) Tony, The trick is that you have to drawscreen before it will play. Note that there are two channels for sound, but you can switch back and forth for the tone/etc. of channel 0 and 1 to simulate more channels by setting the tone/etc. of both channels via AUDC0, AUDF0, AUDV0, AUDC1, AUDF1, AUDV1, then doing drawscreen, and then setting AUDC0, AUDF0, AUDV0, AUDC1, AUDF1, AUDV1 to something else and then again setting AUDC0, AUDF0, AUDV0, AUDC1, AUDF1, AUDV1 and doing drawscreen. This is similar to doing the same switching back and forth with sprites for each drawscreen - there is probably some limit to the number of simulated channels you could emulate via switching without it sounding too muddy, but I don't know what that limit is. My guess is that you could only simulate 4 without it sounding muddy. See more on sound at the page batari wrote that Random Terrain maintains here: http://www.randomterrain.com/atari-2600-me...c-commands.html Hope this helps, Gary Edited March 1, 2008 by Fort Apocalypse Quote Link to comment Share on other sites More sharing options...
TonyA Posted March 2, 2008 Author Share Posted March 2, 2008 Tony, The trick is that you have to drawscreen before it will play. Note that there are two channels for sound, but you can switch back and forth for the tone/etc. of channel 0 and 1 to simulate more channels by setting the tone/etc. of both channels via AUDC0, AUDF0, AUDV0, AUDC1, AUDF1, AUDV1, then doing drawscreen, and then setting AUDC0, AUDF0, AUDV0, AUDC1, AUDF1, AUDV1 to something else and then again setting AUDC0, AUDF0, AUDV0, AUDC1, AUDF1, AUDV1 and doing drawscreen. This is similar to doing the same switching back and forth with sprites for each drawscreen - there is probably some limit to the number of simulated channels you could emulate via switching without it sounding too muddy, but I don't know what that limit is. My guess is that you could only simulate 4 without it sounding muddy. See more on sound at the page batari wrote that Random Terrain maintains here: http://www.randomterrain.com/atari-2600-me...c-commands.html Hope this helps, Gary Hi Gary, thanks. Well I've been experimenting a little with producing sound with the joystick. I did't use drawscreen at all and the compiled bin works fine. I'm probably missing something in your explanation. I'm not using any video right now, just messing around with simple sounds and the joystick. Thanks for the link and help. TOny Quote Link to comment Share on other sites More sharing options...
Fort Apocalypse Posted March 3, 2008 Share Posted March 3, 2008 I did't use drawscreen at all and the compiled bin works fine. Hmm. I must have misremembered that. Sorry! Quote Link to comment Share on other sites More sharing options...
SeaGtGruff Posted March 3, 2008 Share Posted March 3, 2008 I did't use drawscreen at all and the compiled bin works fine. Hmm. I must have misremembered that. Sorry! The TIA (and hence bB) will play sounds without having to draw the screen, but the video will be a rolling screen-- although it will probably be a *black* or blank rolling screen, so I guess you might not be able to tell that it's a rolling screen. There are two things that calling drawscreen will do as far as playing sounds-- it will prevent the screen from rolling (which won't *affect* the sound), and it will delay changes to the sound registers so they occur at regular intervals of about 1/60th of a second (NTSC) or 1/50th of a second (PAL/SECAM). So if you're just playing single tones, or controlling the tones with an input device (e.g., a joystick), you probably won't be able to tell any difference between calling drawscreen or not calling drawscreen. But if you're trying to play a tune using data tables, the song is going to play *really* *really* *fast* if you aren't calling drawscreen at all. Michael Quote Link to comment Share on other sites More sharing options...
Recommended Posts
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.