
The Visual 6502 is a project run by Greg James and a handful of self confessed microchip archaeologists. By meticulously taking hundreds of photographs of microchips they then stitch them back together and convert all of the die information into a vector format for future preservation. Greg explains the reasoning behind this mammoth process in the site FAQ:
“There are many excellent emulators available, but emulation is approximation. It can be extremely difficult to create an accurate emulator, because the typical approach to writing an emulator is to glean information from chip specification documents or more rarely from any chip schematics that happen to be available. This information is always incomplete and even the original chip logic schematics (also Verilog and VHDL code) can differ from what was actually built in silicon (see ECO). A disciplined emulator will capture and use traces of actual chip behavior, but it’s near impossible to capture the billions of sequences of bits that a real chip gives rise to. Instead, we build a virtual chip by modeling and simulating the actual microscopic parts of a physical chip. We’re interested in accurately preserving historic designs.”
Taking the data compiled by their process the web site offers a visual chip to play with. At present they have the 6502 online, made famous in just about every early home computing device such as the Atari 2600. There is also a 6800 to play with. The simulator works by showing the assembly code running down the right-hand side and a complete visual chip layout on the left. As the code runs you can literally watch the instructions fire across the chip – zooming in and out and watching the transistors propagate the messages. You’d be forgiven for wondering how accurate a JavaScript simulation could be – Greg explains:
“The simulator is running an idealized “digital” circuit based on our model of the chip’s network of transistors and wires. It does not account for “analog” behavior (resistance, capacitance, leakage), has no propagation delays, and transistors switch on and off instantaneously. The real chip uses the same network of transistors (barring any mistakes we may have made in our model), but these transistors are analog devices. Our simulation uses a few simple heuristics to account for the differences in behavior between the actual analog circuits and our idealized digital model. In our simulation, if a transient short occurs from power to ground, ground wins. This may happen in our iterative solver as the simulation state is converging. Also, when two floating regions are switched together, their final voltage is taken from the region with the most components. This is a simple but completely non-physical way to account for capacitance.”
Even if like me you have no understanding of chip design, and your assembly coding skills haven’t been deployed in decades, this is still a remarkable and fascinating project well worth exploring.
Cracks me up, nuff thanks for the 6502 piece; really nice flashback to my early teens in early 80s on an atari 400 coding smooth games in 6502 and the amazing custom graphics it had, pokey, and the cpu speed 1.79Mhz if i recall right, was matched to the speed at which the cathode ray traversed the tv tube so you could write code that ran in the vertical blank time between bottom of one frame and top of next and if you were real hardcore you;d code horizontal blank interrupts which ran in the time it took the gun to go from the far right of one scan line to the far left of the next, which aint long, so we had to learn how many clock cycles each 6502 opcode cost and write tight code and normally you get four sprites but if you changed the sprite on the sly during the horizontal blank time you could get loads more but they could only move left/right, hence all the games with vertically stacked levels, frogger etc, and finally i had a printed copy of all the 6502 for the entire 8k operating system rom, and understood pretty much everything the os could do down to the opcode and finally finally, the 6502 opcode that i most liked and still do was this one: NOP . NO OPERATION. it does nothing. heaven.
anyways nuff respec an thanks very much, muaahah 8bit crazy ppls