26 October - 20 November, 2009: Fpga Design & VHDL Fundamentals of Fpgas
26 October - 20 November, 2009: Fpga Design & VHDL Fundamentals of Fpgas
26 October - 20 November, 2009: Fpga Design & VHDL Fundamentals of Fpgas
Nizar Abdallah
ACTEL Corp. 2061 Stierlin Court Mountain View
CA 94043-4655
U.S.A.
FPGA Design & VHDL
Nizar Abdallah
[email protected]
October 2009
Fundamentals of FPGAs
Agenda
FPGA Fundamentals
Mixed-Signal FPGAs
Actel Fusion Architecture
FPGA Design Considerations
Trends
Choosing an FPGA
Development Tools
Summary
Maxfield, Clive
“The Design Warrior’s Guide to FPGAs”
Elsevier
Maxfield, Clive
“The Design Warrior’s Guide to FPGAs”
Elsevier
Maxfield, Clive
“The Design Warrior’s Guide to FPGAs”
Elsevier
Maxfield, Clive
“The Design Warrior’s Guide to FPGAs”
Elsevier
? ? ? ? ?
? ? ? ?
? ? ? ? ?
? ? ? ?
? ? ? ? ?
? ? ? ?
? ? ? ? ?
? ? ? ?
? ? ? ? ?
XXX
1T
6T
Maxfield, Clive
“The Design Warrior’s Guide to FPGAs”
Elsevier
0
Clk 1
X2 a
pin 3
a a
a
a a a
Set/Reset/Enable
X1
pin 2 a a
Clr
a
XC a
pin 5 a
a
a a
Combinatorial Sequential
Any 3 Input D Flip-Flop With Enable
Function and Set or Reset
(3 input LUT D Q
Equivalent) Enable
A CLK
B Q
C Set or Reset
Digital Signal
Typical System
Analog Inputs 15 18 30 30
Output Gate Drivers 5 6 10 10
I/O Types Analog / LVDS / Std+ Analog / LVDS / Std+ Analog / LVDS / Pro Analog / LVDS / Pro
I/O Banks (+ JTAG) 4 4 5 5
I/O
VCC_OSC
Clock out
to FPGA core
C R
GLINT
Additional Features
Factory trim capability for high
precision
Specifications
Maximum output jitter – 50pS From RTC
RMS External XTAL2
Crystal
10 MHz crystal (0.05%) TO CCC/PLL
CLKOUT0
Duty cycle: 40% - 60% TO RTC
(3.3v)
CLKOUT1
Reference
Clock Output
Phase Low-Pass Clock
VCO
Feedback Detector Filter
Clock
Fixed delay
NGMUX Macro
9
(Access from I/Os in
Middle of Left and
Right Sides)
Central Global Rib 12 Quadrant Global
Networks (3 per
6 6 6
3
6 Quadrant – Access
from I/Os in 4
3
6 6 6 6 Corners)
Global Spine
PLL/CCC
PLL/CCC
Analog
Inputs
A/D (incl. SRAM, Small page size (1kb)
CCC/PLL, IO)
Can be accessed by either on-chip
or off chip resources
High Performance
FLASH
Xtal OSC, 60 ns random access
RC OSC,
Memory
RTC, Vreg
Pipelined 10 ns access of
sequential memory addresses
JTAG Port
JTAG Port
4-bit Word
Address
8-bit Data
To FPGA Core
WIDTH
Analog Quad
AV AC AG AT
Pads Gate Driver
Voltage Monitor Current Monitor Temperature
On chip
Block Block Monitor Block
Power
MOSFET
Digital Digital Gate Driver Digital
Input Input Input
Current
Temp.
Monitor/Inst.
Monitor
Amplifier
From
To FPGA To FPGA FPGA To FPGA
To Analog Mux To Analog Mux To Analog Mux
Direct Input used when Maximum Input Voltage is between 2V and VREF
Analog Quad
AV AC AG AT
Pads Gate Driver
Voltage Monitor Current Monitor Temperature
On chip
Block Block Monitor Block
Power
MOSFET
Digital Digital Gate Driver Digital
Input Input Input
Current
Temp.
Monitor/Inst.
Monitor
Amplifier
From
To FPGA To FPGA FPGA To FPGA
To Analog Mux To Analog Mux To Analog Mux
Pre-scaler Input used when Input Voltage is not between 2V and VREF
VCC VREF
Analog to N
VIN Pre-scaler Digital
Converter
Fusion Scaling Factors Give Convenient LSB Values For All ADC Resolutions
All Ranges Indicate Input Level in mV with Simple Left or Right Shift of Binary Value
Maximum Allowable Input Voltage:
-10.5V or +12V for AV and AC pads
+16V for AT pad
Pre-scaling Offset and Gain Error
Gain error
Positive DC inputs: 1% typ
Negative DC inputs: 2% typ
Offset error
2 ± 0.2% of range
10V 9.9V
AV AC
10x 1V
To ADC
Power
Line Side
Analog Quad
Supply Load Side
AV AC AG AT
Pads Gate Driver
Voltage Monitor Current Monitor Temperature
On chip
Block Block Monitor Block
Power
MOSFET
Digital Digital Gate Driver Digital
Input Input Input
Current
Temp.
Monitor/Inst.
Monitor
Amplifier
From
To FPGA To FPGA FPGA To FPGA
To Analog Mux To Analog Mux To Analog Mux
LVDS Bank
FPGA Fabric
System Application
Optional MCU
(ARM or 8051)
Fusion Fusion Fusion
Smart Smart Smart
Applet 1 Applet 2 Applet 3 Peripheral in
FPGA Fabric
Control
Fusion Smart Backbone
Backbone 3.3V
VDD15A
This gets repeated 5 times (for the 10 quad configuration)
GNDA[1]
PCAP
Monitor
VDD33[ 0] PUB
Fusion Device To
ADC
Ch0 ATESTIN
Probe
GNDREF
Pad
BGOUT
GNDAQ
VDDN33 GNDA[0] GNDAQ[0] AV[0] AC[0] AG[0] AT[ 0] ATRTN[4 :0] AT[9:1] AG[9:1] AC[9: 1] AV[9:1] GNDAQ[1] AVDD ADCGNDREF VAREF
uS
5
mS
User
Read
Access
1
ADCSample
Sequence Controller
6
512x9
Dual-Port RAM
Init/Config
10
Dual-Port RAM(s)
Access State Machine
Soft IP
Hard IP
9 ADC Extern al C lock
Generation
This clock signal i s
Crystal Oscil lator PLL Cl ock
distributed to all
Analog . components in this
Inputs Analog SAR
from
. Mux ADC diagram
RC Oscill ator
Quads .
uS
5
mS
1 6
User
ADCSample 512x9
Read Sequence Controller Dual-Port RAM
Access
User System Monitor
512x9
Read Transition Phase
Dual-Port RAM(s)
Access State Machine
General-Purpose General-Purpose
Digital Inputs Digital Outputs
Init/Config
RAM Initializer
Soft IP
Hard IP
Analog
components in this
Inputs Analog SAR
from
. Mux ADC diagram
RC Oscill ator
Quads .
uS
5
mS
S
Interval Gen
ADCSample
Sequence Controller
6
512x9
Dual-Port RAM
Dual-Port RAM(s)
4
Init/Config
RAM Initializer
10
NVM JTAG
Dual-Port RAM(s)
Parameter storage
General-Purpose General-Purpose
Digital Inputs Digital Outputs
Time
0 1 2 3 4 5 6 7 8 9 10 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 Seq (Timeslot) #
1 2 1 3 1 4 1 2 1 3 1 2 1 3 1 4 R C S PD Channel / Function
12 11.1
N=2 9.86
10.4
10.8
9.15
8.20
6.94
5.25
0
3
Step Response
T = 4 Samples
12
N=2 3 Full charge/Discharge
2.25 At 5*T = 20 samples
1.68
1.26 0.95 0.71
0
Impulse Response
X2 6.938 2.112
12.000
X3 8.203 2.730
X4 9.152 3.310 10.000
X5 9.864 3.853
X6 10.398 4.362 OUtput Voltage 8.000
Series1
X7 10.799 4.839 Series2
6.000
X8 11.099 5.287
X9 11.324 5.706 4.000
X10 11.493 6.100
X11 11.620 6.469 2.000
12 11.1
N=2 Over_8v 9.86
10.4
10.8
9.15
8.20
6.94 Assert==3
5.25
0
3
Step Response
T = 4 Samples
12
N=2 3 Full charge/Discharge
2.25 At 5*T = 20 samples
1.68
1.26 0.95 0.71
0
Impulse Response
time
IP Blocks
SmartGen
Logic Synthesis
Programmed
FPGA
Place & Route
User
Analog System Generation Flash Memory System Generation
SmartGen SmartGen
Config File
Analog System Builder Flash Memory System Builder
RTL Mem files Mem files RTL
ASSC+RAM ASSC.mem NVM.mem Init IP
NVM.efc
SMEV+RAM SMEV.mem NVM
SMTR+RAM Programming
SMTR.mem Files NVM Top
AB AB.mem
Analog Top
Start address
Start and end pages
Lock start address
Sequence for
selected procedure
Defined procedures
Make Sure that the Signal Value has been Updated when
Passing a Signal into drive_analog_input
A wait statement can be used for this
Select Temperature,
Voltage or Current
from list
,(Concatenate)
Inc(start, increment, count)
Dec(start, decrement, count)
IncString(“string”, start, increment, count)
Range(start, finish, count)
RandInt(count, Range_to_zero)
Hex(list)
Bin(list)
Rep((list, count)
Skip(count)
File(“filename.txt”)
Signal(“signalname”)
Map{operations} list
PRBS7(length, seed)
PRBS15(length, seed)
Sin(amplitudeV, period, duration)
SinStart(amplitudeV, period, duration)
SinEnd(amplitudeV, period, duration)
CapCharge(amplitudeV, RC, duration)
CapDischarge(amplitudeV, RC, duration)
Ramp(StartV, EndV, Duration)
...
begin
...
-- Actel Analog Drivers Block
drive_analog_input(AV5V_driver, AV5V);
drive_temperature_quad(Temp_driver, Temp);
...
-- Sequence: Unclocked
Unclocked : process
begin
AV5V_driver <= 0.0;
Temp_driver <= 5.0;
wait for 12 ns;
INIT_POWER_UP <= '1';
wait for 28 ns;
SYS_RESET <= '1';
wait for 379907 ns;
AV5V_driver <= 0.1;
wait for 20132 ns;
...
Actel Corporation Confidential © 2009 197
WaveFormer Lite
Verilog Testbench
module stimulus(SYS_CLK, SYS_RESET, INIT_POWER_UP, VAREF, Supply_good,
Over_temp, ATRETURN01, AV5V, Temp);
output SYS_CLK;
output SYS_RESET;
. . .
reg SYS_RESET_driver;
reg INIT_POWER_UP_driver;
reg VAREF_driver;
reg ATRETURN01_driver;
real AV5V_driver;
real Temp_driver;
. . .
drive_analog_input analog_AV5V_driver($realtobits(AV5V_driver), AV5V);
drive_temperature_quad temperature_Temp_driver($realtobits(Temp_driver), Temp);
. . .
task Unclocked;
begin
#12;
INIT_POWER_UP_driver <= 1'b1;
#26;
SYS_RESET_driver <= 1'b1;
#380193;
AV5V_driver <= 0.1;
#19;
Temp_driver <= 5.75;
#19725;
Temp_driver <= 15.0;
#25;
Duration of Busy
Cycle
FAST_SIM = 1(default) FAST_SIM = 0
Reset 3 SYSCLK cycles 25 us
Program
4 us 8.4 ms
Erase
RESET operation System Reset de-asserted Busy de-asserted after 3 clock cycles
PROGRAM operation
PROGRAM operation
Ordering code
M1AFS-EMBEDDED-KIT @ $199
RoHS compliant
10/100 Ethernet interface
USB-to-UART interface
I2C interface
Built-in temperature monitor
Voltage potentiometer
RealView debug header
OLED 96x16 pixel display
4,000,000 SRAM