Good resources to learn how the 6502 works?
Good resources to learn how the 6502 works?
I've looked at diagrams and some articles but is there something I'm missing? is there somwhere where this information is? I think there's a video somewhere but I couldnt find it.
- GARTHWILSON
- Forum Moderator
- Posts: 8773
- Joined: 30 Aug 2002
- Location: Southern California
- Contact:
Re: Good resources to learn how the 6502 works?
Are you looking for hardware, or software, or the combination (as in trying to get into it fresh)? See if there's something at http://6502.org/documents/books/ that you like.
I will probably move this topic to the "Newbies" section later.
Edit: If you mean the insides of the processor itself, as in individual transistors and gates, see http://www.visual6502.org/ .
I will probably move this topic to the "Newbies" section later.
Edit: If you mean the insides of the processor itself, as in individual transistors and gates, see http://www.visual6502.org/ .
http://WilsonMinesCo.com/ lots of 6502 resources
The "second front page" is http://wilsonminesco.com/links.html .
What's an additional VIA among friends, anyhow?
The "second front page" is http://wilsonminesco.com/links.html .
What's an additional VIA among friends, anyhow?
-
White Flame
- Posts: 704
- Joined: 24 Jul 2012
Re: Good resources to learn how the 6502 works?
The visual6502 project is "how the 6502 works" taken to extremes. 
(edit: ...and sniped by Garth's edit!)
(edit: ...and sniped by Garth's edit!)
Re: Good resources to learn how the 6502 works?
Ok thanks! I was hoping to design a cpu on a logic simulator that's compatable with 6502 asm, but since I still dont quite understand how the 6502 PLA works I was thinking of using a rom where part of the address is the timing, part of it is the opcode, and part is for interrupts, and the address lanes will be shared with multiple roms for the selects of different parts, or if it would work fine to use a decoder to select one part at a time from tge output of the rom or even have the opcode and timing be directly attached to the decoder. don't know if there's a better way to learn this
- GARTHWILSON
- Forum Moderator
- Posts: 8773
- Joined: 30 Aug 2002
- Location: Southern California
- Contact:
Re: Good resources to learn how the 6502 works?
Ok, no moving this to "Newbies"!
I expect visual6502 will be the ticket. One of the majors on that project is our own BigEd here on this forum.
I expect visual6502 will be the ticket. One of the majors on that project is our own BigEd here on this forum.
http://WilsonMinesCo.com/ lots of 6502 resources
The "second front page" is http://wilsonminesco.com/links.html .
What's an additional VIA among friends, anyhow?
The "second front page" is http://wilsonminesco.com/links.html .
What's an additional VIA among friends, anyhow?
Re: Good resources to learn how the 6502 works?
in your opinion is this a dumb way to learn how processors work?
Re: Good resources to learn how the 6502 works?
If you can read verilog, I think it will be easier to understand my core https://github.com/Arlet/verilog-6502 than to understand visual6502. Even if you don't know verilog, it's probably still easier to understand. 
Of course, there's a big difference between my project and a real 6502 in terms of all the details, but they also have a lot in common, and I've tried to stay reasonably close to the 6502 design whenever it was possible.
Of course, there's a big difference between my project and a real 6502 in terms of all the details, but they also have a lot in common, and I've tried to stay reasonably close to the 6502 design whenever it was possible.
- GARTHWILSON
- Forum Moderator
- Posts: 8773
- Joined: 30 Aug 2002
- Location: Southern California
- Contact:
Re: Good resources to learn how the 6502 works?
gnawzie wrote:
in your opinion is this a dumb way to learn how processors work?
http://WilsonMinesCo.com/ lots of 6502 resources
The "second front page" is http://wilsonminesco.com/links.html .
What's an additional VIA among friends, anyhow?
The "second front page" is http://wilsonminesco.com/links.html .
What's an additional VIA among friends, anyhow?
Re: Good resources to learn how the 6502 works?
Hi gnawzie, and welcome!
If you really want to understand the internals of the 6502, see first Donald Hanson's block diagram, and then Michael Stiel's presentation on 6502, informed by the visual6502 work: Reverse Engineering the MOS 6502 CPU [27C3]
We've put various resources and links into the visual6502 wiki, so explore that too.
Building a CPU using a very wide microcode implemented with ROMs is certainly feasible, and you'll learn a lot from it. But an exact copy of the 6502 isn't necessarily best, because you copy some complex and incidental decisions made by the original MOS design team.
It's probably worth looking at the design or implementation of other minimal or simple CPUs. Some resources:
- Bruce Jacob's RiSC-16: http://www.eng.umd.edu/~blj/RiSC/
- Steve Chamberlin's Tiny CPU: http://www.bigmessowires.com/cpu-in-a-cpld/
- Dieter Mueller's no6502: http://www.6502.org/users/dieter/m02/m02.htm
- Ruud Baltissen's ttl6502: http://www.baltissen.org/newhtm/ttl6502.htm
(My point here is not "this has all been done before" but more "here are some ways this kind of project can be tackled")
Arlet has a point: many implementations these days are inside programmable logic chips, so learning to read (and eventually write) Verilog will open up more possibilities. But I do think a detailed block diagram is also an asset: it's the way my brain works, at least. If you can do a paper design, there are then several ways to implement it.
A big advantage of Verilog (or VHDL) is that you can write it and then simulate it - you don't need to build hardware to see whether your ideas are heading the right direction. In a simulation you can trace any signal and even print out values, to debug your ideas. All the tools are free, or no-cost.
But it's also true that you can tie yourself in knots in Verilog (probably you can do the same on a breadboard!) so having clear diagrams is always going to help. In Verilog you must stick to a small set of idioms to get reliable results: it's not a chip design language but a general purpose simulator-building language, and you don't want or need that generality.
Cheers
Ed
If you really want to understand the internals of the 6502, see first Donald Hanson's block diagram, and then Michael Stiel's presentation on 6502, informed by the visual6502 work: Reverse Engineering the MOS 6502 CPU [27C3]
We've put various resources and links into the visual6502 wiki, so explore that too.
Building a CPU using a very wide microcode implemented with ROMs is certainly feasible, and you'll learn a lot from it. But an exact copy of the 6502 isn't necessarily best, because you copy some complex and incidental decisions made by the original MOS design team.
It's probably worth looking at the design or implementation of other minimal or simple CPUs. Some resources:
- Bruce Jacob's RiSC-16: http://www.eng.umd.edu/~blj/RiSC/
- Steve Chamberlin's Tiny CPU: http://www.bigmessowires.com/cpu-in-a-cpld/
- Dieter Mueller's no6502: http://www.6502.org/users/dieter/m02/m02.htm
- Ruud Baltissen's ttl6502: http://www.baltissen.org/newhtm/ttl6502.htm
(My point here is not "this has all been done before" but more "here are some ways this kind of project can be tackled")
Arlet has a point: many implementations these days are inside programmable logic chips, so learning to read (and eventually write) Verilog will open up more possibilities. But I do think a detailed block diagram is also an asset: it's the way my brain works, at least. If you can do a paper design, there are then several ways to implement it.
A big advantage of Verilog (or VHDL) is that you can write it and then simulate it - you don't need to build hardware to see whether your ideas are heading the right direction. In a simulation you can trace any signal and even print out values, to debug your ideas. All the tools are free, or no-cost.
But it's also true that you can tie yourself in knots in Verilog (probably you can do the same on a breadboard!) so having clear diagrams is always going to help. In Verilog you must stick to a small set of idioms to get reliable results: it's not a chip design language but a general purpose simulator-building language, and you don't want or need that generality.
Cheers
Ed
Last edited by BigEd on Mon Oct 28, 2013 10:18 am, edited 1 time in total.
Re: Good resources to learn how the 6502 works?
BigEd wrote:
But an exact copy of the 6502 isn't necessarily best, because you copy some complex and incidental decisions made by the original MOS design team.
Quote:
A big advantage of Verilog (or VHDL) is that you can write it and then simulate it - you don't need to build hardware to see whether your ideas are heading the right direction. In a simulation you can trace any signal and even print out values, to debug your ideas. All the tools are free, or no-cost.