Jump to content
Stephen

Could PoKey do this

Recommended Posts

Study the provided source code, and you will see why it is 48k. This is not matter of opinion like your posts usually are. It's there in black and white.

Opinion?

 

They asked a small boy how fast the car was driven. He said "we drove 200km/h through the City"

Everyone was shocked by the news, because in Germany only 50km/h is the max. allowed speed in Cities.

Later he said "we have been 4 people in the car. Everyone was driving at 50km/h" ".

"You know 4 * 50 = 200" ....

Edited by emkay
  • Like 1

Share this post


Link to post
Share on other sites

Sorry man - I just listened to it. The high frequency carrier wave made my ears bleed 2 seconds into it. Nowhere close. Apologies to anyone that cannot hear that high squeal, but it is painful as all hell to those of us who can.

The sampling is rather low. But the quality is very good for that low frequency. It also runs on interrupts. Which means it has nothing to do with that "SID sound Rastaconverter" style they used .

Or should we name it "sound interlace" ? The good point there is that the sampling noise really gets away, because any electronic audio-circuit will cut it off.

Share this post


Link to post
Share on other sites

Sorry man - I just listened to it. The high frequency carrier wave made my ears bleed 2 seconds into it. Nowhere close. Apologies to anyone that cannot hear that high squeal, but it is painful as all hell to those of us who can.

 

Do emulators reproduce that? And is this on the Atari or C64 demo? I hear plenty of artifacts and imperfections from both, so not entirely sure.

 

This is also the first I heard of "hi-def" audio on these 8-bit machines - pretty impressive.

Share this post


Link to post
Share on other sites

 

Do emulators reproduce that? And is this on the Atari or C64 demo? I hear plenty of artifacts and imperfections from both, so not entirely sure.

 

This is also the first I heard of "hi-def" audio on these 8-bit machines - pretty impressive.

Definitely reproduced on emulators, as I gave a quick listen through Altirra. I guess I should mention that I am listening to this through a Sansui 7070 receiver powering somewhat large studio monitors and not just a TV / PVM internal speaker.

 

I'm also not putting down the great work that was done with the PWM technique. I can certainly hear issues with this new C64 technique, but the constant carrier frequency whine is not there.

  • Like 1

Share this post


Link to post
Share on other sites

Emulation will have it's inaccuracies - generally the actual sample playback for sound will be limited by the PC sound hardware, so might be 44.1, 48, 96 or 192 thousand samples per second.

So in effect you do get a sort of low-pass filtering where noise above that frequency contributes much less to the overall sound generation.

In theory a cycle-exact sound emulation could do averaging down to the resultant playback frequency, no idea if any do. It'd likely add a fair bit of overhead.

  • Like 1

Share this post


Link to post
Share on other sites

 

There's a thread here, but I couldn't find it on the first couple looks.

I know he was demonstrating a comparison between PWM and PCM.

I have the PCM file of exactly the same song, and the quality is lower.

 

I did find this thread about PCM audio experiments. Maybe the file is

in the thread and I just didn't see it (didn't spend much time looking).

 

PCM Audio Experiments

 

I made the Desireless - Voyage Voyage examples using phaeron's techniques as reverse engineered from his 60FPS demos. Original thread here. Some more examples using Bon Jovi here. Both rely on instantaneous XEX segment loads as found in emulators. They have gaps for loading on real hardware. I didn't know about the PCM Audio Experiments thread. Thanks for the pointer!

 

Unfortunately the PWM technique loses precision the higher the frequency. At 15Khz it has around 6.5 bits. So at 45Khz it would only have around 2 bits of precision assuming you could properly time everything. At that point it would be better to go back to volume-only mode which has 4 bits of precision.

 

Unrolled LDA/STAs could do about 13 AUDC updates per scanline which translates to about 195KHz. At that frequency you could apply some dithering to the 4-bit samples to increase the precision. If my math is right that would get you to about 6 bits of precision at 48Khz.

  • Like 5

Share this post


Link to post
Share on other sites

I made the Desireless - Voyage Voyage examples using phaeron's techniques as reverse engineered from his 60FPS demos. Original thread here. Some more examples using Bon Jovi here. Both rely on instantaneous XEX segment loads as found in emulators. They have gaps for loading on real hardware. I didn't know about the PCM Audio Experiments thread. Thanks for the pointer!

 

Ah, I guess that's why I got mixed up about who had done them. I can also see why I couldn't find the thread -- seeing it's mainly about PAL-Blending (plus the fact I was searching for posts by phaeron).

 

 

Unfortunately the PWM technique loses precision the higher the frequency. At 15Khz it has around 6.5 bits. So at 45Khz it would only have around 2 bits of precision assuming you could properly time everything. At that point it would be better to go back to volume-only mode which has 4 bits of precision.

 

Yeah, I can hear that (loss of precision in higher frequencies) in the Bon Jovi example, whereas it doesn't really show up in the Desireless example; so, the Desireless tune is a good selection for the technique being used. It sounds great, and you've still got video going.

 

 

Unrolled LDA/STAs could do about 13 AUDC updates per scanline which translates to about 195KHz. At that frequency you could apply some dithering to the 4-bit samples to increase the precision. If my math is right that would get you to about 6 bits of precision at 48Khz.

 

I'm sure everybody would love to see how much further things could be pushed.

Edited by MrFish
  • Like 2

Share this post


Link to post
Share on other sites

It actually sounds forced and muffled. You may listen to the sources of that samples.

 

April 1st, well, the Article shows some frequency waves.... very low at resolution. But it COULD point to 8 bits , if it was just showing a better resolution itself.

You may analyze the picture and see that a lot of data is different and peaks were missing. You may possibly see more differences by a cleaner picture.

 

Hi emkay, Author here.

 

-So, the player is actually 48khz, as obvious from the source code of the player, which is in the article.

 

-It's also 8-bit: it uses Pex 'Mahoney' Tufvesson's technique to play 8 bit digi which, by the way, is only one of the two known techniques to play 8 bit digi on the SID, as clearly stated in the article. Check Mahoney's page for details about the technique I used. The link is in the article.

 

-The picture is fuzzy, but you can click on it, and it zooms out. I thought that was obvious. Anyway, if you do that, you'll notice that there's absolutely no visible difference in the waveforms, and definitely no peaks are missing. The second waveform is different, because it's the differential waveform, but you have to compare the first and the third, as clearly written in the article.

 

-The loud "ssss" sounds in Mazinger demo are indeed there. But that's because they are also in the original. That is the signature way of singing of Ichiro Mizuki: https://www.youtube.com/watch?v=Y8QXVTn77JM

I'm assuming that you have at least a basic knowledge of the theory of Digital Signal Processing, so you will know that lower frequencies and bit resolutions actually kill fricative sounds, don't amplify them. So the sentence "It's much too sharp sounding. Just like only a strip of bits is played", makes absolutely no sense. That's like saying "that picture is too colorful. Just like it's only one bit per pixel".

 

-And of course, about the possibility of the whole thing being an April fool, I wonder how that can be a possibility given that the demos can be downloaded for everyone to run them. As clearly written in the article.

 

One thing you are right about, though: The originals, that are 96Khz 24bit in lossless compression, might sound a tiny bit better than the C64 version, which is 48Khz 8 bit with lossy compression. I would be surprised if that wasn't the case.

But that too is clearly written in the article. :-)

 

A big hello to all the folks here: I'm a HUGE fan of all Atari things!

Take care

Antonio

  • Like 12

Share this post


Link to post
Share on other sites

Ciao Antonio and congratulations for your player (and for Planet Golf too).

I have seen the player some days ago on Italian speaking FB groups.

Share this post


Link to post
Share on other sites

 

Hi emkay, Author here.

 

-So, the player is actually 48khz, as obvious from the source code of the player, which is in the article.

 

-It's also 8-bit: it uses Pex 'Mahoney' Tufvesson's technique to play 8 bit digi which, by the way, is only one of the two known techniques to play 8 bit digi on the SID, as clearly stated in the article. Check Mahoney's page for details about the technique I used. The link is in the article.

 

-The picture is fuzzy, but you can click on it, and it zooms out. I thought that was obvious. Anyway, if you do that, you'll notice that there's absolutely no visible difference in the waveforms, and definitely no peaks are missing. The second waveform is different, because it's the differential waveform, but you have to compare the first and the third, as clearly written in the article.

 

-The loud "ssss" sounds in Mazinger demo are indeed there. But that's because they are also in the original. That is the signature way of singing of Ichiro Mizuki: https://www.youtube.com/watch?v=Y8QXVTn77JM

I'm assuming that you have at least a basic knowledge of the theory of Digital Signal Processing, so you will know that lower frequencies and bit resolutions actually kill fricative sounds, don't amplify them. So the sentence "It's much too sharp sounding. Just like only a strip of bits is played", makes absolutely no sense. That's like saying "that picture is too colorful. Just like it's only one bit per pixel".

 

-And of course, about the possibility of the whole thing being an April fool, I wonder how that can be a possibility given that the demos can be downloaded for everyone to run them. As clearly written in the article.

 

One thing you are right about, though: The originals, that are 96Khz 24bit in lossless compression, might sound a tiny bit better than the C64 version, which is 48Khz 8 bit with lossy compression. I would be surprised if that wasn't the case.

But that too is clearly written in the article. :-)

 

A big hello to all the folks here: I'm a HUGE fan of all Atari things!

Take care

Antonio

Thanks for joining! Bigger thanks for the clarification. Don't worry about emkay. His opinions are stated as fact for everyone else. If it doesn't "sound like" 8-bit to him, it is not, and he will do no research (look at the source code) or listen to anyone stating otherwise.

  • Like 1

Share this post


Link to post
Share on other sites

Ciao Antonio and congratulations for your player (and for Planet Golf too).

I have seen the player some days ago on Italian speaking FB groups.

Ciao Philsan, thanks!

Thanks for giving PG a try too. I would love to port it to Atari, and I'm sure it'll happen at some point. I've been drooling over that faster CPU for decades now :-)

  • Like 4

Share this post


Link to post
Share on other sites

Thanks for joining! Bigger thanks for the clarification. Don't worry about emkay. His opinions are stated as fact for everyone else. If it doesn't "sound like" 8-bit to him, it is not, and he will do no research (look at the source code) or listen to anyone stating otherwise.

No worries, It's actually my fault. I should write shorter and clearer explanations rather than pages and pages of boring details. :-)

  • Like 1

Share this post


Link to post
Share on other sites

No worries, It's actually my fault. I should write shorter and clearer explanations rather than pages and pages of boring details. :-)

Could be interesting to read that, Possibly you'll know what's going on for real then?

 

IF the playback was at real 48kHz and 8 bit, everything was fine.

 

About the BIT usage. 1 Bit beats 16 bit in audio resolution. It's the method that makes it possible. ;)

Share this post


Link to post
Share on other sites

@Antonio, as a Planet Golf purchaser I'd love to see it on the Atari, great work...Loved the intro disk..

  • Like 1

Share this post


Link to post
Share on other sites

@Antonio, as a Planet Golf purchaser I'd love to see it on the Atari, great work...Loved the intro disk..

 

Offtopic.. yeah, nice game there :)

Pretty good samples and animations.. and I suppose that's the c64 high resolution mode?, it would be difficult to have the same clean look in the A8 (or a lot of work using pm's underlays).

 

 

I "LOLed" at the alien x)

 

@Antonio, have you published info about your ball physics and collisions code?.. it would make for a nice article.

Sometimes I think about doing something like "Super Stickman Golf" or "Desert Golfing" in the A8.

  • Like 3

Share this post


Link to post
Share on other sites

Btw: Has someone ever measured the voltage levels of all available combination of the 4 channels ?

Share this post


Link to post
Share on other sites

Btw: Has someone ever measured the voltage levels of all available combination of the 4 channels ?

I'll be at my workbench sometime this weekend with some disassembled machines. I can do this if you like. Couple of questions. Do wou want the voltage measured directly at the PoKey outputs (before any mixing circuitry)? Also, would the BASIC SOUND statement be enough to accomplish these tests?

  • Like 2

Share this post


Link to post
Share on other sites

I'll be at my workbench sometime this weekend with some disassembled machines. I can do this if you like. Couple of questions. Do wou want the voltage measured directly at the PoKey outputs (before any mixing circuitry)? Also, would the BASIC SOUND statement be enough to accomplish these tests?

It's about the volume only bit.

Set bit 4 in all audio controls.

AUDC1 to AUDC4

 

Then check all available combination of the volumes...

 

There are 4 x 4 x 4 x 4 ( 4 channels with 4 bit volume control) combinations .... Useful is the value at the pin out of the AV plug.

  • Like 1

Share this post


Link to post
Share on other sites

Nonlinear audio option in Altirra (the default now?) gives a good approximation of the actual levels. In a nutshell, there aren't 256 distinguishable levels, but you can push beyond the recommended maximum of 32 with enough set bits. Listen to Jim Slide cart samples. They are about 7 bit, I think.

Share this post


Link to post
Share on other sites

Nonlinear audio option in Altirra (the default now?) gives a good approximation of the actual levels. In a nutshell, there aren't 256 distinguishable levels, but you can push beyond the recommended maximum of 32 with enough set bits. Listen to Jim Slide cart samples. They are about 7 bit, I think.

How about the GTIA bit ?

Share this post


Link to post
Share on other sites

4 + 4 + 4 + 4 doesn't equal 16 bits of audio precision. It's more like 6 bits if you're lucky and there's the problem of delay in storing 4 values.

 

The GTIA bit and the PIA bit if a tape drive's connected - supposedly each equates to about level 8 of a single voice which isn't a great deal of help.

 

Instead of chasing more "high bits" the way to go is probably to try for more "low bits". e.g. running a single voice with an ultra-high frequency note in 1.79 MHz mode at low amplitude might give some extra low value amplitude. Such techniques have probably not been explored very well.

  • Like 2

Share this post


Link to post
Share on other sites

4 + 4 + 4 + 4 doesn't equal 16 bits of audio precision. It's more like 6 bits if you're lucky and there's the problem of delay in storing 4 values.

I actually wrote 4*4*4*4 which equals 256

 

You can address 256 values using 8 bit resolution, and well, not all combinations do add there.

 

In theory you can get 16 values from one channel. adding other channel's volumes.

The calculation looks even more like 16 bit. But, what had to be done is to find a row of different voltages that fits best to the 8 bit stepping.

Not to forget the "silent" mode , when POKEY throws the volume down, after the load of all channels gets too loud.

 

Yeah, the 1.79MHz filter would be the solution for all digi. problems. Crystal clear speech without any side-noise. But let's see what happens the next 40 years ;)

Share this post


Link to post
Share on other sites

It's actually - 1 voice = 4 bits.

2nd voice = almost the 5th bit.

3rd + 4th voices = almost the 6th bit.

 

Possibly if going for the "lower bit" we could use just 3 voices in total - the 6th bit (being the extra low bit in this case) coming from the single voice @ 1.79 MHz. Leaving the 4th voice alone for conventional sound.

  • Like 1

Share this post


Link to post
Share on other sites

It's actually - 1 voice = 4 bits.

2nd voice = almost the 5th bit.

3rd + 4th voices = almost the 6th bit.

 

Possibly if going for the "lower bit" we could use just 3 voices in total - the 6th bit (being the extra low bit in this case) coming from the single voice @ 1.79 MHz. Leaving the 4th voice alone for conventional sound.

Have you checked it using a voltage meter?

Share this post


Link to post
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...