Important Notice: Our web hosting provider recently started charging us for additional visits, which was unexpected. In response, we're seeking donations. Depending on the situation, we may explore different monetization options for our Community and Expert Contributors. It's crucial to provide more returns for their expertise and offer more Expert Validated Answers or AI Validated Answers. Learn more about our hosting issue here.

I want to dinamically modify the sound generator registers to create music or a sound effect. Should I do that in the vbi() method?

0
Posted

I want to dinamically modify the sound generator registers to create music or a sound effect. Should I do that in the vbi() method?

0

No. The IAVC simulation does its best to redraw the screen 25 times per second and it manages to do it well enough for a video game animation, but it is not accurate enough for audio. The sound generator hardware (simulation) synthetizes audio in Sound Frames, at a rate of 25 sound frames per second. After each sound frame it generates a Sound Frame Interrupt (SFI). You can have your code executed at that time by placing it in a method named sfi().

Related Questions

What is your question?

*Sadly, we had to bring back ads too. Hopefully more targeted.