Mod Archive Forums Mod Archive Forums
Advanced search  

News:

Please note: Your main modarchive.org account will not work here, you must create a forum account to post on the forums.

Pages: [1]   Go Down

Author Topic: why is there a pitch difference on amiga and dos?  (Read 5124 times)

0 Members and 2 Guests are viewing this topic.

red M95

  • New User
  • Offline Offline
  • Posts: 10
    • View Profile
why is there a pitch difference on amiga and dos?
« on: December 14, 2022, 23:21:15 »

title says pretty much everything, i'm wondering why when i play a .mod on dos it has a slightly higher pitch than the same thing on an amiga. actually, if i play any module, no matter the format, on dos, the pitch is higher than on the amiga. does dos have a much different way of handling sound, so everything sounds higher-pitched when played on it? also, if you're reading this and also listened to apple iigs music, you may also have noticed the huge pitch difference from the iigs to anything else. with the iigs, the pitch difference is much worse, it's pretty much a semitone, or, if you use protracker, it's approximately a +5 finetune. no idea why.
also, i almost forgot: hi everyone, i'm red M95, a very beginner composer who uses protracker, sometimes famitracker too.
Logged

m0d

  • Creator of Meow Meow Meow Kitty Song
  • Global Moderator
  • Top Poster
  • ****
  • Offline Offline
  • Posts: 1867
  • Original Site Admin/Designer/Coder
    • View Profile
    • Science & Art - Eindhoven.space - RedHeat Music & More
Re: why is there a pitch difference on amiga and dos?
« Reply #1 on: January 05, 2023, 00:53:57 »

Different timer chips. Amiga MOD uses CIA I/O chip for reference.

DOS players have to emulate that based on code trying to divide time over a period linked to the VSYNC (I think, its something like that, im not 100%)
Logged
👨‍💻 Creator, Musician & HF Packet Radio Network Core
🎧 Discover great music via other member's special picks in the MFG
☕️ Get m0d a coffee via Ko-Fi.com
💬 IRC irc.rizon.net #modarchive
💬 Modarchive Discord

red M95

  • New User
  • Offline Offline
  • Posts: 10
    • View Profile
Re: why is there a pitch difference on amiga and dos?
« Reply #2 on: January 05, 2023, 12:48:30 »

> Amiga MOD uses CIA I/O chip for reference.
bro, i didn't know amigas were made by the us government '-'
jokes aside, that makes much more sense now. from what i understood, the samples were loaded faster in dos by default, so they had higher pitch. i think i've heard of the same problem in the apple iigs. the iigs uses an ensoniq es5503 doc as the sound chip, but it's not sample-based, instead, it's wavetable. so i think the "hack" they used had a disadvantage of playing samples in a faster speed, making them higher pitch. and according to wikipedia, the timer for the iigs sound is in the sound chip itself, but it uses a whole channel for that timing if the program that's running relies on the system firmware or stock tools. if it doesn't, then it's fully possible to use all 32 channels, though i've never seen any iigs music use all these channels, nor have i seen a demo or tracker that can break this limitation. so i'm guessing the default timing on the iigs sound chip was much different, but programmers didn't bother with fixing that to make music sound the same as in the amiga.
> DOS players have to emulate that based on code trying to divide time over a period linked to the VSYNC (I think, its something like that, im not 100%)
i think openmpt does the same thing. amiga music also sounds higher-pitched there. maybe they didn't separate the code that much for amiga and dos, see, if you play an amiga module in protracker 2 clone for windows/ linux/ whatever, it will sound the exact same thing as in a real amiga. the code in there has a much better emulation i assume. though, there are some flaws that can be fixed.
Logged

red M95

  • New User
  • Offline Offline
  • Posts: 10
    • View Profile
Re: why is there a pitch difference on amiga and dos?
« Reply #3 on: February 08, 2023, 00:07:59 »

> DOS players have to emulate that based on code trying to divide time over a period linked to the VSYNC (I think, its something like that, im not 100%)
i'm trying to develop my own tracker right now based on the fasttracker ii (clone) source code, and now i discovered. the actual reason is the middle-c frequency. on fasttracker, the middle-c frequency is set to 8363 hz for both amiga and linear frequency tables, and now i'm trying to fix that by setting the middle-c frequency to 8287 hz for the amiga frequency table only. however, many .mod's were made in fasttracker ii, so they'd sound different than supposed since the header isn't very different and there's no 100% accurate way to detect whether the .mod is from dos or a real amiga.
the apple iigs might have the exact same issue, so i'm guessing the middle-c frequency there was even higher than the one in fasttracker ii.
Logged
Pages: [1]   Go Up