phaeron Posted July 19, 2022 Author Share Posted July 19, 2022 18 hours ago, MrFish said: What are the valid values that can be used? I tried 1 - 5 (0=off); but to be honest, 1 is quite a bit above typical POKEY levels (and 5 blasted my eardrums out). For comparison, I'm playing some recently posted GTIA chip music and some POKEY music that I have on hand. It looks like the volume ramp needs to start a little lower. Any non-negative values are valid, but the intended range is 0-1. It's just a linear amplitude scaling factor. However, this is before the global volume level, which will usually be around -6 dB to -3 dB. To be specific, a value of 1 with global volume at 0 dB means that the raw GTIA output will be a square wave between 0% and 100%. You can raise it above 1, with an increased chance of the output saturating and clamping. Setting it to a value like 5 makes it overdrive hard and constantly clamp out, effectively rectifying the output into a square wave, but this isn't intended (or recommended for your speakers and ears). Note that there is a high-pass filter in between the GTIA mix point and the final output in the emulator. It is designed to gradually remove the DC offset from the output, to deal with the asymmetric output from both POKEY and GTIA and to simulate the effect of AC coupling in the hardware amplifier. This avoids having the host computer's output being unbalanced as well, which would lead to stop/start popping and distortion in the system audio mixer. The time constant is long to keep it from affecting the character of the sound, but you can see the effects of it in the captured waveform (from an OS key click): The long time constant means that it cannot immediately balance the output however, which is why "full volume" is only targeted at full amplitude swinging in one direction. 18 hours ago, MrFish said: Is this standard procedure for first time changes to anything in the advanced config? I made my subsequent changes without following this procedure. No, the UI dialog is the main procedure. This is just the back door for when things go pear shaped, since the config variables are for advanced / unsupported usage only. Ideally the emulator would realize there's a problem and bring this up automatically, but I haven't designed a mechanism for that yet. 1 1 Quote Link to comment Share on other sites More sharing options...
tebe Posted July 19, 2022 Share Posted July 19, 2022 (edited) "Piccolo slideshow" crashes when we have an active "SlightSID" device. Maybe it should be so, or maybe not ? When I try to use "Piccolo", "PSD Converter", "Convert PSD to A8", I get a message Emulator parameters: /nodebugbrkrun Edited July 19, 2022 by tebe Quote Link to comment Share on other sites More sharing options...
+MrFish Posted July 19, 2022 Share Posted July 19, 2022 5 hours ago, phaeron said: ...but the intended range is 0-1. You got me with the fractions. I'll be able to find a suitable level now. A great addition for listening to these chip tunes... 5 hours ago, phaeron said: Note that there is a high-pass filter in between the GTIA mix point and the final output in the emulator. Reminds me of the early versions of Altirra, when you had a low-pass filter on POKEY. I really liked how that sounded; I know it's not realistic, but then neither are Windows fonts in Atari BASIC. 5 hours ago, phaeron said: No, the UI dialog is the main procedure. This is just the back door for when things go pear shaped, since the config variables are for advanced / unsupported usage only. Ideally the emulator would realize there's a problem and bring this up automatically, but I haven't designed a mechanism for that yet. No complaints here. I'm sure you'll get around to it sometime. Thanks again for the addition. Quote Link to comment Share on other sites More sharing options...
phaeron Posted July 19, 2022 Author Share Posted July 19, 2022 2 hours ago, tebe said: "Piccolo slideshow" crashes when we have an active "SlightSID" device. Maybe it should be so, or maybe not ? Both the slideshow and SlightSID are cartridges, you can't use the two together. Even if you could wire up a passthrough port, AtariMax carts use the whole $D5xx page and SlightSID's registers are at the bottom of the page where carts typically access to switch AtariMax 1Mbit banks. 2 hours ago, tebe said: When I try to use "Piccolo", "PSD Converter", "Convert PSD to A8", I get a message I can't get the Piccolo tool to work, but you have the PSD file in a path that contains spaces and the error you're getting from Altirra suggests that Piccolo is not property wrapping such paths in quotes on the command line. 1 Quote Link to comment Share on other sites More sharing options...
phaeron Posted July 19, 2022 Author Share Posted July 19, 2022 12 minutes ago, MrFish said: Reminds me of the early versions of Altirra, when you had a low-pass filter on POKEY. I really liked how that sounded; I know it's not realistic, but then neither are Windows fonts in Atari BASIC. It wasn't a low-pass filter, but the volume curve on the non-linear mixing mode, meant to simulate the saturation characteristics of the POKEY output as the total channel volume rises. It was more aggressive in older versions, which had the effect of compressing the audio output more, until I retuned it down based on new measurements. It sounds better on some tunes for the same reason that ads have such compressed audio -- because moar louder is moar better. You can try using a compressor or over-amplifying with a soft clamp to get a similar effect. Average computer speakers don't help either, if you have common ones that naturally lack bass response. Altirra does have a low-pass filter on the output, but at a much higher cutoff (15KHz). This is to prevent ultrasonics from aliasing down into audible range. Quite a lot of programs set POKEY channels to inaudible frequencies of around 31KHz instead of actually muting them; without such a filter, these would alias down to an awful ~7KHz whine. 3 Quote Link to comment Share on other sites More sharing options...
Synthpopalooza Posted July 19, 2022 Share Posted July 19, 2022 On 7/17/2022 at 8:27 PM, phaeron said: Added option for downmixing stereo audio to mono Thanks so much for this! My Metroid tunes sound so much better now! 1 Quote Link to comment Share on other sites More sharing options...
+MrFish Posted July 19, 2022 Share Posted July 19, 2022 1 hour ago, Synthpopalooza said: Thanks so much for this! My Metroid tunes sound so much better now! Yeah, it does. Here's a link to the post for it: Synthpop - Metroid (Stereo to Mono) 1 Quote Link to comment Share on other sites More sharing options...
+MrFish Posted July 19, 2022 Share Posted July 19, 2022 9 hours ago, phaeron said: It wasn't a low-pass filter, but the volume curve on the non-linear mixing mode, meant to simulate the saturation characteristics of the POKEY output as the total channel volume rises. It was more aggressive in older versions, which had the effect of compressing the audio output more, until I retuned it down based on new measurements. Ah, ok; I thought you had said it was a low-pass before. Well, as I said, accurate or not, I liked what it was doing; a nice enhancement. 9 hours ago, phaeron said: It sounds better on some tunes for the same reason that ads have such compressed audio -- because moar louder is moar better. Haha 9 hours ago, phaeron said: Altirra does have a low-pass filter on the output, but at a much higher cutoff (15KHz). This is to prevent ultrasonics from aliasing down into audible range. Quite a lot of programs set POKEY channels to inaudible frequencies of around 31KHz instead of actually muting them; without such a filter, these would alias down to an awful ~7KHz whine. Interesting. Why are people doing this, as a means of saving some bytes of code, etc.? Quote Link to comment Share on other sites More sharing options...
phaeron Posted July 19, 2022 Author Share Posted July 19, 2022 2 hours ago, MrFish said: Interesting. Why are people doing this, as a means of saving some bytes of code, etc.? It does save code in that you can silence a channel by writing 0 into the frequency (period) register instead of having to separately update the volume register and complicate the envelope code. But I suspect it's just more that it worked and there was no reason to do otherwise. This is only a problem when emulating or recording POKEY with digital sampled audio. In the analog domain on the hardware, there's no hard frequency limit, just attenuation -- and if somehow the ultrasonic signal makes it all the way through, it ends up at a speaker cone that can't possibly move fast enough to produce any real sound out of it. In the digital domain, though, there is the Nyquist limit at half the sampling rate, and anything above that limit gets folded down like an accordion without filtering. Thus, it's necessary to filter out those frequencies rather than let them alias to a bogus lower frequency. Some older POKEY emulators simply muted channels above a frequency threshold, but this doesn't work with more tricky output configurations like two ultrasonic channels intentionally set up to interfere with each other to produce a lower frequency. That having been said, there is a reason to avoid doing this in real hardware, which is that it pegs the channel at a non-zero average volume, which can cause more distortion in the mixed output than necessary. 2 Quote Link to comment Share on other sites More sharing options...
+MrFish Posted July 19, 2022 Share Posted July 19, 2022 1 hour ago, phaeron said: That having been said, there is a reason to avoid doing this in real hardware, which is that it pegs the channel at a non-zero average volume, which can cause more distortion in the mixed output than necessary. True Quote Link to comment Share on other sites More sharing options...
Synthpopalooza Posted July 19, 2022 Share Posted July 19, 2022 Playing zero frequencies in $Ax distortion is also not a good idea because they are ultrasonic and can introduce transients into the mix, even more so in 15khz mode where it actually becomes audible. $Cx distortion has a way around this, by playing $0E it outputs silence due to polycounter sampling. 1 Quote Link to comment Share on other sites More sharing options...
Xuel Posted July 20, 2022 Share Posted July 20, 2022 On 7/17/2022 at 7:27 PM, phaeron said: Added option for downmixing stereo audio to mono. Any chance for a stereo separation slider? It would be nice to have some stereo separation but less than 100% for headphone listening. 3 Quote Link to comment Share on other sites More sharing options...
VinsCool Posted July 20, 2022 Share Posted July 20, 2022 23 minutes ago, Xuel said: Any chance for a stereo separation slider? It would be nice to have some stereo separation but less than 100% for headphone listening. +1 for this suggestion! Having the Stereo output downmixed to Mono is awesome, still! This will be fantastic to adapt to the RMT plugin later, in any case. Quote Link to comment Share on other sites More sharing options...
rensoup Posted July 23, 2022 Share Posted July 23, 2022 On 7/19/2022 at 9:49 AM, phaeron said: I can't get the Piccolo tool to work, but you have the PSD file in a path that contains spaces and the error you're getting from Altirra suggests that Piccolo is not property wrapping such paths in quotes on the command line I thought I used spaces all over the place in many pictures I tried but perhaps that was just in filenames and not directories... Small request, any chance of supporting filenames with "/" on the cmd line, so that xex could be associated with Altirra in linux ? Have to say it works really well under Wine. Quote Link to comment Share on other sites More sharing options...
phaeron Posted July 24, 2022 Author Share Posted July 24, 2022 5 hours ago, rensoup said: I thought I used spaces all over the place in many pictures I tried but perhaps that was just in filenames and not directories... Small request, any chance of supporting filenames with "/" on the cmd line, so that xex could be associated with Altirra in linux ? Have to say it works really well under Wine. They should generally work, but you need to wrap them in quotes. Can't for unquoted rooted paths, as this would conflict with the Windows conventions for switches. 2 Quote Link to comment Share on other sites More sharing options...
Kylev Posted July 24, 2022 Share Posted July 24, 2022 Hi, I am using the device settings for an emulated MIO board. I can successfully assign a VHD file to the device, configure the drive with the MIO settings screen, initialize the drive with HDINIT and copy files to the hard disk. However, as soon as I perform a cold start or exit the emulator the configuration for the hard disk is lost (along with any file copied to it) and I have to start again from scratch. This is the kind of behavior I would expect from the real device, if I powered the MIO board off. If I remember correctly, though, I should have been able to re-configure the device in the MIO settings and regain access to the hard drive. I must be doing something wrong. I never could afford a hard drive for my system back in the day, so I am working from a reading of the manual and the Altirra help file. Any help will be greatly appreciated. Quote Link to comment Share on other sites More sharing options...
rensoup Posted July 26, 2022 Share Posted July 26, 2022 On 7/24/2022 at 6:16 AM, phaeron said: They should generally work, but you need to wrap them in quotes. Can't for unquoted rooted paths, as this would conflict with the Windows conventions for switches. Ah, still can't get it to work but that could be an issue with Wine maybe I just don't know how to set file associations properly in Linux... Anyone figured this out ? How to make clicking on a .car/.xex launch Altirra in Wine with the file as a parameter ? Quote Link to comment Share on other sites More sharing options...
VinsCool Posted July 26, 2022 Share Posted July 26, 2022 2 hours ago, rensoup said: Ah, still can't get it to work but that could be an issue with Wine maybe I just don't know how to set file associations properly in Linux... Anyone figured this out ? How to make clicking on a .car/.xex launch Altirra in Wine with the file as a parameter ? Not sure how to make that shortcut exactly but using this command-line format seems to work fine for me: I imagine as long as the arguments used for the shortcut is following this format, it would work? Quote Link to comment Share on other sites More sharing options...
phaeron Posted July 26, 2022 Author Share Posted July 26, 2022 On 7/24/2022 at 3:45 PM, Kylev said: Hi, I am using the device settings for an emulated MIO board. I can successfully assign a VHD file to the device, configure the drive with the MIO settings screen, initialize the drive with HDINIT and copy files to the hard disk. However, as soon as I perform a cold start or exit the emulator the configuration for the hard disk is lost (along with any file copied to it) and I have to start again from scratch. This is the kind of behavior I would expect from the real device, if I powered the MIO board off. If I remember correctly, though, I should have been able to re-configure the device in the MIO settings and regain access to the hard drive. I must be doing something wrong. I never could afford a hard drive for my system back in the day, so I am working from a reading of the manual and the Altirra help file. Any help will be greatly appreciated. The MIO keeps its configuration in sector 0 of the first hard drive. Make sure you aren't placing a partition at 0; the ICD Configurator will let you do this, but this will just overwrite the config as soon as you initialize the partition. You should be able to cold reset or restart the emulator and the MIO configurator should show the config that was previously saved. 4 hours ago, rensoup said: Ah, still can't get it to work but that could be an issue with Wine maybe I just don't know how to set file associations properly in Linux... Anyone figured this out ? How to make clicking on a .car/.xex launch Altirra in Wine with the file as a parameter ? Remember that Altirra is a Windows application and expects Windows paths. It appears that the wine program will attempt to do path translation, but this will only work if the Linux path you're giving it can be mapped to one of the drive letter paths in wine's config. Quote Link to comment Share on other sites More sharing options...
GoodByteXL Posted July 26, 2022 Share Posted July 26, 2022 6 hours ago, rensoup said: Ah, still can't get it to work but that could be an issue with Wine maybe I just don't know how to set file associations properly in Linux... At least for using Altirra under a linux gui it is quite easy. With Linux Mint I created after installation of WINE a symlink: sudo ln -s /usr/share/doc/wine/examples/wine.desktop /usr/share/applications/ Could be possible linux will need a restart, depends ... Thereafter right-click on the respective Altirra EXE and you will be prompted with an option to open this exe with the WINE Windows Program Starter. Click and go ... No Windows hassles anymore. 2 hours ago, phaeron said: Remember that Altirra is a Windows application and expects Windows paths. It appears that the wine program will attempt to do path translation, but this will only work if the Linux path you're giving it can be mapped to one of the drive letter paths in wine's config. In my view this is the only real disadvantage of Altirra. I cross my fingers it will be generally usable under WINE in the future. Quote Link to comment Share on other sites More sharing options...
rsh Posted July 26, 2022 Share Posted July 26, 2022 Altirra basic needs the move, bget, bput, poke, peek, dpeek, dpoke, fre(<bank>) to support bank switching like Basic XE. Basic XE added an extra parameter the specifies the extended memory bank. This would eliminate the need for special extra bank routines required taking up your program space. Looks like Altirra has captured almost all of Basic XE style commands except for these... which I think is really important... Basic XE has a mode called "extend" that allowed those functions to work with the extra 64K in 130XE... but Altirra could be smart enough to not need command and be able to access all compy/rambo memory for the emulator or real hardware like the NUC+ or other hardware mods. I think Altirra should still support the "extend" command as an option because the extend in Basic XE moved all of the program into the extended ram freeing the other main 32K up for whatever. This allowed you to wright a huge basic program filling up the extended banks bottom up, anything you didn't use could be used for data. It was quite brilliant by OSS an elegant. Quote Link to comment Share on other sites More sharing options...
Mclaneinc Posted July 26, 2022 Share Posted July 26, 2022 I'm pretty sure that Avery has said that the rewrite literally took almost every byte of the file, hence we lost the CONT command in favour of a hugely optimised BASIC. Quote Link to comment Share on other sites More sharing options...
+MrFish Posted July 26, 2022 Share Posted July 26, 2022 BASIC XE is on a 16 KB cartridge -- and requires an extension disk for some features. Altirra BASIC is meant to be an upgraded replacement for Atari BASIC, necessarily on an 8 KB ROM. You're not going to fit BASIC XE into Altirra BASIC because of the size constraints, which is what @Mclaneinc is talking about in the previous post. 1 Quote Link to comment Share on other sites More sharing options...
rsh Posted July 26, 2022 Share Posted July 26, 2022 Just now, MrFish said: BASIC XE is on a 16 KB cartridge -- and requires an extension disk for some features. Altirra BASIC is meant to be an upgraded replacement for Atari BASIC, on an 8 KB ROM. You're not going to fit BASIC XE into Altirra BASIC because of the size constraints, which is what @Mclaneinc is talking about in the previous post. I see... but I'm just talking about enhancing a couple of the current commands to support banks switching easy lol .... if it's truly maxed... maybe create a supercart version or an Optional add on loader of commands that eat a little high/ext memory. Quote Link to comment Share on other sites More sharing options...
+MrFish Posted July 26, 2022 Share Posted July 26, 2022 27 minutes ago, rsh said: I see... but I'm just talking about enhancing a couple of the current commands to support banks switching easy lol .... if it's truly maxed... maybe create a supercart version or an Optional add on loader of commands that eat a little high/ext memory. @phaeron already has a project that extends Altirra BASIC here: Altirra Extended BASIC Maybe you can focus your attention/requests in that thread. 1 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.