Jump to content



phaeron's Photo

phaeron

Member Since 28 Oct 2007
OFFLINE Last Active Private

Topics I've Started

SIO timing requirements

Sun Feb 12, 2012 7:08 PM

Does anyone know how rigidly the SIO timing specifications in the OS manual are followed in practice? I'm working on a high-speed SIO routine and am trying to determine what delays are required, since some of the delays are annoying to hit with variable DMA involved. The one I'm particularly interested in is the t2 delay from last command byte to command line deassert. This is specced as 650-950 microseconds, but it looks like the OS routine violates this by only waiting 400us:

	T-0.000403 | A=00 X=FE Y=00 S=F2 P=32 | EAA7: F0 F5			 BEQ $EA9E
  + IRQ interrupt
...
	  T-0.000002 | A=A0 X=FE Y=31 S=F0 P=B0 | EB11: A9 3C			 LDA #$3C
	  T+0.000000 | A=3C X=FE Y=31 S=F0 P=30 | EB13: 8D 03 D3		  STA PBCTL

The actual delay is even lower in a gr.4 (IR mode 8) screen, only 300us.

I was tempted to use timers 1+2 in 15KHz for timeouts as it's easier to set up than OS timer 1 and I can hit delays up to four seconds that way, but now I'm not even sure I need to be that precise with the delays.

Altirra 2.00

Sat Dec 24, 2011 12:20 PM

Well, this is nothing new to anyone who's been following the test releases, but here's version 2.00 final of my Altirra emulator. There are no significant changes from the last test release. Thanks to everyone who provided feedback!

(You need to copy and paste these links into your browser, since I have a referrer check on the download directory.)
http://www.virtualdu...ltirra-2.00.zip
http://www.virtualdu...ra-2.00-src.zip

And, now that 2.00 is released, I can release the changes that I've been keeping on the side into the main devline. :D New features include disk drive emulation levels, Slight-SID emulation, the debugger's alias support has been beefed up to emulate more Atari800 debugger commands, and WIP on 1030 modem support.

http://www.virtualdu...-2.10-test2.zip
http://www.virtualdu...0-test2-src.zip

Happy holidays, everyone!

PCM audio experiment

Sun Oct 16, 2011 5:10 AM

For a while now, I've been thinking about ways to do PCM audio on the 8-bit Atari better than the standard 4-bit PCM through volume-only mode. The way this used to be done with the PC speaker was through one-shot mode, which unfortunately POKEY lacks. I tried doing this with two-tone mode but wasn't able to get more than about 4.5-bit precision due to only being able to use the second half of each period. I realized last night that 16-bit linked timers could be used to create a one-shot timer by using the high timer to hold down the low timer after it has fired. The result is the attached music. I'm interested in knowing if it works for other people on real hardware, since the noise is less than I expected (there is a 15KHz carrier due to the technique used). You probably won't be able to get it running if you have a 65C02 or 65C816 due to a hack I used in the timer IRQ. Some of the 2.0 test builds of Altirra also have a regression in STIMER handling that prevents this from playing properly; 1.9 is OK, and this version has a bug fix:

http://www.virtualdu...2.00-test43.zip
http://www.virtualdu...-test43-src.zip

The output sample precision is about 6.7 bits, but the volume is a bit low because three voices are being mixed.