Looking to use a CPLD. Which one to go for...? - Page 1
Forum section: electronics / general

author: Tronix
author_rank: Newbie
timestamp: February 05, 2016, 10:37:13 pm
content: Hi,I'm looking to move from using 74xx series logic and GALs to a CPLD, but unsure which family to use.The circuitry I'm looking to replace is all 5v as it'll be connecting to older home computer hardware - a mix of 74xx and 4000 parts and an old CPU + Memory all on shared data/address bus etc.What would be ideal:- 5v operation- PLCC packagingBut I know that 5v can now be quite limiting, the only current series I can see are the ATMEL ATF15xx which are still produced in 5v parts, with 44 and 84pin PLCC parts (32/64/128 macrocells).On paper, they sound ideal, however, from reading their website, news and these forums...- The ATMEL range is not recommended- Their software for developing CPLD is limited to using the CUPL language for designing, unless a two year license is purchased to use VHDL/Verilog.- With Microchip about to buy up ATMEL who knows how long the parts will be produced.The Xilinx range XC95xx seem to be very popular, but with the 5v range now discontinued moving 3v3 is the only option. Although with 5v tolerant inputs it would still require a 3v3 regulator to power the device, and I'm not sure that 3v3 outputs would be sufficient to trigger everything that may possibly be connected to the shared buses (as it is old legacy hardware it would be connected to).Thanks in advance for any advice.

author: nctnico
author_rank: Super Contributor
timestamp: February 05, 2016, 11:20:22 pm
content: You can try and push the XC95 series to run on 3.6V. That may just tip the balance into being compatible with 99% of the 5V systems.

author: uncle_bob
author_rank: Unknown
timestamp: February 06, 2016, 01:53:15 am
content: HiFive volt supplies went out of favor on CPLD / FPGA type parts in the mid 90's. Most of them went out of production by about 2005.Xylinx and Altera are are the top two guys in the CPLD / FPGA arena. I happen to be an Altera guy, a LOT of people use those other people. Depending on how you measure (surprise, they each look at it differently) one or the other is ahead in this or that this month.They each have good free tools to program the parts with. They also have free design tools. Altera will let you do a design with a schematic. I don't know if Xylinx will let you do that or not. Except for Neanderthals, this stuff gets set up with Verilog (or something similar) rather than a schematic. My kid keeps telling me I need to move into the modern age.Both outfits will sell you demo boards with parts on them. That's nice with things like 144 pin package or BGA's involved. There also are an enormous number of guys on eBay that will sell you cheap boards. More or less it's a "grab a board, download software and run" sort of thing. About all you will need is a modern PC and a cheap programming dongle.Bob

author: Bruce Abbott
author_rank: Frequent Contributor
timestamp: February 06, 2016, 06:40:06 am
content: Quote from: Tronix on February 05, 2016, 10:37:13 pmMost 5V parts are out of production and hard to get, but many 5Vtolerantparts are still available - just add a 3.3V regulator.QuoteDon't touch Atmel unless you have the correct programmer for them.Quote3.3V CMOS logic levels are compatible with 5V TTL parts, including old CPUs and memory etc. 5V 4000 series is not TTL compatible, but was rarely used in old home computers for that reason (and because it'sslow). 3.3V is actually an advantage when you want to interface modern peripherals such as SD Cards. Yes, you have to add a 3.3V regulator, but that's not hard.Xilinx XC95xx and Altera EPM30xx series are cheap and easy to use. PLCC versions are getting rare, but adapter boards for TQFP packages are readily available. Lattice might be another possibility (Element14have a few 5V PLCC parts in stock!).

author: obiwanjacobi
author_rank: Super Contributor
timestamp: February 06, 2016, 07:51:09 am
content: I've started recently with the Altera MAX II (3.3V). 100 pin flat pack (0.1 mm pitch)Bought a cheap board on ebay and a blaster (USB programmer) and downloaded the software (big!). The MAX II is still supported by the latest software version (no support for Win10 though).Recently bought a couple MAX II's on ebay - just the chips for $1,38 (US) each - so very cheap. I soldered those on adapter boards to get to 0.1" pin headers.I was also thinking of getting into the older GALs but I could find all the parts: IDE, Programmer etc.

author: Tronix
author_rank: Newbie
timestamp: February 06, 2016, 09:53:38 am
content: Hi,Thanks for the advice so far, appreciated.QuoteI learned that with their GALs... my programmer did not like them so I still use old stock of Lattice GALs.*If* I did go Atmel I'd get their ATF15xx demo kit which has their JTAG programmer. Their parts are also readily available from Digikey etc.QuoteI have done that before, as I have SD cards running in previous projects. But for my new ideas I still cannot fully guarantee everything would be happy at 3.3v.I think the idea may just to pick up a very cheap board with a chip and give it a try... if something like a Xilinx part isn't working reliably then maybe then have to explore the Atmel route with 5v parts...QuoteTQFPs I can handle hand soldering, but I wouldn't go down the route of BGA.

author: Bruce Abbott
author_rank: Frequent Contributor
timestamp: February 06, 2016, 10:24:52 am
content: Quote from: Tronix on February 06, 2016, 09:53:38 amWhat are your new ideas?

author: andre_teprom
author_rank: Regular Contributor
timestamp: February 06, 2016, 10:51:06 am
content: Why don't you simply buy an extremely cheap starter kit instead of assembling yourself the chip at the board ?

author: uncle_bob
author_rank: Unknown
timestamp: February 06, 2016, 03:13:49 pm
content: HiHere's the next "layer" to this decision:These guys very much want you to use the latest and greatest parts. In most areas that would equal "most expensive and crazy to use". In the world of FPGA's and CPLD's ... not so much. Each new generation brings out bigger parts (higher gate count) at lower prices per gate. The result often is that a newer / bigger /faster part is cheaper than an old part.Since they want you to focus on the new stuff, they taylor the support in their free software to the newer parts. The support for the older parts stays with the older software. The software keeps getting (slightly) easer to use and adds features as time goes on.Take a look at the prices of the demo boards / breakout boards. I can get a Max 10 (Altera's latest and greatest) for less than $30 from Arrow (not the cheapest place in the world). The eBay guys have not quite caught up to cheap Max 10 parts (yet), but take a look at Cyclone V, IV, III and II boards. There is a dip in the curve. At some point rather than getting cheaper, as you go back in time, they get more expensive. Once you hit that dip, there isn't any value in going further back.If you are a bit confused by that naming switch, you are not the only one. Altera has essentially turned their CPLD parts into something that directly compares to an FPGA. The why is a bit complex. Mostly it is one of those "because we could" sort of things.Yes, that's all Altera specific. You sort of need to name names to do this sort of comparison. The Spartan series works pretty much the same way cost wise in the Xylinx lineup.(except for the dodge to CPLD right at the end).You might notice that these are *not* the smallest of the small devices. If you are buying boards, the little guys don't save you much ($6 delivered isn't that much less than two for $13 delivered). In some cases they actually are more expensive. The nutty part is that I can't buy the chips in small quantities for the price of the board. It's not a close thing in most cases ....I certainly can not layout a board, populate it with regulators and caps and assemble it at anything close to what the boards cost.What you likely will find (once you get going) is that this stuff is pretty easy. Your ideas will grow at a rapid clip. What looked like a big part last week will be full sometime middle of next week. Bigger is always better ...Bob

author: asgard20032
author_rank: Regular Contributor
timestamp: February 06, 2016, 03:24:50 pm
content: And don`t forget that newer = more low power, also lower power = less need for complicated power design to power up the FPGA. So again, lower cost, smaller regulator.

author: Buriedcode
author_rank: Super Contributor
timestamp: February 06, 2016, 03:49:01 pm
content: As these guys have said, whilst you can still get 'CPLDs', many companies have blurred the lines between these and FPGA's, effectively creating convenient FPGA's, with on-board config memory, oscillators, flash etc.. A good example is the Lattice XO2/3 series.I got 'in' to CPLD's about 16 years ago, back when there were plenty of 32/64/128 macrocell devices in PLCC packages - I still have quite a few MAX7000's (Altera), 9500's (Xilinx), and lattice MACH4A's. Whilst I could probably still use them in some projects, the hassle of finding the older software that supports these, and possible issues getting them to run on windows 7/10 means they just collect dust - and thats a pity. But I'm going to order a XO3 board, which for £20 has more than enough gates for anything I'll need - its almost shocking how powerful/large these devices are on boards that cost far less than the older CPLD boards (that had 32 MC's..). No doubt I'll end up like these guys who use CortexM4's to make a few LED's flash.Back to your needs. The biggest restriction is of course, 5v logic. Yes, the 9500XL from xilinx (I *think* that is still supported) has 5V tolerant IO's, but adding HCT buffer chips to its outputs to get 'true 5v' sort of defeats the point of using a CPLD to replace said 7400. And even though much newer devices can have 3.3V IO (with a separate core voltage much lower) I don't think any are 5v-tolerant, and perhaps, even though you get *much* more logic for the price, using a modern FPGA would be overkill, and for knocking up 'old' computer hardware - it could all be done in the FPGA anyway, which again, maybe defeats the point of building old computer hardware..If this is just for one off's, and you feel you really need a 5V device, I can supply you with a list of chips I have (in the UK here), and try and find the older versions of Altera/Xiliinx/Lattice software that will allow you to configure them. (Pretty sure Altera and Xilinx have ftp servers providing very old versions of their software). Simpler devices such as these also have the advantage that they have a lot less 'options' (IO slew rate, thresholds etc..) that would have to be configured for a modern device. So yes, cost is generally proportional to the age of the device.You could try one of these:http://www.ebay.co.uk/itm/XILINX-XC9572XL-Development-Board-CPLD-Logikgatter-/181974808918?hash=item2a5e8b3956:g:2UQAAOSwCQNWgVfGBut actually programming them can be an arse. Whilst Altera has the Byteblaster - and the many cheap clones around, xilinx programmers tend to be more expensive, unless you have a parallel port on an old PC then you can knock one up pretty quickly. It really is the software/programmer rather than the devices features itself that make the difference.

author: chris_leyson
author_rank: Super Contributor
timestamp: February 06, 2016, 04:32:21 pm
content: Unlike Uncle_Bob who is an Altera guy I'm a Xilinx guy, only because the Altera MAX7000 series I tried years ago had totem pole output drivers and my application needed true complimentary output drivers, I went for Xilinx XC3000 in the end and thats why I'm a Xilinx guy, I don't have enough time to learn a new set of tools so I've stuck with Xilinx ISE, I don't have anything against Altera. Xilinx Coolrunner was bought from Philips in around '99, 3.3V parts but have low power consumption.Xilinx XC95 series, now obsolete, run at 5V and they were available in PLCC package but run quite warm, it was prior to the Philips buy out. Altera MAX7000 series will also run at 5V but have a totem pole output stage, good enough for TTL interfacing. If you can get your hands on XC95 or MAX7000 chips they are a good place to start and still supported by the older software suites. Lattice also have older generation 5V logic but I've never used Lattice in a design so can't make any recomendations.

author: Alex Eisenhut
author_rank: Super Contributor
timestamp: February 06, 2016, 04:41:02 pm
content: Quote from: nctnico on February 05, 2016, 11:20:22 pmI wonder if it is possible to raise the CPLD's ground reference to shift up its logic levels...I know, I'm a rebel.

author: uncle_bob
author_rank: Unknown
timestamp: February 06, 2016, 04:45:28 pm
content: Quote from: Alex Eisenhut on February 06, 2016, 04:41:02 pmHiBeen there, done that. Not a real good idea. You get into all sorts of nasty diode clamp issues. Outputs swing sort of right until you hit a tri-state port. Inputs clamp on both sides, with occasional "interesting" outcomes. (as in you source enough current into the part to take the top or bottom side rail to +5 or to ground).Bob

author: uncle_bob
author_rank: Unknown
timestamp: February 06, 2016, 05:05:20 pm
content: Quote from: Buriedcode on February 06, 2016, 03:49:01 pmHiJust for the sake of completeness (NOT because it's a better board):http://www.ebay.com/itm/EP4CE6-EP4CE6E22C8N-ALTERA-FPGA-Cyclone-IV-Development-Evaluation-Board-Core-Kit-/231074176951?hash=item35cd181fb7:g:D0UAAOSwYIhWjb~KMake offer, so who knows what he'll take. You will have all the usual shipping and VAT issues. Likely outcome > $30 delivered.An *excellent* example of the alternative:https://www.arrow.com/en/products/bemicromax10/arrow-development-tools?utm_source=arrow&utm_medium=npi&utm_content=bemicro_max10&utm_term=buy_now&utm_campaign=bemicro_isOut of stock, can be back ordered. Who knows what that means. Possibly they will never make another batch. $30 before delivery. Not clear what Arrow does to get them to the UK.What do you get in each case?The Arrow board has a much more powerful / newer part on it. It has far more i/o. It has a lot more support chips on the board. It also has a built in programmer. The build quality of the board is excellent. The chip on the board is supported by current software and will be supported for many years to come.The board from eBay *is* cheaper and you have a range of people to buy them from. It requires a programmer ($4 to $8 depending on how picky you are). That can be a plus or a minus. It probably does everything you need it to do. The chip on the board may not be supported a lot longer on the free software. There are interesting little quirks to the board (the FPGA memory IC) that may or may not be a PIA when you go to program it.If you want the board that Arrow (or any of the other guys) make up, you need to buy them when they have them. The boards are targeted at the classes they hold to train customers on the parts. The deal is you come in, get a free lunch, a free board and errr.... pay $99. (so maybe not free ...). Because it's a course board, there are nice "getting started" materials that come with the board. A few years from now, you fry the board and want another one .... probably not going to happen.Regardless of what family you start out with, there are boards like this and choices like this. Starting with the training board does not cost a lot of money. It gets you over a bunch of bumps in the road a lot faster than the eBay board. Take care though, if you head off to a training board that has things like Ethernet and video on it, they run up into the $100 to $200 range pretty fast.Bob

author: Bruce Abbott
author_rank: Frequent Contributor
timestamp: February 06, 2016, 05:34:32 pm
content: Quote from: nctnico on February 05, 2016, 11:20:22 pmWith 99% of old home computers you don't need to raise the voltage. Since TTL only requires 0.8V low to 2.0V high, 3.3V CMOS logic levels are sufficient. The only problem is ensuring that 5Vinputsdon't overdrive the CPLD. Xilinx XC9500XL series are 5V tolerant and don't have clamp diodes to Vio, so you can connect them directly to a TTL compatible 5V CPU bus. Here is an example:-ZX Breakout

author: uncle_bob
author_rank: Unknown
timestamp: February 06, 2016, 05:43:59 pm
content: Quote from: Bruce Abbott on February 06, 2016, 05:34:32 pmHiThe only thing that leaves are Tri-state outputs (like an address or data bus) that have external pull ups to +5V. In that case a weak pull up is not likely to create an issue. If somebody got a bit crazy with values, your 3.3V output (and possibly 3.3V regulator) may not be very happy dealing with the injection current.Bob

author: Gribo
author_rank: Frequent Contributor
timestamp: February 06, 2016, 06:07:11 pm
content: Be careful of fake chips. There are tons of fake EP3000 and EP7000 on EBay and Alibaba. The chip might pass programming, but not all the IO pins will work.

author: uncle_bob
author_rank: Unknown
timestamp: February 06, 2016, 06:31:40 pm
content: Quote from: Gribo on February 06, 2016, 06:07:11 pmHi.... or the chip may not program at all. The same caution applies to just about any part you buy. Tantalum caps are another commonly faked part. Any time a part gets expensive or rare, it becomes worthwhile to fake them.Yet another reason to buy working (or hopefully working) boards rather than bulk parts.Bob

author: nctnico
author_rank: Super Contributor
timestamp: February 06, 2016, 08:03:49 pm
content: Quote from: Bruce Abbott on February 06, 2016, 05:34:32 pmYou are forgetting about chips (ASICs) you may find in older gear which are not exactly TTL compatible then therefore won't work with 3.3V levels. Also CMOS is notorious for not working with 3.3V levels because in CMOS a '1' usually is 0.7*VCC => 5*0.7=3.5V.

author: marcopolo
author_rank: Regular Contributor
timestamp: February 06, 2016, 08:49:51 pm
content: MAX7000: EPM7160LC84 for 1€00 in Germanyhttp://www.ebay.fr/itm/Altera-EPM7160LC84-20-Electrically-Erasable-PLD-Datecode-9413-/231012018626But you need an Altera LP6 board to program them, not easy to find.

author: Bruce Abbott
author_rank: Frequent Contributor
timestamp: February 07, 2016, 03:28:18 am
content: Quote from: nctnico on February 06, 2016, 08:03:49 pmThat's why I said 99%, not 100%. I could be wrong though. Do you know of any old home computers which used ASICs that are not TTL compatible?QuoteApplies only to parts with 'CMOS' 5V logic levels, eg. 4000 series and 74Cxxx. Most 5V CMOS ROM and RAM chips are TTL compatible. Old home computers generally used LS/TTL logic with NMOS CPU and peripheral chips.

author: obiwanjacobi
author_rank: Super Contributor
timestamp: February 07, 2016, 07:31:16 am
content: Before you decide which one it will be, make sure the version of the IDE you need for the part is supported by the OS you're running.Example: I had a Altera Cyclone II board, that only is supported by an older version of the IDE (13.x) and that version only runs on Windows 7 - and I'm on 8 and 10. I have tried it anyway and indeed it did not work (why? I did not put time into that to find out).

author: MT
author_rank: Super Contributor
timestamp: February 07, 2016, 11:38:03 am
content: Quote from: nctnico on February 06, 2016, 08:03:49 pmHe could use 3.6V.

author: nowlan
author_rank: Frequent Contributor
timestamp: February 07, 2016, 12:19:10 pm
content: That arrow page says no stock. Was there an alternative supplier.I only ever looked at de-nano boardsbefore.

author: legacy
author_rank: Super Contributor
timestamp: February 07, 2016, 01:31:37 pm
content: I have the same need for CPLD I need to attach to a 5V bus. I am going to use an oldXC95108CPLD, which comes with 3.3V or 5V I/O capability.the data sheet saysVCC, Supply voltage relative to GND, up to7.0VVIN, Input voltage relative to GND, up to VCC + 0.5VVTS, Voltage applied to 3-state output, up to VCC + 0.5VVCCINT, Supply voltage for internal logic and input buffers, up to 5.25VVCCIOSupply voltage for output drivers for 5V operation, up to 5.5VSupply voltage for output drivers for 3.3V operation, up to 3.6Vwhich sounds that I can put VCC=VIN=VTS=VCCINT=VCCIO=VCC_BUS=5V, right ?

author: legacy
author_rank: Super Contributor
timestamp: February 07, 2016, 01:33:59 pm
content: Quote from: Bruce Abbott on February 06, 2016, 05:34:32 pminteresting

author: uncle_bob
author_rank: Unknown
timestamp: February 07, 2016, 01:35:24 pm
content: Quote from: nowlan on February 07, 2016, 12:19:10 pmHiYup, the cheap Bemicro boards are currently not in stock. They are (as far as I know) a sole source thing from Arrow. Some of their expensive are very similar to or are the same as the Terasic boards. Those show up as De Nano's of various sorts. Some of them are better than others. There are a lot of sources for Terasic boards.Bob

author: legacy
author_rank: Super Contributor
timestamp: February 07, 2016, 01:37:22 pm
content: here I have an old Atlera flex10K fpga board, it comes with its flash programming chip and its byte blaster interface (parallel port)it requires QuartusII v5 (I have a copy, webpack=free license) as its support has gone droppedI think I will put it on ebay as I prefer to use a XILINX XC95xx CPLD

author: uncle_bob
author_rank: Unknown
timestamp: February 07, 2016, 01:39:23 pm
content: Quote from: obiwanjacobi on February 07, 2016, 07:31:16 amHiThe Quartus guys moved over to a "64 bit only" approach back around version 12 or so. Their stuff all runs on anything from Win 7 on forward as long as it is 64 bit. Some of their newer versions run on things other than Windows as well.Bob

author: legacy
author_rank: Super Contributor
timestamp: February 07, 2016, 01:52:47 pm
content: Quote from: Alex Eisenhut on February 06, 2016, 04:41:02 pmQuote from: uncle_bob on February 06, 2016, 04:45:28 pmI do not understand the point, as the XC95108 data sheet says thatyou can provide 5V to the internal logic and input buffers (VCCINT)and 5V to the output drivers (VCCIO)exactly, what have you done, guys ? and which is the nasty diode clamp issue ?

author: legacy
author_rank: Super Contributor
timestamp: February 07, 2016, 01:58:22 pm
content: Interfacing 3V and 5V applications: found a goodApplication Noteby nxp

author: uncle_bob
author_rank: Unknown
timestamp: February 07, 2016, 02:49:03 pm
content: Quote from: legacy on February 07, 2016, 01:52:47 pmHiIf you take a part that does not have 5V outputs (or inputs) and:Raise the ground pin on the part up to 0.9VFeed the supply with 4.2VYou have a part that swings roughly equally to both sides of 2.5V. Most 5V CMOS data sheets suggest that the logic threshold is at 2.5V plus minus some tolerance. (it isn't, but that's not part of this story). The 3.3V part has a 3.3V supply. If you run up to 3.6V, it's pretty much the same with slightly different numbers.Normally the low side is done with some sort of series drop element (like a pair of low barrier voltage diodes). The high side is done with an adjustable series regulator. It all looks fine on paper.Now, pull all the inputs low. The clamp diodes all fire and the low side voltage goes below your 0.9V supply. Worse yet, pull an output low. Then the 0.9V goes right to ground if it's pulled hard enough. (pull down resistor or something else).Next pull all the inputs high. Again the clamp diodes all fire and your part is running off of the +5 through the clamp diodes rather than your series 4.3V regulator. Same issue if an output gets pulled high.If you started with 3.3V you may or may not have fried the chip yet.Now take some of the lines high and some of them low. You have both effects at the same time. Likely your supply is over the max on the chip at this point.All of this is just looking at the output transistors and input clamps. It does not include neat stuff like parasitic stuff that gets triggered when you are above supply or below ground. Since you can get in trouble just with the outputs, having a part with no clamp to the high side rail does not keep you out of trouble. In the context of "drop it into anything" the split supply thing is not a good idea.Bob

author: Bruce Abbott
author_rank: Frequent Contributor
timestamp: February 07, 2016, 06:16:57 pm
content: Quote from: legacy on February 07, 2016, 01:52:47 pmThe point is that the XC95108 is discontinued and unobtainable. Some 9500XL series parts are still available, but they are 3.3V Vccio only.The 'nasty clamp diode issue' doesn't apply to 9500XL because they don't have clamp diodes, but youmighthave trouble driving 3.3V logic high into a line that is pulled up to 5V. Pullups are usually only used with open collector drivers, in which case it isn't a problem. However a dodgy circuit might use pullups to raise the voltage when interfacing between TTL and CMOS.All this means is that - as always - you should determine the specific requirements of the device you are interfacing tobeforedeciding which chips to use.

author: Tronix
author_rank: Newbie
timestamp: February 07, 2016, 10:36:54 pm
content: Thanks for all the replies. Just read through it all.QuoteI would have that problem with some of the signal lines.

author: Bruce Abbott
author_rank: Frequent Contributor
timestamp: February 07, 2016, 10:48:34 pm
content: Quote from: Tronix on February 07, 2016, 10:36:54 pmWhat are you interfacing to, and which signals lines in it have pullups?

author: legacy
author_rank: Super Contributor
timestamp: February 08, 2016, 11:03:06 am
content: the real problem I have: 32bit on the data bus line, plus 24 bit on the address bus line, plus 4 bit on the control bus lineall of these at 5V, while I have to use a Spartan6 fpga, which is 3.3V: I will need to put a lot of level-shifter buffers in the middleand the PCB will be bloated about that

author: legacy
author_rank: Super Contributor
timestamp: February 08, 2016, 11:13:31 am
content: Quote from: Bruce Abbott on February 07, 2016, 06:16:57 pmrecently, I have bought a few of them from ebay uk

author: Bruce Abbott
author_rank: Frequent Contributor
timestamp: February 08, 2016, 05:10:54 pm
content: Quote from: legacy on February 08, 2016, 11:03:06 amWhat computer are you interfacing to, and what is the purpose of your device?QuoteLucky you!

author: legacy
author_rank: Super Contributor
timestamp: February 08, 2016, 05:35:45 pm
content: Quote from: Bruce Abbott on February 08, 2016, 05:10:54 pmah, it's a bus, a synchronous bus, made by Motorola in 1994, it needs a finite state machine in order to handle the access (eventually in burst mode)the fpga should implement the fsm, plus a few extra devices, including a super fast serial, able to shoot up to 3Mbps (over usb), and a dram controllerI am not sure if to use the fpga's PLL (every good fpga has a built in one, I guess), or if I'd better an external PLL (e.g. MC88915? MC88916?): with "clock distribution in mind" engineers in Motorola have designed it to export half the clock frequency (12.5Mhz) over the connector (a big 96pin, 3 row of 32 pins), so I need to double it locally (25Mhz) in order to provide the right synchronization to the fsm.

author: uncle_bob
author_rank: Unknown
timestamp: February 08, 2016, 06:19:46 pm
content: Quote from: legacy on February 08, 2016, 05:35:45 pmHiMost FPGA's have PLL's in them. This thread has mixed CPLD's and FPGA's without identifying which is which. CPLD's often do not have PLL's. If you have a FPGA and a PLL in it, your timing closure process (part of the design) will be much easier with an on chip PLL.You can get parts that have a *lot* of buffers in one package. There is no need to buy them one buffer at a time. If I'm adding correctly, you have 32+24+4 = 60 lines. With hex inverters (a very low density approach) that's 10 packages. With octal transceivers, you are down to 8 packages. That's without getting into anything very crazy.Bob

author: legacy
author_rank: Super Contributor
timestamp: February 08, 2016, 06:25:59 pm
content: Quote from: uncle_bob on February 08, 2016, 06:19:46 pmas already written:CPLD XC95108, PLCC, I/O @ 5V, already boughtFPGA spartan6, I/O @ 3.3V + buffer level shifter, I have not decided which one in in s6e familyI had forgotten to specify: they are used in two different projects (CPLD-> glue logic for RAM-DISC, FPGA-> DRAM ctrl + fast uart)even if, they are going to be used in the same board

author: legacy
author_rank: Super Contributor
timestamp: February 08, 2016, 06:37:11 pm
content: Quote from: uncle_bob on February 08, 2016, 06:19:46 pmyes, correct, but the bus is 5V, while s6e is 3.3V, unfortunately it's not 5V tolerantso, I need external Dual-Supply buffers, in order to adapt the bus voltage (5V) to the fpga voltage (3.3V)the CPLD project has no issue, the CPLD is already 5V and it's involved only as glue logic with a few lines from the bus(5 signals in total: 3 input, 2 output), so, the PCB will be easy, in this caseproject1 and project2, will be implemented in two different PCBs, as "expansion" cards.

author: uncle_bob
author_rank: Unknown
timestamp: February 08, 2016, 11:55:15 pm
content: Quote from: legacy on February 08, 2016, 06:37:11 pmHiIf you have 24 address lines - do you need to read them or only write to them? (or only read and not write). I'm guessing it is one or the other, but not both. Either way, a very standard single supply tri-state buffer with TTL level inputs should do the trick. If it's a drive the address thing, the power is +5 and 3.3V logic will toggle TTL levels fine. If it's read the lines, you do a 3.3V supply and let the 5V immunity of the chips do it's thing.The 4 control lines may or may not fit in the same category as the address lines, same set of questions apply.On the data lines, yes you need some sort of bidirectional gizmo. It will have to run on +5. If it has TTL thresholds, you are ok on the inputs. If not, do the very standard pull up level shift and drive them off of 3.3V. On the outputs, you know they are going from 0 to 5V. You need 0 to 3V .... a resistive divider does that quite well. At the very slow speeds you are talking about it all works pretty well. You have essentially zero gate loads to deal with on the dividers. Near zero C makes the RC time constant mighty small. (Ok some math, if the resistors are 1K and 2K, their parallel combo is 750 ohms. 750 times 10 pf gets you to 7.5 ns. Your 12.5 MHz clock has a period of 80 ns. There's no reason to be up as high as 1K or 10 pf ...Bob

author: Bruce Abbott
author_rank: Frequent Contributor
timestamp: February 09, 2016, 06:21:22 am
content: Quote from: legacy on February 08, 2016, 06:37:11 pmThat fpga's not looking so wonderful now, is it?The magic that high gate-count fpga's do comes at a price - the need to operate on very low voltage. Manufacturers don't build in 5V level converters because they are expensive, and the market for 5V compatible devices is too small.So if you want to use your fpga on a 5V bus then you will just have to 'bite the bullet' and install external buffers. In the old days such buffering was standard practice (even on purely 5V systems) because the bus driving capability of CPUs and peripheral chips was often very limited.

author: legacy
author_rank: Super Contributor
timestamp: February 09, 2016, 09:51:30 am
content: the address lines need to be input only, in this project I do not need DMAthe data lines need to be bidirectionalctrl lines is composed by 3 inputs, and 2 outputs

author: legacy
author_rank: Super Contributor
timestamp: February 09, 2016, 10:08:09 am
content: Quote from: Bruce Abbott on February 09, 2016, 06:21:22 amyes, I come from the 80s, I remember when I had to add a lot of 245 and 244 chips and then the PCB became more complexin my case, I might go for Spartan2, it's 5V tolerant, already successfully used in myNintendo ADV(it's a project I made in 2003), but nowadays … I have difficulties in finding these chipswhile it's almost easy to find a few XC95108 chips on Ebay, even if they are a bit expensive (10-20-30 euro), apparently there is a little demand of these CPLD I guess because of their legacy feature and because they do not require external SPI flash which makes them perfect for "glue logic" in order to replace damaged chips in 5V systemscontrariwise it's difficult to see spartan2e chips, it smells they have zero demand

author: nctnico
author_rank: Super Contributor
timestamp: February 09, 2016, 11:11:39 am
content: There are version of the 245 and 244 which are easier to route (IIRC 545 and 544) and if you use the TSOP versions they are almost inline with the signals and take very little space.

author: legacy
author_rank: Super Contributor
timestamp: February 09, 2016, 11:50:53 am
content: 244 and 245 like, but Dual-Supply buffersso, I can supply one end at Vcc1=5V, and the other end at Vcc2=3.3V

author: Bruce Abbott
author_rank: Frequent Contributor
timestamp: February 09, 2016, 05:05:57 pm
content: Quote from: legacy on February 09, 2016, 11:50:53 amYes. The 74LVX4245 is a TTL compatible dual supply equivalent of the 245. You can also use it replace a 244 by tying OE low and DIR high or low.The 74HC4050 is useful if you just need a few extra inputs (6 buffers per package).

author: uncle_bob
author_rank: Unknown
timestamp: February 09, 2016, 05:52:04 pm
content: Quote from: legacy on February 09, 2016, 10:08:09 amHiAs mentioned earlier, while it's easy to find some things "labeled" as this or that on eBay, it is not quite as easy to find good working examples of older parts. It's not just eBay. We occasionally get bit here at work exactly the same way. A taped up reel or tray comes in and ... surprise ... not what it's supposed to be. That's a major mess if you only catch it after they went through the pick and place.Bob

author: uncle_bob
author_rank: Unknown
timestamp: February 09, 2016, 06:00:09 pm
content: Quote from: legacy on February 09, 2016, 09:51:30 amHiOk, so address lines are simply 3.3V inverters / buffers / whatever that have 5V tolerant inputs. Same with the three control line inputs. That's 27 pins to deal with. It's either 14 pin packages at 6 to a package or something bigger with more PIA routing wise. I'd go with the 14 pin packages. The only real question then is "how small can you solder". If the five packages cost you more than 15 cents each, you need to shop harder (or stop buying DIP packages).For the bidirectional pins, you can go the way I suggested earlier or there is another way:For the "in" direction, it works just like the other inputs. For the "out" it's a tri-state 5V powered part with TTL level inputs. No resistors, no speed questions. Maybe a few more packages to deal with. Very simple to do.Bob

author: legacy
author_rank: Super Contributor
timestamp: February 11, 2016, 04:47:37 pm
content: about the PLL problem, currently I am using an external chip, MC88915 (and I am also ready with MC88916), it seems to me that Spartan 3E offered only 4 Digital Clock Managers (DCM) but did not offer any Phase-Locked Loops (PLL), while the Spartan 6 offers the more flexible CMT which provides both DCM's and PLL's!so, I'd better use a Spartan 6 chip

author: uncle_bob
author_rank: Unknown
timestamp: February 11, 2016, 05:43:23 pm
content: Quote from: legacy on February 11, 2016, 04:47:37 pmHiOne of the "wonderful" debates when you get Xylinx and Altera guys at the same bar is the relative merits of the clock schemes used by each company. That is another layer on top of the whole "no fancy clock stuff in CLPD's" issue.With both companies, the number of this and that (including clock inputs) goes up as the chips get bigger. The tendency is to advertise what is in the biggest million pad BGA in large type and put a unreadable footnote 22 pages later about the packages you can afford not having everything and anything in them. It's always best to do a bit of digging before you pick a specific chip. The data is there, it's generally in a nice table. That table probably is not in the first document you will come across.Bob

author: Artlav
author_rank: Frequent Contributor
timestamp: February 12, 2016, 08:34:42 am
content: Quote from: Bruce Abbott on February 06, 2016, 06:40:06 amOn an off-topic note, where can i get one or what to look for?Searching on both ebay and digikey produced zero results.Google images do come up with something that kinda looks like one, but no actual links.

author: nctnico
author_rank: Super Contributor
timestamp: February 12, 2016, 02:10:39 pm
content: Quote from: Artlav on February 12, 2016, 08:34:42 amSearching for 'qfp dip' on Ebay produces more than 200 results which prices starting from $1 including shipping.

author: legacy
author_rank: Super Contributor
timestamp: February 12, 2016, 02:13:13 pm
content: it might depend on the area where one is located

author: nctnico
author_rank: Super Contributor
timestamp: February 12, 2016, 02:19:05 pm
content: Always search on Ebay.com ofcourse!

author: Artlav
author_rank: Frequent Contributor
timestamp: February 12, 2016, 06:46:58 pm
content: Quote from: nctnico on February 12, 2016, 02:10:39 pmAh, ok.I was looking for a QFP to PLCC adapter.That is, something that would help program a tqfp44 CPLD in a programmer with a PLCC44 socket.

author: Bruce Abbott
author_rank: Frequent Contributor
timestamp: February 12, 2016, 08:45:57 pm
content: Quote from: Artlav on February 12, 2016, 06:46:58 pmSuch things are available, but they are not cheap!You could make one from a tqfp programming socket and a PLCC plug likethis, or perhaps even make the PLCC plug from scratch.But there might be another way to do it that doesn't involve a PLCC plug. Which programmer do you have, and what CPLDs do you want to program?

author: nctnico
author_rank: Super Contributor
timestamp: February 12, 2016, 09:18:42 pm
content: Quote from: Artlav on February 12, 2016, 06:46:58 pmUsually only a few wires are needed for programming so it makes more sense to put a few pins on a board and solder these to a PLCC (or any other) socket.