??? 08/31/04 19:31 Read: times |
#76697 - RE: Atari 400/800 implementation with 8052 Responding to: ???'s previous message |
was thinking about how you might do the emulation layer in hardware,having the idea of a system to map 6502 op-codes to 8052 op-codes when reading from a 6502 ROM.The problem comes when the 6805 op-codes map to two or more 8052 op-codes because you then have to 'steal' 8052 program read cycles to insert the new op-codes which don't actualy exist in the 6502 code.This means that you need to maintain an external address counter in the fpga to handle the fact the the 8052 read address and the 6502 rom codes are going to be misaligned by the 'inserted'op-codes.The address counter also has to be reset to the 'real'address when ever there is a jump to an absolute address as in a call or interrupt.Which means that you have to know when an internal or external interrupt has occured which means its a pain in the bum.You can tell when a call is being made by looking at the op-codes sent to the '52 but its not so easy to tell when an interrupt has occured without reproducing all the interrupt sources in the fpga.
|