6502.org Forum  Projects  Code  Documents  Tools  Forum
It is currently Sun Nov 24, 2024 9:00 am

All times are UTC




Post new topic Reply to topic  [ 17 posts ]  Go to page 1, 2  Next
Author Message
PostPosted: Tue Jan 25, 2022 12:07 am 
Offline
User avatar

Joined: Sun Sep 08, 2013 10:24 am
Posts: 740
Location: A missile silo somewhere under southern England
Hi guys

Can anyone who has experience designing for the 65816 know the realistic maximum number of devics (TTL/CMOS load) you can have being driven by the address bus and various control signals such as RWB? (data bus wise, it would be down to the buffer/PLD (in my case the ATF1508).

In my upcoming design I've possibly gone a bit overboard (using Kicad so more PCB room!) with : 4x VIAs, 1x SC28L92 (serial), 2xSRAM ICs, 4 Flash ROM ICs (one is the OSROM, 3 paged ROMs), 3 PCI-type edge connector slots (the PCI slots have address, data bus, RESB, NMIB, RWB, PHI2, PHI1, amongst other signals)
I'm thinking I might have to buffer the PCI slots given they go offboard and I plan to implement a graphics card using one of them.


Top
 Profile  
Reply with quote  
PostPosted: Tue Jan 25, 2022 1:25 am 
Offline
User avatar

Joined: Fri Aug 30, 2002 1:09 am
Posts: 8546
Location: Southern California
From the 6502 primer:

    I have done some brief tests on the W65C816S's pin drivers. Their behavior was pretty much symmetrical, able to pull up just as hard as they can pull down, unlike TTL which cannot pull up as hard. If you had to boil my test results down to approximations and treat the circuits as just a resistance, the data pin drivers acted very roughly like a SPDT switch with 50Ω in series with the common terminal (ie, the output); and the address bus pins, as a SPDT switch with 60Ω in series. I have not had the chance to test a W65C02S; but I suspect WDC used the same circuits on the '02 and the '816, which would make it much stronger than the data sheet says. The time constant of 60Ω times the capacitive load of 10 CMOS loads is around 3ns, which is less added delay than you'll get from a bus transceiver IC. Daryl Rictor had no trouble running my 4Mx8 5V 10ns SRAM module on his SBC-4 single-board computer at 12MHz with a barefoot '816 (ie, no bus transceivers), driving this module and three daughter boards at the same time. The module has 8 bussed SRAM ICs.

_________________
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?


Top
 Profile  
Reply with quote  
PostPosted: Tue Jan 25, 2022 2:00 am 
Offline
User avatar

Joined: Thu May 28, 2009 9:46 pm
Posts: 8514
Location: Midwestern USA
On my POC V1.3 unit, I've got two DUARTs (28L92), DUART channel status buffer, RTC, EPROM, RAM and the SCSI host adapter all hanging off the data bus. All of these items, except the channel status buffer, are also attached to the address bus, along with various parts of the glue logic. Also, the SCSI host adapter takes the buses off-board. This mess is running fine at 16 MHz, BTW.

GARTHWILSON wrote:
The time constant of 60Ω times the capacitive load of 10 CMOS loads is around 3ns, which is less added delay than you'll get from a bus transceiver IC.

With the 65C816, the data bus transceiver’s main value is in eliminating potential contention right at the point where the 816 “turns around” the data bus. The slight amount of time it takes for the transceiver to start conducting after Ø2 goes high is actually beneficial. The stronger drive of the transceiver probably isn't contributing much to the system's performance, but won't hurt if the buses are going off-board.

_________________
x86?  We ain't got no x86.  We don't NEED no stinking x86!


Top
 Profile  
Reply with quote  
PostPosted: Tue Jan 25, 2022 2:48 am 
Offline
User avatar

Joined: Fri Dec 11, 2009 3:50 pm
Posts: 3367
Location: Ontario, Canada
banedon wrote:
In my upcoming design I've possibly gone a bit overboard
I hope your upcoming design uses an '816 that's in a PLCC or Quad-pack package -- not a 40-pin DIP. That's because driving the capacitance of a heavily-populated bus results in substantial current spikes in the Gnd and Vcc pins of the CPU. It's to your advantage if (as with PLCC and Flat-pack) there are multiple Gnd pins and multiple Vcc pins to help carry these spikes without creating too much of a voltage drop.

-- Jeff

_________________
In 1988 my 65C02 got six new registers and 44 new full-speed instructions!
https://laughtonelectronics.com/Arcana/ ... mmary.html


Top
 Profile  
Reply with quote  
PostPosted: Tue Jan 25, 2022 10:05 am 
Offline
User avatar

Joined: Sun Sep 08, 2013 10:24 am
Posts: 740
Location: A missile silo somewhere under southern England
Thanks for your replies and that all sounds positive. I just need to see if the ATF1508 behaves under such load. My suspicon is yes, but we'll see. I also forgot to include the RTC DIP IC.

Jeff: I can certainly move the 65816 across to PLCC (currently DIP), but I was hoping to avoid it as I have begun hating routing PLCC :lol:, but on balance I'd rather do the routing and it actually work.

With the rest of the devices (if it matters at all): Due to programmer constraints (the PLCC adapters (scroll dopwn) are £100+ a pop) I'm having to stick with DIP for the OS & paged flash roms. Also the two SRAM ICs & RTC are DIP as those are what I have 'in stock'. Total: 8 devices.
PLCC-wise: The SC28L92 and the VIAs are all PLCC: 5 devices. Will add the 65816 to that as well as you recommend.


Top
 Profile  
Reply with quote  
PostPosted: Tue Jan 25, 2022 3:08 pm 
Offline
User avatar

Joined: Fri Dec 11, 2009 3:50 pm
Posts: 3367
Location: Ontario, Canada
banedon wrote:
With the rest of the devices [...] I'm having to stick with DIP
That should be alright. The CPU is the chip that's most critical because it has far more output pins to drive. (At the start of every cycle, all 16 address lines may simultaneously change, and all the "data" bus pins, too, since they output the Bank Address at this time. Also we have RWB and some others that may change.)

Quote:
I'm thinking I might have to buffer the PCI slots given they go offboard and I plan to implement a graphics card using one of them
I wouldn't worry about buffering, but I'd strongly recommend you make provision for series termination -- definitely for the Phi2 signal, and preferably for all the other signals, too.

By "make provision for" I mean providing a site where a resistor or resistor array can be installed, in a socket, perhaps. You can start with zero ohms or some other negligible value. But probably your 'scope will reveal less ringing if you up the value to 50 or 100 ohms (the best value to be determined by experimentation).

Series termination means the resistor will appear at the source end -- on the motherboard, not on the plug-in card that receives the signals. Hopefully you'll post a proposed schematic, and we can deal with the details then. :)

-- Jeff

_________________
In 1988 my 65C02 got six new registers and 44 new full-speed instructions!
https://laughtonelectronics.com/Arcana/ ... mmary.html


Top
 Profile  
Reply with quote  
PostPosted: Tue Jan 25, 2022 11:08 pm 
Offline
User avatar

Joined: Sun Sep 08, 2013 10:24 am
Posts: 740
Location: A missile silo somewhere under southern England
The design is spread out amongst a ton of Kicad sheets. I usually do the all-in-one page approach, but the consensus seems against that from what I've read online. This means I can't just post one schematic, but I'll get what I have so far posted a bit later. Just keep in mind it's not competed, particularly the glue logic as I need to finish the design of the CPLD logic, let it assign most of the non-clock pins and then reflect that in the schematic.

BDD recommended a while back putting a 100-200 (ish) ohm resistor as close to the PHI1 and PHI2 D-flipflops as possible to deal with ringing. I think this is what you're referring to with regards terminating? So it goes: oscillator > d-flipflop > resistor as close to output as possible > the rest of the circuit.
If this is the case then I'd probably put resistor networks (in-line, not bussed to VCC) on all address bus and data bus pins in the same manner. I know you said it really only affects the MPU, but would the ATF1508 CPLD possibly suffer from this as well given that it pretty much deals with all device selects, IRQs, NMIs, produces WD & RD, inverts RESB, and latches out the data bus?


Top
 Profile  
Reply with quote  
PostPosted: Tue Jan 25, 2022 11:18 pm 
Offline
User avatar

Joined: Fri Aug 30, 2002 1:09 am
Posts: 8546
Location: Southern California
banedon wrote:
The design is spread out amongst a ton of Kicad sheets. I usually do the all-in-one page approach, but the consensus seems against that from what I've read online.

Where did you read that? I find it much more difficult when we have to follow tags from one page to another, especially if there's no indication of where to find the matching tag. (I will add however that it's possible to arrange things in such a way so as to minimize the tagging.)

_________________
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?


Top
 Profile  
Reply with quote  
PostPosted: Wed Jan 26, 2022 12:24 am 
Offline
User avatar

Joined: Sun Sep 08, 2013 10:24 am
Posts: 740
Location: A missile silo somewhere under southern England
GARTHWILSON wrote:
banedon wrote:
The design is spread out amongst a ton of Kicad sheets. I usually do the all-in-one page approach, but the consensus seems against that from what I've read online.

Where did you read that? I find it much more difficult when we have to follow tags from one page to another, especially if there's no indication of where to find the matching tag. (I will add however that it's possible to arrange things in such a way so as to minimize the tagging.)

Not entirely sure. I think it was when I was watching a batch of Kicad videos (so more watched/listened than read) a while back.
I agree with you, but as I'm a hobbyist (at best!) I thought that was just me so was going with the *seeming* proper method.


Top
 Profile  
Reply with quote  
PostPosted: Wed Jan 26, 2022 12:36 am 
Offline
User avatar

Joined: Sun Sep 08, 2013 10:24 am
Posts: 740
Location: A missile silo somewhere under southern England
Here are the schematics. I've not included the VIAs or the glue logic CPLD because they aren't finished (the CPLD exists as a device on the sheet as I'm still working on the PLD/JED design so the pinout is not finalised). If you don't want to look through this lot then let me know and I'll put them all on one sheet.

Note that the Flash ROMs and RTC are 70ns parts so will be accessed with PHI2 stretched, where-as the other devices (includng the VIAs) will be accessed at full speed. The VIAs will be hooked up to the GC (global clock) rather than PHI2 to prevent slow down on their internal counters. Click stretching is determined by the CPLD uisng the /WSE signal.

Final note: The design isn't at all finished and something are likely to change. The clock generation, mpu/ram/rom/rtc/pci slows are mostly set, but power, serial (mostly the GPI and GPO pin usage) VIA ouput ports and CPLD glue logic are still under consideration.

Core MPU, OSROM, RAM, RTC:
Attachment:
65C816SA-MPU, RAM, ROM.pdf [99.82 KiB]
Downloaded 50 times

Clock Generation:
Attachment:
65C816SA-Clock Generation.pdf [74.74 KiB]
Downloaded 47 times

Core signals:
Attachment:
65C816SA-Core Signals.pdf [53.63 KiB]
Downloaded 44 times

PCI bus I/O:
Attachment:
65C816SA-Bus & IO ports.pdf [75.39 KiB]
Downloaded 46 times

Power:
Attachment:
65C816SA-Power.pdf [41.72 KiB]
Downloaded 40 times

Serial:
Attachment:
65C816SA-Serial.pdf [74.89 KiB]
Downloaded 43 times


Last edited by banedon on Wed Jan 26, 2022 12:46 am, edited 1 time in total.

Top
 Profile  
Reply with quote  
PostPosted: Wed Jan 26, 2022 12:46 am 
Offline
User avatar

Joined: Fri Dec 11, 2009 3:50 pm
Posts: 3367
Location: Ontario, Canada
banedon wrote:
I'd probably put resistor networks (in-line, not bussed to VCC) on all address bus and data bus pins in the same manner.
Yes, in-line. IOW, in series. There is also such a thing as parallel termination, where a node gets attached to the junction between a resistor to ground and a resistor to Vcc. I won't try to say why that's more appropriate in some situations and less so in others. But series termination is easy and can help a lot, and that's why I suggest it.

Locate the resistor reasonably close to the signal source, be it the CPU, a flip flop, or whatever. And 100-200 (ish) ohms sounds high to me, although it'll depend on circumstances. I'd be more inclined to start with 50 ohms or so. If you socket the resistor arrays then you can try different values and see how things look on the scope.

It's somewhat of a judgment call. More ohms is gonna give a visually smoother waveform, but it also increases delay. So you don't wanna go overboard making it look all soft and pretty. For clock lines, at least, you wanna keep the edges crisp, even at the expense of a small amount (say 0.5V p-p) of residual ringing.

Quote:
would the ATF1508 CPLD possibly suffer from this as well
If its outputs have very abrupt rise and fall times like those of WDC CPU's then yes.

I see you've posted some schematics while I was typing. Will have a look at those later... :)

-- Jeff

_________________
In 1988 my 65C02 got six new registers and 44 new full-speed instructions!
https://laughtonelectronics.com/Arcana/ ... mmary.html


Top
 Profile  
Reply with quote  
PostPosted: Wed Jan 26, 2022 3:14 am 
Offline
User avatar

Joined: Thu May 28, 2009 9:46 pm
Posts: 8514
Location: Midwestern USA
banedon wrote:
BDD recommended a while back putting a 100-200 (ish) ohm resistor as close to the PHI1 and PHI2 D-flipflops as possible to deal with ringing. I think this is what you're referring to with regards terminating? So it goes: oscillator > d-flipflop > resistor as close to output as possible > the rest of the circuit.

Jeff answered this...I'll just add that in POC V1.2 there was 120 ohms in series with Ø2. The signal was pretty clean at 20 MHz, with about 0.1 volts P-P ringing, well within the tolerance of WDC parts. V1.3 has 100 ohms and exhibits a signal quality that is very much like that of V1.2, albeit at a lower frequency (16 MHz). In both cases, I used discrete resistors.

This resistor is something you may have to experiment with some to find the best value.

Quote:
...but would the ATF1508 CPLD possibly suffer from this as well...

The two concerns with the CPLD are: 1) its outputs are TTL, not CMOS, and 2) the output slew rate is fast. Regarding item 1), pullups on all pins designated as outputs may be beneficial—it's something I will be evaluating in POC 2.0 when it's done. I'm not sure being TTL levels is a handicap, but I've got a plan B of sorts should it turn out to be a problem.

As for output slew rate, that is controllable with the property atmel {output_fast = off | on }; statement in your PLD file (select off or on, not both). Even if set to off, it's still pretty fast, although not as aggressive as 74AC logic. Something to experiment with if the CPLD's outputs have too much ringing.

_________________
x86?  We ain't got no x86.  We don't NEED no stinking x86!


Top
 Profile  
Reply with quote  
PostPosted: Wed Jan 26, 2022 1:21 pm 
Offline
User avatar

Joined: Sun Sep 08, 2013 10:24 am
Posts: 740
Location: A missile silo somewhere under southern England
Definitely. I set up a breadboard to test the delay circuit we were discussing a while ago and as part of that I also added in some resistors (one leg cut super short on the flipflop side) and compared with and without. Obviously not the same as an entire single board PCB, but I did see a big difference in ringing which is what really sold me on it (there's nothing like seeing something actually working in front of you). As such, definitely going to be included, but I will experiment with values and see what happens.

With regards pull ups:
I've got plans to add 2K2 pull up resistor networks for the ATF1508 CPLD. If I need them I can fit them, if not - I wont :lol: . Interestingly, my existing 6502GPD rev B design doesn't have pulls up and I can see that the digital highs are at TTL voltage level. So far haven't seen any issues apart from the design won't push past 12MHz (discussed in another thread and I'm still looking into it).
Maybe not such a great surprise as the design has the usual WD65C02S CPU & WD65C22S VIAs along with AS6C4008 for RAM, Winbond W27512 EEPROM - all of which are noted as being fine with TTL. Am currently coding something for the SC28L92 so we'll see on that, but from what I read in the data sheet it should be fine as well.

Output slew-wise, I have that disabled in both my existing 6502GPD rev B design (uses ATF1504 7ns and (so far) in my new Blue816 v2 design (i.e. this 65816 one) which will use a ATF1508.
I might try enabling it to see if it helps with the above mentioned speed issues with my 6502GPD...


Top
 Profile  
Reply with quote  
PostPosted: Wed Jan 26, 2022 2:34 pm 
Offline
User avatar

Joined: Thu May 28, 2009 9:46 pm
Posts: 8514
Location: Midwestern USA
banedon wrote:
Output slew-wise, I have that disabled in both my existing 6502GPD rev B design (uses ATF1504 7ns and (so far) in my new Blue816 v2 design (i.e. this 65816 one) which will use a ATF1508.

Which ATF1508 package are you going to use?

_________________
x86?  We ain't got no x86.  We don't NEED no stinking x86!


Top
 Profile  
Reply with quote  
PostPosted: Wed Jan 26, 2022 5:02 pm 
Offline
User avatar

Joined: Sun Sep 08, 2013 10:24 am
Posts: 740
Location: A missile silo somewhere under southern England
ATF1508AS-7JX84 so the 7.5ns version


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 17 posts ]  Go to page 1, 2  Next

All times are UTC


Who is online

Users browsing this forum: Google [Bot] and 61 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to: