Now that I have tested my 6502 and having a basic knowledge of what's going on, I want to start adding some memory. I would like start with a ROM(EEPROM) for now coz' I don't have any RAM yet. I have a Winbond W27c512 EEPROM that i would like to start with. So the address pins of the W27c512 (A0..A15) goes to the address bus pins of the 6502 and the same with the data pins, correct? What about the OE and CE? I'm guesing they should held low? If so, why?
So while I experiment with just a ROM I would like to know any recommended RAM I should buy? 16k or 32k I guess.
The 6502 datasheet says it can address a total of 65k of memory which I don't understand quite well yet. When it says 65k memory, does it mean 65k for just ROM and I can add say a 16k or 32K RAM too? Or a total for both like for example 32k ROM + 32k RAM? Or 32k ROM + 16k RAM + other inputs = 65k?
RAM and ROM for 6502
- GARTHWILSON
- Forum Moderator
- Posts: 8775
- Joined: 30 Aug 2002
- Location: Southern California
- Contact:
Re: RAM and ROM for 6502
M0001 wrote:
I have a Winbond W27c512 EEPROM
The 27's are EPROM. 28's are EEPROMs.
Quote:
So the address pins of the W27c512 (A0..A15) goes to the address bus pins of the 6502 and the same with the data pins, correct? What about the OE and CE? I'm guesing they should held low? If so, why?
They have to be low to output data; but if you hold them low all the time, nothing else will be able to put data on the bus without bus contention. You don't want that. Again, see the 6502 primer, particularly the address-decoding page (and the first diagram since you're interested in 32KB of ROM) and the whole-computer circuit at the top of the circuit potpourri page.
Data lines will be connected straight across. It's mostly the same story with the address lines, except that A15 will have nowhere to go on the ROM, since a 32KB ROM only has 15, not 16, address lines. A15 will be used to select the ROM. See the diagram at the top of the circuit potpourri page. When you get to the SRAM, address lines can be scrambled, and data lines can be scrambled, if it makes routing a PC board easier.
Quote:
The 6502 datasheet says it can address a total of 65k of memory which I don't understand quite well yet. When it says 65k memory, does it mean 65k for just ROM and I can add say a 16k or 32K RAM too? Or a total for both like for example 32k ROM + 32k RAM? Or 32k ROM + 16k RAM + other inputs = 65k?
65,536 (64K) locations altogether, including RAM, ROM, and I/O; so if you have 32KB of ROM and 16KB of RAM, that leaves 16KB for I/O—not that you need that much for I/O but it makes the address decoding really simple and nothing has more than two gate delays. The diagrams linked above give a very simple way to get 32KB of ROM, 16KB of RAM, and up to ten I/O ICs, using only a single quad NAND gate for glue.
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: RAM and ROM for 6502
Thank you!
What about just the ROM for now? The one i have is 64k(w27c512) with address pins A0 to A15. So is it a straight connections to the 6502 including the A15? Do i still need some decoding if im just going to use just a ROM?
What about just the ROM for now? The one i have is 64k(w27c512) with address pins A0 to A15. So is it a straight connections to the 6502 including the A15? Do i still need some decoding if im just going to use just a ROM?
// tinkerBOY
- GARTHWILSON
- Forum Moderator
- Posts: 8775
- Joined: 30 Aug 2002
- Location: Southern California
- Contact:
Re: RAM and ROM for 6502
You could put just a ROM on there, filling all 64K, but with no RAM, you can't have any subroutines or variables, and with no I/O...well, that wouldn't be a very interesting computer.
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: RAM and ROM for 6502
GARTHWILSON wrote:
You could put just a ROM on there, filling all 64K, but with no RAM, you can't have any subroutines or variables, and with no I/O...well, that wouldn't be a very interesting computer.
// tinkerBOY
- GARTHWILSON
- Forum Moderator
- Posts: 8775
- Joined: 30 Aug 2002
- Location: Southern California
- Contact:
Re: RAM and ROM for 6502
M0001 wrote:
So any parts recommended for a RAM or even an EEPROM?
It looks like the only 32KB EEPROM Mouser has in a DIP is this one. Zowee. Neither cheap, nor very fast either! (I've only used EPROMs not EEPROMs, and never paid nearly that much. I guess if you don't want to use a UV eraser, and you want to program it in-circuit, you pay a lot for each part.) For 5V 32KB SRAMs in DIP, they have these. I can't take the time to look at all the data sheets, but I suspect any of them would work. I've used the 62256 type. The 62256, 27c256 and 28c256 varieties are what are shown in the diagram in the circuit potpourri page.
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: RAM and ROM for 6502
My RC6502 Apple 1 Replica uses an Amtel AT28C256 for ROM and Hitachi HM62256BLP-7 for RAM, and works nicely. These are both pretty common parts used throughout the hobbiest community, with many non-official sources as well (although you need to be alert for used, possibly not tested, and possibly remarked chips from China, I suppose).
These can be had for closer to a tenth that price (often even with free shipping) from many vendors on AliExpress. With the usual "buyer-beware" warnings, of course.
On Ebay and the like there are also plenty of sellers of packages of various chips that include RAM and ROM; much of the RAM and ROM in my parts bin has come from those. (For example, I saw a good deal on a 68008 that I wanted to try out, and the seller had packaged it with enough other stuff for a full computer, sans decoding logic.) The RAM chips I currently have in my parts bin (mostly untested so far), include:
(The chips just seem to collect, like socks in a laundry room! :-))
GARTHWILSON wrote:
It looks like the only 32KB EEPROM Mouser has in a DIP is this one. Zowee. Neither cheap, nor very fast either!
On Ebay and the like there are also plenty of sellers of packages of various chips that include RAM and ROM; much of the RAM and ROM in my parts bin has come from those. (For example, I saw a good deal on a 68008 that I wanted to try out, and the seller had packaged it with enough other stuff for a full computer, sans decoding logic.) The RAM chips I currently have in my parts bin (mostly untested so far), include:
Code: Select all
Qt Item Desc
-----------------------------------------------------------------
2 TC551001CP-70L Toshiba 128k×8 static RAM
4 W24512AK-10 64K×8 CMOS static RAM DIP-32N
1 W24512AK-15 64K×8 CMOS static RAM DIP-32N
5 HM62256ALP-8 Hitachi 32k×8 CMOS static RAM
7 HM62256ALP-10 Hitachi 32k×8 CMOS static RAM
2 HM6264LP-70 8k×8 static RAM
5 HM6264ALP-10 Hitachi 8k×8 CMOS static RAM
Last edited by cjs on Sun Jan 26, 2020 11:55 am, edited 1 time in total.
Curt J. Sampson - github.com/0cjs
Re: RAM and ROM for 6502
cjs wrote:
My RC6502 Apple 1 Replica uses an Amtel AT28C256 for ROM and Hitachi HM62256BLP-7 for RAM, and works nicely. These are both pretty common parts used throughout the hobbiest community, with many non-official sources as well (although you need to be alert for used, possibly not tested, and possibly remarked chips from China, I suppose).
These can be had for closer to a tenth that price (often even with free shipping) from many vendors on AliExpress. With the usual "buyer-beware" warnings, of course.
On Ebay and the like there are also plenty of sellers of packages of various chips that include RAM and ROM; much of the RAM and ROM in my parts bin has come from those. (For example, I saw a good deal on a 68008 that I wanted to try out, and the seller had packaged it with enough other stuff for a full computer, sans decoding logic.) The RAM chips I currently have in my parts bin (mostly untested so far), include:
(The chips just seems to collect, like socks in a laundry room!
)
GARTHWILSON wrote:
It looks like the only 32KB EEPROM Mouser has in a DIP is this one. Zowee. Neither cheap, nor very fast either!
On Ebay and the like there are also plenty of sellers of packages of various chips that include RAM and ROM; much of the RAM and ROM in my parts bin has come from those. (For example, I saw a good deal on a 68008 that I wanted to try out, and the seller had packaged it with enough other stuff for a full computer, sans decoding logic.) The RAM chips I currently have in my parts bin (mostly untested so far), include:
Code: Select all
Qt Item Desc
-----------------------------------------------------------------
2 TC551001CP-70L Toshiba 128k×8 static RAM
4 W24512AK-10 64K×8 CMOS static RAM DIP-32N
1 W24512AK-15 64K×8 CMOS static RAM DIP-32N
5 HM62256ALP-8 Hitachi 32k×8 CMOS static RAM
7 HM62256ALP-10 Hitachi 32k×8 CMOS static RAM
2 HM6264LP-70 8k×8 static RAM
5 HM6264ALP-10 Hitachi 8k×8 CMOS static RAM
// tinkerBOY
- BigDumbDinosaur
- Posts: 9428
- Joined: 28 May 2009
- Location: Midwestern USA (JB Pritzker’s dystopia)
- Contact:
Re: RAM and ROM for 6502
M0001 wrote:
So any parts recommended for a RAM or even an EEPROM?
Realistically, any computer without RAM and I/O is all but useless. In the case of the 65C02, there are two "must have" areas of RAM if any reasonable program is to be executed: page zero and page one. Many instructions have zero page addressing modes and some instructions are 100 percent dependent on page zero access to work, e.g., LDA (<addr>),Y.
Page one is important because the 65C02's stack is "hard-wired" to that range of addresses. The stack pointer is an eight-bit register, which means you cannot point at any address outside the range $0100-$01FF.
As for ROM, a 32KB EPROM (27C256) or EEPROM (28C256) is way more that enough. You can cram a lot of code and/or data into a ROM that size. In reality, you probably will use a fraction of that space and could get by with something smaller.
Unfortunately, sources for parallel interface E(E)PROMs are dwindling and prices are increasing. My long-time go-to EPROM was the 27C256-55, which has vanished from first tier distribution. One second tier distributor quoted me 13 dollars each on them—I bought quite a few from Jameco a few years ago for about four dollars each.
x86? We ain't got no x86. We don't NEED no stinking x86!