phoenix@ms.uky.edu (R'ykandar Korra'ti) (11/23/89)
Article 22689 of comp.sys.atari.st: Path: ukma!rex!samsung!uunet!mcsun!unido!uklirb!incas!hoenig From: hoenig@incas.UUCP (Helmut Hoenig) Newsgroups: comp.sys.atari.st Subject: 6502 - the ultimate (?) emulation Message-ID: <3189@incas.UUCP> Date: 21 Nov 89 10:10:51 GMT Distribution: comp Organization: University of Kaiserslautern, W-Germany Lines: 52 Posted: Tue Nov 21 11:10:51 1989 Is there any use of a VIC20-Emulation on the ATARI ST ? I wrote one to test a new kind of emulation: The 6502-code of the VIC20- Machine is not interpreted the usual way. It gets *translated* in 68000-Code at run-time. That means: If a statement is reached for the second time, it is already translated. This gets very difficult, especially if self-modifying code is alowed (already the Commodore-Basic uses it). My final results: - It needs a *lot* of memory: The memory of the Atari is sliced in 8-byte slots of code for every VIC20-Byte (unfortunatly, that's not enough for a lot of 6502-Commands). An additional flag-byte is needed for every VIC20-RAM-byte. - It's *not* faster than a normal interpreter: Programs usually run about 4 to 5 times longer on the Atari. This sounds very bad, but it is not. A lot of time is needed for updating the display (about 40% of the time is needed when simulating the colors on the Monochrom-Monitor) and for interrupts. Since I didn't change a single bit in the kernel, the original routine for decoding the key-matrix is running. On the other side, I had to encode the key-events of the Atari to let that routine work correct. I found out very early, that this is *not* the ultimate emulation. But I continued working on it, until my favorite ROM-Modules of the VIC20, the games 'AVENGERS' and 'STAR BATTLE', where running. As they were made in the early days of the VIC20, their 'CPU'-usage is not too high and they can be emulated nearly in real-time. Fortunatly they use the timers to 'sleep' and not some strange loops. Now I've got a problem: The Copyrights. I wrote my program just for fun (although I though it's a great invention). Of course, I would allow to copy it freely. But you can't do anything without the copy of the VIC20-ROMS and some game-modules (you can get them nearly as gifts, if you still find them in a store). The question is: - Am I allowed to distribute these files with my program ? - If not: Am I allowed to copy these files at least to owners of a VIC20, as they also could have transferred them to the Atari on their own ? Is there a 'yes'-answer anywhere ? -- Helmut Hoenig, University of Kaiserslautern, Germany. hoenig@informatik.uni-kl.de -- | R'ykandar Korra'ti, Editor, LOW ORBIT | phoenix@ms.uky.edu | CIS 72406,370 | | Elfinkind, Unite! | phoenix@ukma.bitnet | PLink: Skywise | QLink: Bearclaw |