Author Topic: Working with FPGA  (Read 14880 times)

0 Members and 1 Guest are viewing this topic.

Offline StiegeTopic starter

  • Regular Contributor
  • *
  • Posts: 72
  • Country: nz
Working with FPGA
« on: February 08, 2013, 10:12:38 pm »
Hey everyone,

I'm recently been getting into designing stuff on an Altera DE0 board at home, but at work I'm also using a Spartan 3a-dsp 1800 development board. I'm enjoying it heaps, but I'm confused about what's required to use an FPGA without a development board. Especially regarding how the FPGA has to be reprogrammed on every power up. Are there stock parts for this? Are they unique to Altera vs Xilinx FPGAs, or is it all fairly generic.

Basically any directions on where I can read about porting my designs from the development board and onto my own board would be appreciated.

Kind regards and thanks in advance
 

Offline marshallh

  • Supporter
  • ****
  • Posts: 1462
  • Country: us
    • retroactive
Re: Working with FPGA
« Reply #1 on: February 08, 2013, 10:37:39 pm »
The bare minimum for an fpga design to run standalone:

1. Power supplies (I/O voltages of maybe 3.3/1.8/2.5, analog PLL supplies 2.5v, Vcore 1.2v or 1.1v)
2. Clock source (50mhz LVCMOS oscillator is common)
3. Config storage (usually SPI flash rom)

Altera's EPCS chips are just remarked ST/Numonyx flash roms. If you are careful about what specs parts you get you can find a drop-in commodity replacement.
FPGAs generally have builtin self-configuration circuitry. They have a rough internal oscillator, enough to clock in bits from the external SPI rom.
They will also have a variety of other configuration schemes, fast parallel, fast serial (QSPI), etc... It depends if you need to re-configure the FPGA on the fly to swap operating modes often, or just send updates in the field.

For lowest PLL jitter at the very least put a pi filter on the Vcca supplies, you can use a switching regulator fine.
Low-demand fpga boards can get by with just a few LDOs.

For low voltage, high current core voltages like 1v2, use a push pull converter instead of the classical buck converter. I use the semtech SC185, switching speed is 1Mhz and uses cheap small passives. For high speed switching regs like this you will want to use MLCC caps, not alum. electrolytic because of their lower ESR.

Anyway that's the real bog-standard stuff, more specific applications will come with more specific requirements.
Verilog tips
BGA soldering intro

11:37 <@ktemkin> c4757p: marshall has transcended communications media
11:37 <@ktemkin> He speaks protocols directly.
 

Offline StiegeTopic starter

  • Regular Contributor
  • *
  • Posts: 72
  • Country: nz
Re: Working with FPGA
« Reply #2 on: February 08, 2013, 10:54:44 pm »
The bare minimum for an fpga design to run standalone:

1. Power supplies (I/O voltages of maybe 3.3/1.8/2.5, analog PLL supplies 2.5v, Vcore 1.2v or 1.1v)
2. Clock source (50mhz LVCMOS oscillator is common)
3. Config storage (usually SPI flash rom)

Altera's EPCS chips are just remarked ST/Numonyx flash roms. If you are careful about what specs parts you get you can find a drop-in commodity replacement.
FPGAs generally have builtin self-configuration circuitry. They have a rough internal oscillator, enough to clock in bits from the external SPI rom.
They will also have a variety of other configuration schemes, fast parallel, fast serial (QSPI), etc... It depends if you need to re-configure the FPGA on the fly to swap operating modes often, or just send updates in the field.

For lowest PLL jitter at the very least put a pi filter on the Vcca supplies, you can use a switching regulator fine.
Low-demand fpga boards can get by with just a few LDOs.

For low voltage, high current core voltages like 1v2, use a push pull converter instead of the classical buck converter. I use the semtech SC185, switching speed is 1Mhz and uses cheap small passives. For high speed switching regs like this you will want to use MLCC caps, not alum. electrolytic because of their lower ESR.

Anyway that's the real bog-standard stuff, more specific applications will come with more specific requirements.

Great!

So I'm looking for more information on the config storage. The DE0 board has a Cyclone III 3C16 FPGA. I've had a quick look though some of the literature: http://www.altera.com/literature/lit-cyc3.jsp

Is that the best way to learn about it? It talks about a lot of standards that I have pretty much no understanding of, do I have to understand all of that before I can implement a basic FPGA design? Where's a good starting point that just covers the basics for implementing an FPGA design and covers some of the options that I could look into?
 

Offline marshallh

  • Supporter
  • ****
  • Posts: 1462
  • Country: us
    • retroactive
Re: Working with FPGA
« Reply #3 on: February 08, 2013, 11:02:49 pm »
Read, read, read. There is no short cut. FPGAs are picky and you are only going to know what you're doing if you get in there and learn it. The Cyclone III handbook is a compilation of all relevant chapters.
Don't sweat it over all the chapters over SSTL, LVDS, QDR sram blah blah, the short story is that there are several categories of pin types and within those each pin has several different possible functions determined by the device fitter (part of synthesis)
Verilog tips
BGA soldering intro

11:37 <@ktemkin> c4757p: marshall has transcended communications media
11:37 <@ktemkin> He speaks protocols directly.
 

jucole

  • Guest
Re: Working with FPGA
« Reply #4 on: February 08, 2013, 11:42:26 pm »
A while ago I bought a very minimal fpga dev board which looks like one of these, the schematic for it is pretty much the bare essentials but it gave me a good "boost" up and over the wall into fpga land! without doing too much reading ;-)



http://www.topelectronics.com.au/image-eb/EP2C5T144.pdf
 

Offline StiegeTopic starter

  • Regular Contributor
  • *
  • Posts: 72
  • Country: nz
Re: Working with FPGA
« Reply #5 on: February 08, 2013, 11:54:48 pm »
That's excellent! Nice reference to Phi just there.
 

Offline EEVblog

  • Administrator
  • *****
  • Posts: 37664
  • Country: au
    • EEVblog
Re: Working with FPGA
« Reply #6 on: February 09, 2013, 12:16:47 am »
Just take any FPGA development board for the same chip family you are using and simply copy exactly everything it's doing. SPI FLASH boot memory, power supplies, clock, config pins etc.
Once you have that base working system, you can work backwards and figure out why they are doing what they are doing.
Different families of FPGA can have very differing requirements, let alone between brands whcih can use entirely different terminology and configuration techniques.
If you get one config pin wrong, or put the clock on the wrong pin, then your system will just sit there and do nothing, or give you lots of confusing errors.

Dave.
 

Offline StiegeTopic starter

  • Regular Contributor
  • *
  • Posts: 72
  • Country: nz
Re: Working with FPGA
« Reply #7 on: February 09, 2013, 12:54:22 am »
Very pragmatic, I'll take that advice.
 

Offline EEVblog

  • Administrator
  • *****
  • Posts: 37664
  • Country: au
    • EEVblog
Re: Working with FPGA
« Reply #8 on: February 09, 2013, 08:42:35 am »
I forgot that I have a video on this. Kinda, it's a bit random, but might have some useful info.



Dave.
 

Offline Codemonkey

  • Regular Contributor
  • *
  • Posts: 235
  • Country: gb
Re: Working with FPGA
« Reply #9 on: February 09, 2013, 10:40:05 am »
Just take any FPGA development board for the same chip family you are using and simply copy exactly everything it's doing. SPI FLASH boot memory, power supplies, clock, config pins etc.

Not quite so straight forward with the DE0-Nano board, its also got circuitry on there that acts as an Altera Byteblaster. Its a shame you can't re-purpose it to use it to program other boards when you start doing your own designs.
 

Offline EEVblog

  • Administrator
  • *****
  • Posts: 37664
  • Country: au
    • EEVblog
Re: Working with FPGA
« Reply #10 on: February 09, 2013, 11:26:10 am »
Just take any FPGA development board for the same chip family you are using and simply copy exactly everything it's doing. SPI FLASH boot memory, power supplies, clock, config pins etc.

Not quite so straight forward with the DE0-Nano board, its also got circuitry on there that acts as an Altera Byteblaster. Its a shame you can't re-purpose it to use it to program other boards when you start doing your own designs.

Yes, good point. It should be a dev board that is only programmable via JTAG. Not these smarter all-in-one dev boards.

Dave.
 

Offline Neilm

  • Super Contributor
  • ***
  • Posts: 1545
  • Country: gb
Re: Working with FPGA
« Reply #11 on: February 09, 2013, 11:42:59 am »
If you are looking at porting designs between chip manufacturers, do your best to ensure that the code has been done in a portable format, like VHDL or Verilog. I worked for a company many years ago that insisted that everything be done in a schematic capture format. (They used OrCad). Unfortunately for them, OrCad promptly dropped the FPGA synthesis support meaning they ended up with a station that was using an old version of OrCad and couldn't be updated and would not support the latest chips.

They then decided that the best thing to do would be using the manufacturers schematic capture options. No problem there, every thing worked - until the head office made a deal with a big FPGA manufacturer and decided that all FPGAs would be from that manufacturer.

The result was I had to re-write the code for a third time, only in this instance it was in the format I had originally asked for - having "accidentally" mentioned in a meeting that if we had made it portable in the first place, my time wouldn't have been tied up for best part of three weeks (again).

Neil
Two things are infinite: the universe and human stupidity; and I'm not sure about the the universe. - Albert Einstein
Tesla referral code https://ts.la/neil53539
 

Offline EEVblog

  • Administrator
  • *****
  • Posts: 37664
  • Country: au
    • EEVblog
Re: Working with FPGA
« Reply #12 on: February 09, 2013, 11:59:14 am »
If you are looking at porting designs between chip manufacturers, do your best to ensure that the code has been done in a portable format, like VHDL or Verilog. I worked for a company many years ago that insisted that everything be done in a schematic capture format. (They used OrCad). Unfortunately for them, OrCad promptly dropped the FPGA synthesis support meaning they ended up with a station that was using an old version of OrCad and couldn't be updated and would not support the latest chips.

Out of interest, I know of cases (military) where schematic capture is used for FPGA's because VHDL ad Verilog are classed as "source code" and therefore fall under different stricter regulatory requirements. Source code in this instance has to have every line of code independently checked and verified at $$/line, but schematic capture falls under the "hardware" definition, so they get away without doing that!  ;D

Dave.
 

Offline Marco

  • Super Contributor
  • ***
  • Posts: 6694
  • Country: nl
Re: Working with FPGA
« Reply #13 on: February 09, 2013, 01:04:30 pm »
It's a shame there is no universal markup for VHDL/Verilog which at least lets you (portably) design the hierarchy and signal connections in schematic form.
 

Offline Christe4nM

  • Supporter
  • ****
  • Posts: 252
  • Country: nl
Re: Working with FPGA
« Reply #14 on: February 09, 2013, 01:13:29 pm »
Just take any FPGA development board for the same chip family you are using and simply copy exactly everything it's doing. SPI FLASH boot memory, power supplies, clock, config pins etc.

Not quite so straight forward with the DE0-Nano board, its also got circuitry on there that acts as an Altera Byteblaster. Its a shame you can't re-purpose it to use it to program other boards when you start doing your own designs.

Yes, good point. It should be a dev board that is only programmable via JTAG. Not these smarter all-in-one dev boards.

Dave.

The Terasic Max-II CPLD microkit does have an on-board USB Blaster that with a breakout header for stand alone use to program your own devices using JTAG. Unfortunately for me the shipping costs outweigh the purchase price by a lot.
 

Offline free_electron

  • Super Contributor
  • ***
  • Posts: 8515
  • Country: us
    • SiliconValleyGarage
Re: Working with FPGA
« Reply #15 on: February 09, 2013, 04:13:33 pm »
Quote from: marshallh link=topic=14109.msg190436#msg190436
remarked ST/Numonyx flash roms.

No they're not. If you pay a chip maker enough he will put whatever you want on the package. No need for re-marking  ;D. They're now made by micron. ST spun off flash to numonyx which got 'borged' by micron.

But yes, they are essentially 25F series spi flash chips. And they were fabbed by ST for a long time
Professional Electron Wrangler.
Any comments, or points of view expressed, are my own and not endorsed , induced or compensated by my employer(s).
 

Offline Neilm

  • Super Contributor
  • ***
  • Posts: 1545
  • Country: gb
Re: Working with FPGA
« Reply #16 on: February 09, 2013, 05:40:11 pm »
If you are looking at porting designs between chip manufacturers, do your best to ensure that the code has been done in a portable format, like VHDL or Verilog. I worked for a company many years ago that insisted that everything be done in a schematic capture format. (They used OrCad). Unfortunately for them, OrCad promptly dropped the FPGA synthesis support meaning they ended up with a station that was using an old version of OrCad and couldn't be updated and would not support the latest chips.

Out of interest, I know of cases (military) where schematic capture is used for FPGA's because VHDL ad Verilog are classed as "source code" and therefore fall under different stricter regulatory requirements. Source code in this instance has to have every line of code independently checked and verified at $$/line, but schematic capture falls under the "hardware" definition, so they get away without doing that!  ;D

Dave.

It was a company making military hardware I was referring to. The diktat at the end was done from head office who also insisted we use VHDL (although after I made my comment to managers).
Neil
Two things are infinite: the universe and human stupidity; and I'm not sure about the the universe. - Albert Einstein
Tesla referral code https://ts.la/neil53539
 

Offline StiegeTopic starter

  • Regular Contributor
  • *
  • Posts: 72
  • Country: nz
Re: Working with FPGA
« Reply #17 on: February 10, 2013, 02:32:52 am »
Thanks for all that info. I have actually watched that video already, and it was very useful. I use VHDL at work on the spartan 3a-dsp, and I use verilog on the DE0. This way I'm covering all the permutations of language and brand.

Have been reading the datasheets some more and I understand the config stuff a lot better now.

Being a student is such as shame, all the will in the world but have to save my pennies to afford some of the gear I need to implement this stuff. Feel like I might try to something with a low cost Xilinx chip since I have the programmer at work. Sort of stuck with doing anything with an Altera device, as has been mentioned about the on board DE0 programmer.
 

Offline Marco

  • Super Contributor
  • ***
  • Posts: 6694
  • Country: nl
Re: Working with FPGA
« Reply #18 on: February 10, 2013, 02:56:31 am »
A blaster clone is 10$.
 

Offline StiegeTopic starter

  • Regular Contributor
  • *
  • Posts: 72
  • Country: nz
Re: Working with FPGA
« Reply #19 on: February 10, 2013, 08:16:27 am »
A blaster clone is 10$.

Sorry? I thought the USB blaster would be my only real option. Where could I find this clone?
 

Offline jeroen74

  • Frequent Contributor
  • **
  • Posts: 396
  • Country: nl
Re: Working with FPGA
« Reply #20 on: February 10, 2013, 08:31:12 am »
A $10 clone is likely one that uses the parallel port. You don't want that.

Another one for which you don't need an external programmer:

Morph IC II. IIRC it recalls the FPGA configuration from the host PC upon connection, so might not be what you're after.

Schematic capture of FPGA logic is handy to replace old-school 74xxx based logic boards with an FPGA. You can do this with Altera Quartus and also use the special IP blocks like RAM blocks, multipliers, PLLs etc. Though replicating timing tricks with RC networks is bit trickier in an FPGA.
 

Offline EEVblog

  • Administrator
  • *****
  • Posts: 37664
  • Country: au
    • EEVblog
Re: Working with FPGA
« Reply #21 on: February 10, 2013, 08:53:36 am »
 

Offline jeroen74

  • Frequent Contributor
  • **
  • Posts: 396
  • Country: nl
Re: Working with FPGA
« Reply #22 on: February 10, 2013, 08:56:04 am »
Amazing...
 

Offline StiegeTopic starter

  • Regular Contributor
  • *
  • Posts: 72
  • Country: nz
Re: Working with FPGA
« Reply #23 on: February 10, 2013, 08:07:40 pm »
Sweet!
 

Offline StiegeTopic starter

  • Regular Contributor
  • *
  • Posts: 72
  • Country: nz
Re: Working with FPGA
« Reply #24 on: February 10, 2013, 09:02:51 pm »
So just in my quest to learn more about FPGAs I decided to check out what was on the market. Found the most expensive FPGA on Mouser:

http://nz.mouser.com/ProductDetail/Altera-Corporation/5SGTMC7K2F40C2ES/?qs=sGAEpiMZZMvoScKlWpK8TBFFO0FjFVkjBsZMkmLO2aw%3d

I'm not sure who pays over $50 000 for a chip. Has anyone ever played with one of these things? What's it used for? I'm thinking maybe areas like international fibre optic link data management systems maybe?
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf