Wednesday, April 24, 2024

Re: Response to "The 6502 CPU Powered a Whole Generation!'

For some reason, Gmail sometimes destroys my formatting.  This was a problem with cutting and pasting.

Here is a corrected version:



 https://www.youtube.com/watch?v=acUH4lWe2NQ

I programmed the SNES, Sony PlayStation, and Gameboy Color for a couple of major video game developers. My experience with Z80 and 6502 programming goes back to the 1970s.

I love how efficient the 6502 processor is. I have no doubt that for 8-bit operations it is twice as fast as a Z80. The first chess computers were 4 Mhz Z80s, but manufacturers switched to the 6502, starting at 2, 3, and 4 MHz, and eventually going up to 6 MHz.

The Z80 has almost twice as many transistors as the 6502, but the 6502 was wisely designed to be fast and cheap.

However, I have to cry foul when it is stated that the Z80 takes an average of 13 clock cycles per instruction.

The Z80 has extra capabilities like 16-bit math and loads. When we compare 8-bit to 8-bit then the 6502 is at most twice as fast.

The Z80 index registers are very inefficient so I never used these registers.

Eight-bit load instructions take 4 to 7 clock cycles depending on the instruction type. Indexed 8-bit loads take a whopping 19 clock cycles.

16-bit loads take 10 to 20 clock cycles depending on the instruction type.

Eight-bit math takes 4 to 7 clock cycles depending upon the type of instruction. Incrementing or decrementing a memory location takes 11 clock cycles, and once again using the inefficient index registers takes 22 clock cycles.

Sixteen-bit math takes 6 to 11 clock cycles, and the indexed registers take 15 clock cycles.

Bit shifting the accumulator takes 4 clock cycles. Bit shifting other registers takes 8 clock cycles. Bit-shifting memory takes 14 clock cycles.

The block memory copy instruction takes a whopping 22 cycles per byte. For copying the same bytes into a block of memory, one can hijack the SP for an average of 5.5 clock cycles per byte not counting control instructions. (There are efficient ways to write this.)


I take issue with your criticism of the Timex Sinclair 2068 computer. I am one of many people who are still fans of this computer. This has much to do with the cost of the computer. The C64 cost $595 when released, which is about $1900 today adjusted for inflation. There was absolutely no way I could afford a C64, but the 2068 was actually a pretty good computer for $200 which I could afford. For me, it was a choice of the 2068 or no computer at all. (You claimed that the C64 was also selling for $200, but this is not what I saw back in 1983. It was hundreds of dollars more. You pointed to an ad that listed the C64 for $200, but I looked at the fine print which showed it was $400 with free software supposedly worth $200.)

The 2068 had a better BASIC with a 24K ROM and additional instructions for accessing graphics and sound.

The C64 definitely had better graphics capabilities for games with sprites and smooth scrolling. However, it was still possible to write games for the 2068. I wrote and self-published a Boulder Dash clone for the 2068 called "Diamond Mike". There are videos of it here on YouTube.

If I were comparing only the processors, I would choose a 3.58 Mhz Z80 over a 1 Mhz 6502. Obviously, I would prefer a faster 6502. I very much enjoyed programming on the SNES with the 3.58 Mhz 65C816. (The reason the speed 3.58 Mhz was used for multiple computers and video game systems is it is 1/4 the speed of the color signal crystal. They used one crystal to drive both things as a cost-savings measure.)

Best wishes,

John Coffey

Response to "The 6502 CPU Powered a Whole Generation!'


I programmed the SNES, Sony PlayStation, and Gameboy Color for a couple of major video game developers. My experience with Z80 and 6502 programming goes back to the 1970s. I love how efficient the 6502 processor is. I have no doubt that for 8-bit operations it is twice as fast as a Z80. The first chess computers were 4 Mhz Z80s, but manufacturers switched to the 6502, starting at 2, 3, and 4 MHz, and eventually going up to 6 MHz. The Z80 has almost twice as many transistors as the 6502, but the 6502 was wisely designed to be fast and cheap. However, I have to cry foul when it is stated that the Z80 takes an average of 13 clock cycles per instruction. The Z80 has extra capabilities like 16-bit math and loads. When we compare 8-bit to 8-bit then the 6502 is at most twice as fast. The Z80 index registers are very inefficient so I never used these registers. Eight-bit load instructions take 4 to 7 clock cycles depending on the instruction type. Indexed 8-bit loads take a whopping 19 clock cycles. 16-bit loads take 10 to 20 clock cycles depending on the instruction type. Eight-bit math takes 4 to 7 clock cycles depending upon the type of instruction. Incrementing or decrementing a memory location takes 11 clock cycles, and once again using the inefficient index registers takes 22 clock cycles. Sixteen-bit math takes 6 to 11 clock cycles, and the indexed registers take 15 clock cycles. Bit shifting the accumulator takes 4 clock cycles. Bit shifting other registers takes 8 clock cycles. Bit-shifting memory takes 14 clock cycles. The block memory copy instruction takes a whopping 22 cycles per byte. For copying the same bytes into a block of memory, one can hijack the SP for an average of 5.5 clock cycles per byte not counting control instructions. (There are efficient ways to write this.) I take issue with your criticism of the Timex Sinclair 2068 computer. I am one of many people who are still fans of this computer. This has much to do with the cost of the computer. The C64 cost $595 when released, which is about $1900 today adjusted for inflation. There was absolutely no way I could afford a C64, but the 2068 was actually a pretty good computer for $200 which I could afford. For me, it was a choice of the 2068 or no computer at all. (You claimed that the C64 was also selling for $200, but this is not what I saw back in 1983. It was hundreds of dollars more. You pointed to an ad that listed the C64 for $200, but I looked at the fine print which showed it was $400 with free software supposedly worth $200.) The 2068 had a better BASIC with a 24K ROM and additional instructions for accessing graphics and sound. The C64 definitely had better graphics capabilities for games with sprites and smooth scrolling. However, it was still possible to write games for the 2068. I wrote and self-published a Boulder Dash clone for the 2068 called "Diamond Mike". There are videos of it here on YouTube. If I were comparing only the processors, I would choose a 3.58 Mhz Z80 over a 1 Mhz 6502. Obviously, I would prefer a faster 6502. I very much enjoyed programming on the SNES with the 3.58 Mhz 65C816. (The reason the speed 3.58 Mhz was used for multiple computers and video game systems is it is 1/4 the speed of the color signal crystal. They used one crystal to drive both things as a cost-savings measure.)

Thursday, April 11, 2024

Old Tube TVs

For those who don't remember, powering up really old televisions would start as an expanding dot in the middle of the screen.  It would only take a few seconds to reach full size.  Old televisions used vacuum tubes instead of transistors, which needed warming up.  They glowed orange.  You could see them through the heat vents in the back.  In a dark room, the TV would light up the wall behind it.

I remember going to a repair shop that had dozens of different types of replacement tubes.   A local drug store used to have a tube tester by the door.

Starting in the mid-1970s, manufacturers advertised televisions that were "Instant On".  I noticed these TVs kept some vacuum tubes powered up even when the TV was "off".

Old TVs put out a great deal of heat.

Friday, April 5, 2024

Columbus Commons Mall



I very much miss the Columbus Commons Mall in downtown Columbus. In the early history of Columbus, many shops were concentrated in the southwest corner of the city, but this would change as businesses moved to the major roads. Most of this mall has been remodeled to be offices for Cummins Engine Company. A small part remains as a public space.

The mall was built when I was around age 12 or 13. For me, it was a great place to explore. I mostly liked the arcade, but I also liked the bookstore, the ice cream shop, and the hamburger place. In the mid-70s there were vendors selling treats, like popcorn and baked goods. There was also an electronics store that I liked and I became friendly with one of the employees.

Columbus opened a new mall on 25th Street, but that failed and is now being remodeled into some sort of recreation center combined with medical offices.