Ideas for bank switching

Building your first 6502-based project? We'll help you get started here.
User avatar
cbmeeks
Posts: 1254
Joined: 17 Aug 2005
Location: Soddy-Daisy, TN USA
Contact:

Re: Ideas for bank switching

Post by cbmeeks »

Quote:
That doesn't make any sense to me. The 65C816 is a phone call or mouse-click away, same as any other item that Mouser et al stocks.
As of this moment, they don't have any in stock. Other than the PLCC-44 version which I can't work with at the moment.

Where else can I buy one in the US (other than eBay)?


**EDIT**

I guess I could get a PLCC-44 to DIP converter and go that route. But I already have 65c02's on hand. :-)
Cat; the other white meat.
User avatar
GARTHWILSON
Forum Moderator
Posts: 8773
Joined: 30 Aug 2002
Location: Southern California
Contact:

Re: Ideas for bank switching

Post by GARTHWILSON »

cbmeeks wrote:
Where else can I buy one in the US (other than eBay)?
The only place I've bought them is from WDC itself. I called with credit card in hand, was off in a few minutes, and the parts showed up at my door a couple of days later.
Quote:
I guess I could get a PLCC-44 to DIP converter and go that route.
You don't even need to do that. Besides the common thru-hole soldertail PLCC sockets, there are wire-wrap ones available too (although the latter are quite expensive). See http://uk.rs-online.com/web/c/connector ... LCC+socket .
Image

Image

Note that these don't take any more board space than the PLCC sockets found on commercially made boards. Others here on the forum have come up with other ways to do the same thing with a little more work to save a lot of money. Jeff is one that comes to mind. Hopefully he will give a link to where he has posted pictures.
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?
User avatar
cbmeeks
Posts: 1254
Joined: 17 Aug 2005
Location: Soddy-Daisy, TN USA
Contact:

Re: Ideas for bank switching

Post by cbmeeks »

Oh yeah. Forgot that I can buy from WDC directly. So used to dealing with Mouser.

I'd love to get into wire wrapping. But I don't have any wire wrapping tools.

Plus, I read more and more on how people aren't doing wire wrapping any more. Seems to me it should still be a popular method for getting more permanent circuits built. I guess the PCB houses are getting cheaper and cheaper these days.
Cat; the other white meat.
User avatar
GARTHWILSON
Forum Moderator
Posts: 8773
Joined: 30 Aug 2002
Location: Southern California
Contact:

Re: Ideas for bank switching

Post by GARTHWILSON »

Part of the 6502 primer: "Answering Wire-Wrap (WW) Questions and Doubts" http://wilsonminesco.com/6502primer/WireWrap.html
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?
User avatar
cbmeeks
Posts: 1254
Joined: 17 Aug 2005
Location: Soddy-Daisy, TN USA
Contact:

Re: Ideas for bank switching

Post by cbmeeks »

HA!

I've been reading the primer as we speak. :-D
Cat; the other white meat.
User avatar
Dr Jefyll
Posts: 3525
Joined: 11 Dec 2009
Location: Ontario, Canada
Contact:

Re: Ideas for bank switching

Post by Dr Jefyll »

Here is a post detailing the PLCC-to-wirewrap solution that Garth mentioned. Actually two different but similar solutions -- "Plan A" and "Plan B"

"Plan C" is for SOIC's, but could be adapted to PLCC.

J. :)
In 1988 my 65C02 got six new registers and 44 new full-speed instructions!
https://laughtonelectronics.com/Arcana/ ... mmary.html
User avatar
Arlet
Posts: 2353
Joined: 16 Nov 2010
Location: Gouda, The Netherlands
Contact:

Re: Ideas for bank switching

Post by Arlet »

Quote:
Oh yeah. Forgot that I can buy from WDC directly.
According to their web site, they've stopped doing direct business, and are now referring people to the regular distributors instead.
Quote:
To enhance the support of our distributors, we are discontinuing our Online Order Form. All new customer purchase and/or sample requests should be directed to one of our Distributors. Most distributors offer product information and support. WDC will still continue to host all product documentation and provide technical support.
See: http://www.westerndesigncenter.com/wdc/HowToOrder.cfm
User avatar
GARTHWILSON
Forum Moderator
Posts: 8773
Joined: 30 Aug 2002
Location: Southern California
Contact:

Re: Ideas for bank switching

Post by GARTHWILSON »

If none of the distributors have something in stock though, and if they won't even sell any of the PQFP packages to distributors, I'd call them up and point out the nonsense in what they are saying.
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?
User avatar
jac_goudsmit
Posts: 229
Joined: 23 Jun 2011
Location: Rancho Cucamonga, California
Contact:

Re: Ideas for bank switching

Post by jac_goudsmit »

cbmeeks wrote:
Wait. You're right. It's 40ns.

However, there is a way using counters to achieve 12.5 ns per instruction at 80 MHz. I can't remember how but I know I've read it several times.

I will have to look into that again.
On the Propeller you can sample the pins at 1 sample per clock by running 4 cogs that are each 1 cycle out of phase of each other.

It's probably not too hard to program a Propeller to function as an address decoder for bank switching, however you can't make it as fast as that: your program has to read the address bus of the 65C02 and generate an address for the memory chip or module, and if you use the trick mentioned above, the cogs will interfere with each other when they put the address on the output pins.

The fastest way to implement an address decoder with a Propeller would probably read the value from INA and modify a JMP or JMPRET instruction accordingly. The JMP instruction then jumps to a few instructions that store a value onto OUTA and return to the main loop to wait for the next clock pulse. Based on my experiences with Propeddle and L-Star I reckon you can probably get this to work at some clock rate between 1 and 2 MHz depending on whether you want to store the table in the hub or not.

Another problem is that if your circuit only has one Propeller, you're going to run out of pins really quickly. My L-Star project uses all pins of the Propeller and uses monochrome video using the 1-pin video driver. It's possible to free up one additional pin (for bank switching a 128K chip perhaps) by using the 1-pin keyboard driver instead of the 2-pin standard PS/2 driver, but then the user has to press the space bar after a reset, and the keyboard lights won't work.

The bottom line is that bank switching (in a world where you are using a Propeller to bitbang a 6502) will probably require an extra chip, and if that chip only has to do bank switching, it probably makes more sense to find a different solution than a Propeller for that.

===Jac
User avatar
cbmeeks
Posts: 1254
Joined: 17 Aug 2005
Location: Soddy-Daisy, TN USA
Contact:

Re: Ideas for bank switching

Post by cbmeeks »

More than likely, I will be using 2-3 Propellers for my design. But not explicitly for address decoding or glue logic.

I still think a 65C02 running at 2MHz is a nice machine so I would be more than happy to hit that target. In fact, some other designs I want to build using the *cough* *cough* Z80, would run at a maximum speed of 4 MHz. So, I'm not trying to build anything massive.

After I build a few 8 bit machines, I want to tackle either a 16 bit or maybe 32 bit machine. But by that time, I will be using FPGA (which I'm learning) with maybe a Propeller as the main CPU (or ATMEGA) or maybe even a 68K running as a softcore. Lots to learn and do.

But my first computer is going to be pretty simple. I will more than likely use some discrete logic for memory decoding and 2-3 Propellers for video, audio and I/O.

Also, I've been trying to crunch some numbers. Nothing concrete. But I plan on running the Propellers with a 6.25 MHz crystal which gives you 100 MHz. Four clocks per instruction (minimum) yields 25 MIPS. Or, 40ns per instruction.

65C02 running at 2 MHz is 500ns per cycle....250ns per half cycle. So, in theory, that gives me a maximum of 6 Propeller instructions per half-cycle. With real life being probably 2-4 instructions. So, not much can be done other than clocking a shift register, etc. So, I get it now.

I mean, you would think 100MHz microcontroller could handle a measly 2MHz 6502.... :-D

But at least I understand why it can't for many things. Not without devoting several COGS to get parallelism. But like you said, if I were to do that, might as well use discrete logic.

Lessons learned. :-)
Cat; the other white meat.
User avatar
cbmeeks
Posts: 1254
Joined: 17 Aug 2005
Location: Soddy-Daisy, TN USA
Contact:

Re: Ideas for bank switching

Post by cbmeeks »

FYI,

I didn't notice that Mouser tells you an estimated delivery date for out of stock parts.

Looks like the W65C816S6PG-14 is expected to be in stock on the 21st of this month! (Monday).

Hope that's true. I might go ahead and buy a couple just to have.
Cat; the other white meat.
User avatar
BigDumbDinosaur
Posts: 9425
Joined: 28 May 2009
Location: Midwestern USA (JB Pritzker’s dystopia)
Contact:

Re: Ideas for bank switching

Post by BigDumbDinosaur »

cbmeeks wrote:
FYI,

I didn't notice that Mouser tells you an estimated delivery date for out of stock parts.

Looks like the W65C816S6PG-14 is expected to be in stock on the 21st of this month! (Monday).

Hope that's true. I might go ahead and buy a couple just to have.
You can place the order and they will ship when they have inventory. If you wait until they have inventory before ordering you may discover that everyone else beat you to them. :cry:
x86?  We ain't got no x86.  We don't NEED no stinking x86!
User avatar
cbmeeks
Posts: 1254
Joined: 17 Aug 2005
Location: Soddy-Daisy, TN USA
Contact:

Re: Ideas for bank switching

Post by cbmeeks »

BigDumbDinosaur wrote:
You can place the order and they will ship when they have inventory. If you wait until they have inventory before ordering you may discover that everyone else beat you to them. :cry:
Already way ahead of you. Got two coming soon. :-)
Cat; the other white meat.
Post Reply