Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Tips and advice for FPGA newbie

Status
Not open for further replies.

oliglaser

Junior Member level 3
Joined
Feb 26, 2010
Messages
31
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,286
Location
Manchester, UK
Activity points
1,688
Hi,

I'm not new to electronics or programmiing, just to PLDs.

I'm thinking of using a FPGA in a project but am not sure where to start. I'm trying to keep the costs as low as possible at the moment so I was looking at an Amontec USB JTAGKey. I make my own prototype boards so I don't want to buy any devleopment boards, just be able to program the chips in circuit. My questions are:

1. Will this program most Xlinix, ALtera and Actel FPGAs okay?

2. Is it compatible with the various development platform softwares? If not what do I write the code with?

3. If the above answers are no, what is a decent cheap way of programming these chips?

If anyone else makes their own boards, any advice on the easiest/cheapest tools to use would be good, for instance I am having trouble just locating a header for the flash pro 4 from actel (I have found one, but it seems they don't go to great lengths to make sure the components used with their boards are easily sourced)

I realise these might be stupid questions, but I'm completely new to this field, any help would be much appreciated.

Thanks,
Oli
 

Re: FPGA Newbie advice

FPGAs are great fun. But I would not suggest you make your first board or two. We used to make CPLD-based boards but there are some really great low cost options out there for FPGAs so we stopped -- just not cost effective. So none of the below belong to me, just things I've used.

First, don't worry too much about vendors. Just pick one and stick to it. Xilinx has won me over because their parts are available in small quantity with no hassle. Altera... not so much, although maybe getting better. Altera has nicer tools, though, and cheap JTAG hardware.

I don't make programmable logic stuff for sale anymore but still have tutorials at **broken link removed** (some for Xilinx, some for Altera, not up to date, but probably close enough to get started).

Now... hardware. I really like the Digilent S3BOARD. Xilinx must defray the cost of these somehow. Spring the extra $50 and get the one with the larger FPGA device. The board has enough switches and ports and LEDs that you can do lots of practical experimenting. I have two custom CPUs that run on this hardware (see http://www.drdobbs.com/embedded-systems/221800122). There is also a very nice logic analyzer project for this board (Google Sump logic analyzer) and a TRS-80 emulator that works well (from the board's Yahoo Group).

Digilent also has cheap JTAG cables although their USB cable isn't a direct replacement for the pricey Xilinx USB cable it does work. $109 in the base configuration (+$50 for the larger FPGA) http://www.digilentinc.com/Products/Detail.cfm?NavPath=2,400,799&Prod=S3BOARD. Or look at the $50 S3E board from Avnet: http://www.em.avnet.com/evk/home/0,...W%3D%26PNT%3D%26BID%3DDF2%26CTP%3DEVK,00.html (Long link). Not as much I/O and has some cool but confusing features (like a PSoC CPU onboard and touch switches instead of physical switches). USB JTAG is built into this board.

If you have an appetite for more features, both of those companies have plenty of other choices. Oddly enough eBay is a good source for a lot of FPGA stuff too including cheaper ($100) Xilinx USB JTAG dongle knock offs.

While it is true you can get lots of JTAG hardware, the Xilinx tools like to work with the Xilinx dongles. The workflow without them is a pain -- you have to produce some sort of file and switch to another tool to "burn" the device. But with the real dongle its all integrated and you can even do debugging in the device if you have the expensive "Chipscope" software (they have an evaluation version and of course you might "locate" a copy used or something).

As for Actel and other vendors. I like some of Actel's products, but frankly the two big players are Xilinx and Altera. As such you'll find way more support and its easier dealing in ones and twos since you can just go to DigiKey or other "public" distribution and buy stuff.

So if I were starting out today this is what I would do:

1) Get some kind of project in mind.
2) Download (free) both Xilinx ISE and Altera Quartus. You don't need any hardware to simulate stuff. Try both out and see which one "feels" better to me.
3) Work on my project a little. Like I say, you don't have to have hardware to simulate and you should be simulating before making hardware anyway.
4) When I have a feel for how big a device I needed and that I was going with one vendor over the other, I'd browse Digilent, Avnet, eBay, and maybe just Google for a cheap board that had the kind of device I wanted. Parallax (the Basic Stamp people) used to sell Altera development boards. Not sure if they still do, but I don't think they push them if they do.

Hope that helps. I did the same learning exercise more years ago then I care to remember and I know that first hump is really steep. But it is great fun -- as I wrote somewhere once "a truly solderless breadboard."

Al W.
**broken link removed**[/url]
 

FPGA Newbie advice

Hi Oli, Al,

What Al said makes sense. Being an FPGA user myself, I always try to do as much as possible in software before going to hardware.

Actually, my company makes software that lets FPGA developers run the Xilinx and Altera tools in a vendor-neutral fashion.

Sorry for the plug, but if it helps, try our free webapp at https://www.plunify.com and see if it gets you started with simulation and FPGA implementation.

Best,
mike
 

Re: FPGA Newbie advice

bagelfire said:
What Al said makes sense. Being an FPGA user myself, I always try to do as much as possible in software before going to hardware.

I think real hardware experience is important, since there are a lot of things that will work 100% reliably in software simulation that will turn out to be flaky in real hardware. I'm sure someone with experience would be able to tweak the software simulation to detect all the possible 'gotchas', and I'm sure that the people at Intel have some really amazing stuff that's far beyond the range of hobbyists, but from what I've seen most simulation tends to either be overly optimistic or overly pessimistic.

Perhaps there's some good simulation stuff I'm unaware of--if so, enlightenment would be appreciated. Some things I'd like to see for CPLD simulation (some of these may be less applicable with FPGAs)

  • Simulate T flip-flops functionally as JK flip-flops, where the J and K inputs contain the product terms that are applicable if the latch is low or high, respectively, but retain the timing and routing behavior of T flip flops. If a T flip flop state is "unknown" in simulation, it won't recover unless asynchronously set or reset, even though in the real world its behavior might be entirely predictable (and modeling it as a JK would generate appropriate real-world behavior). For example, if a T flip-flop has one or more product terms which will be true if the flip-flop output is true, and none which will be true if the flip-flop output is false, then after one good-length clock where such conditions hold the output will most likely be false (unless the latch was in a rare metastable state), and after two such clocks it's pretty well guaranteed.
  • Easily allow nodes to be selectively configured to pass through an "unknown" state for various amounts of time when switching from high to low. Doing that for all nodes would often lead to system states that were totally "unknown", but doing it for as many nodes as possible would aid in detecting race conditions and timing hazards.
  • Import a design from a fusemap file. One would hope the fusemap would always match the specified design, but that doesn't always actually happen. Simulating the actual fusemap would help defend against compiler bugs.
  • Easily simulate the behavior of different types of I/O pins (floating, pull-up, pull-down, or bus-hold).
Anyone know any good software for such things? Incidentally, I've not done FPGA's yet--just CPLD's, and my preferred language is ABEL. I'm getting my feet wet with Verilog and VHDL, but find that ABEL makes it easier to predict the resources required to do things various ways. Right now I'm designing for the Lattice Mach4064ZE, but I've also used the Xilinx 9536XL.
 

Re: FPGA Newbie advice

Hi Oli,

The FPGA vendors and their simulation partners e.g. Mentor Graphics do provide simulation tools and libraries to simulate timing behavior. As timing is closely tied to the specific vendor hardware, one would typically need to run a "Compile simulation libraries" step with an FPGA vendor utility before pointing a simulator to them.

Static timing analysis using the FPGA vendors' tools help point out bottlenecks and warnings that are good to heed.

There are several types of simulation as you alluded to: functional with no timing information, function with timing estimates, post-synthesis, post place-and-route. As you can imagine, simulations slow down as one goes further down the implementation process and gets closer to hardware, until you get the equivalents of a gate-level simulation with as detailed a set of timing information you can get.

If you're looking for commercial simulation software, Modelsim and VCS have worked well for me. Modelsim has a free version with limited features.
The open source simulators GHDL and Icarus Verilog can be configured to work with timing simulations although I have not tried them myself.

I have encountered cases where things worked fine in functional simulation and broke in hardware. Most of the time, I was able to narrow bugs down at the timing simulation stage, but more often than not, my problems could be fixed at the RTL level. Possibly related to how I code my FPGA designs.

In many instances, I've found it useful to create a bare-bones FPGA system, do some quick functional simulation and get down to testing on a board as soon as possible. But when my design gets big and stable, I found it useful to try many rounds of synthesis and place-and-route with different constraints to optimize the speed/size.

Anyway, just some thoughts. Hope this helps.
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top