Found another DEMO that seems to work with TOD bug disabled (and that works fine on SAE):
"5 to 12 (1993) (Syndacate)" (required 1 Mb of chip ram)
But I'm not sure because every time I reset the vAmiga with the button, the audio works randomly. Perhaps it's not related to the TOD bug?...🤔
Furthermore ... after about 3 minutes there's an effect called "Dot World":


.. the audio slows down a few times (but not in SAE).
_Originally posted by @Gianmarco72 in https://github.com/dirkwhoffmann/vAmiga/issues/364#issuecomment-641313781_
Again a great catch! The sound issue at the beginning seems to be related to asynchronous FIFO buffer emulation (disk controller). If this option is disabled, the sound problems vanish (at least in the version with the TOD issue fixed).

There seems to be an issue with warp mode, too. I did run into the situation where the emulator was running in warp mode and sound was still playing. If this happens, sound is always scrambled.
Asynchronous FIFO emulation seems to be all right. The demo uses a custom disk loader which is ultra sensitive to physical drive parameters such as the track switching delay.
Up to now, vAmiga moved the head in no time. If the head was at position n and the head stepped inwards or outwards, the head was at position n on the next track, too. To emulate a delay, I added the following to the stepping code:
// Push drive head forward
head.offset = (head.offset + skip) % Disk::trackSize;
So the question is how big „skip“ has to be. We know that it doesn’t work with 0.
So let’s do some calculations. The drive rotates at 300 rpm which is 5 rotations per second. There are 12688 bytes on each track. The HRM says:
„The drives used for the Amiga are guaranteed to get to the next track within 3 milliseconds. Some drives will support a much faster rate, others will fail.„
In 3 milliseconds, 3 * 5 * 12688 / 1000 = 190 bytes are skipped, but with this value, it doesn’t work either. Because „some drives support a much faster rate“, let’s try something in between: 100. And with this value, sound works fine 😎. This doesn’t prove anything, of course. With this delay, it may just work due to some other, yet unknown reason.
Great stuff 🤤👍🏿
@Gianmarco72 I think the issue is fixed in v0.9.8.1. Could you double check?
Please make sure that "Emulate asynchronous FIFO" is enabled.
Tried: now the demo starts well every time! 👍🏻😎
But there's still the problem with the music that slowing down during the "Dot World" effect. 🙄
I'll try to explain the issue better.😰
After about 3 minutes of playing demo, this screen appears which introduces the "Dot World" effect:

... and Paula still plays ok. Next, starts the effect:

.. during it we notice a slight slowdown of the music especially when the dots rotate.🤔
In SAE and UAE it doesn't happen.🤔
And there is still the reset issue. Music is broken when the game is loaded a second time (after reset). It requires the hand & disk logo to be shows to work.
😓
And there is still the reset issue. Music is broken when the game is loaded a second time (after reset). It requires the hand & disk logo to be shows to work.
It doesn't happen to me: I tried to reset 5 times just now (so the demo loaded for 5 times) and the music plays well every time.😳 (except for the slowdown described, of course)
.. during it we notice a slight slowdown of the music especially when the dots rotate.
Issue is still there in v0.9.8.4. Hard to say what the root cause is...
What is this demo? I couldn't find the name anywhere...
What is this demo? I couldn't find the name anywhere...
The name is "5 to 12"
https://demozoo.org/productions/5788/
What is this demo? I couldn't find the name anywhere...
Here you are 😉
5 to 12 (1993)(Syndicate).zip
I checked this:
"a slight slowdown of the music especially when the dots rotate."
I still see this issue in v0.9.10.1.
I hope that helps
Interesting @Gianmarco72 @dirkwhoffmann . I've tried this on FS-UAE set as A500 and the same slowness happens at the same point.
Then I read the intro screen again (you have it above) and the developer says he developed in a 68030 and had no time to test in a 68000! I then set up FS-UAE to use a 680ec30 instead and the music played just fine.
I don't think the slowness is a bug at all, but the demo is probably the culprit here. Does that make sense?
Then I read the intro screen
Wow, somebody read the docs 😂.
I'll try the demo on my A500...
I don't think the slowness is a bug at all, but the demo is probably the culprit here.
Confirmed. The demo has the same hiccups on the real machine (test machine was an A500 8A with an ACA500plus to emulate the required 1MB Chip Ram).
Another issue solved without doing anything. I like that 😎.
😃Yeah!
@pedgarcia 👍🏻 Great!