EB73 - iCEblink40-HX1K Evaluation Kit User`s Guide


iCEblink40-HX1K Evaluation Kit
User’s Guide
September 2012
Revision: EB73_01.1

iCEblink40-HX1K Evaluation Kit
User’s Guide
Introduction
Thank you for choosing the Lattice Semiconductor iCEblink™40-HX1K Evaluation Kit.
This guide describes how to begin using the iCEblink40-HX1K Evaluation Kit, an easy-to-use platform for rapidly
prototyping designs using the iCE40 FPGA.
Features
• High-performance, low-power iCE40HX1K FPGA
• USB programming, debugging, virtual I/O functions, and power supply
• Four user LEDs
• Four capacitive-touch buttons
• 3.3 MHz clock source
• 1Mbit SPI serial configuration PROM
• Supported by Lattice iCEcube2™ design software
• 68 LVCMOS/LVTTL (3.3V) digital I/O connections on 0.1” through-hole connections
• Supports third-party I/O expansion boards and modules, including 3.3V Arduino Shield boards (requires additional sockets, not supplied)
Figure 1. iCEblink40-HX1K Evaluation Board and Major Hardware Features
USB Programming,
Debug and Power
Low Power iCE40
FPGA
68 User I/O Pins
(3.3V)
Capacitive Touch
Buttons
User LEDs
Software Requirements
Before using the iCEblink40 board, please be sure to download and install iCEcube2 release 2011.12 or later. This
and later versions include the programming software for the iCEblink40 board. Currently, the programming software
is only available for the Windows operating system.
http://www.latticesemi.com/products/designsoftware/icecube2/downloads.cfm
During the installation process, be sure to install the Adept USB Programming Software, as shown in Figure 2.
1. Make sure that Adept USB Programming Software is checked. This is the default setting.
2. Click Next.
2
iCEblink40-HX1K Evaluation Kit
User’s Guide
Figure 2. Select the Adept Programming Software for Installation
1
2
A few steps later, select the installation for the Adept programming software, as shown in Figure 3.
3. Make sure that both the Adept Runtime and Adept Application options are checked, which are the default
settings.
4. Click Next.
Figure 3. Adept Setup Options
3
4
Connecting to the iCEblink40 Evaluation Board
Before connecting the iCEblink40 board, be sure to download and install a supported version of the iCEcube2 software.
Connect the iCEblink40 evaluation board to your PC using the USB cable provided. The USB connector on the
board is labeled with reference designator J3 and is located in the upper left corner. Once connected, the red
power-good LED (LD1) adjacent to the USB connector illuminates. See Figure 4 to locate the power-good LED.
3
iCEblink40-HX1K Evaluation Kit
User’s Guide
Power and Configuration Status LEDs
The iCEblink40 evaluation board has two status LEDs, as shown in Figure 4. These two status LEDs indicate the
current status of the iCEblink40 board, as listed in Table 1. The red LED, LD1, located near the USB connector indicates if the USB power supply, the 3.3V supply, and the 1.2V supply are within the specified ranges.
The yellow LED, LD6, located below the FPGA indicates whether the FPGA is configured properly. This LED lights
up when the FPGA is correctly loaded with a valid bitstream.
Figure 4. iCEblink40 Status LEDs
Power-Good LED (LD1)
(Red LED)
iCE40HX1K
VQ100
FPGA Configuration
Done LED (LD6)
(Yellow LED)
Table 1. iCEblink40 Status LED Descriptions
Power-Good
LED (LD1)
Configuration DONE
LED (LD6)
On
On
Off
Off
Description
The board is powered, the FPGA successfully configured and the FPGA
application is operating.
Board is unpowered. Connect the board to a computer USB port, a powered hub, or a USB-based wall plug.
If board is plugged in and previously operating, indicates that an SPI
Flash programming operation is in progress
The board is powered but the FPGA is not yet configured.
On
Off
Off
On
ACTION: Program the onboard SPI Flash PROM with a valid
FPGA configuration bitstream.
ERROR: The board is powered but there is a problem with the USB
power supply or with the on-board regulator.
4
iCEblink40-HX1K Evaluation Kit
User’s Guide
Pre-programmed Demonstration Design
The iCEblink40 board comes preprogrammed with a demonstration application. The application supports two interfaces.
1. Control the LEDs from the four capacitive touch buttons on the board itself.
2. Control the LEDs and other internal logic using the USB-based I/O expansion interface.
Operating the Capacitive Touch Buttons
Upon power up, the green LEDs on the board scroll in an upward pattern, as described in Figure 5. Pressing any of
the capacitive touch buttons stops the LEDs from scrolling and places the board in a different operating mode.
Figure 5. Preprogrammed Demonstration Design
LEDs Scroll Upward
1. Power On
Green LEDs scroll upward.
2. Press any button to enter
LED Toggle Mode.
Toggle LED with Button Press
3. Press a button to toggle the
associated LED on or off.
If no button is pressed within
five seconds, the board returns
to Scroll LEDs Mode.
In the second operating mode, toggle individual LEDs on and off by pressing the associated capacitive touch button.
If no button was pressed during the last five seconds, the board returns to scrolling the LEDs.
The demonstration application is available for download from the Lattice website at: 
www.latticesemi.com/iceblink40-hx1k.
Virtual I/O Expansion Debugging Interface
The iCEblink40 board is powered and programmed via the USB interface. Additionally, the USB interface also provides a convenient means to monitor and control logic inside the FPGA, as shown in Figure 6. The USB controller
drives a byte-wide parallel port expander implemented within the FPGA, controlled by software running on the PC.
The Digilent ADEPT2 I/O Expansion screen, shown in Figure 7, provides a mix of virtual switches, pushbuttons,
LEDs, light bars, and 32-bit input and outputs.
5
iCEblink40-HX1K Evaluation Kit
User’s Guide
Figure 6. iCEblink40 Board Supports Virtual I/O Connections over USB
Debug I/O Expansion Core
Debug I/O Expansion Core
DB
LightBar[23:0]
ASTB
USB
Controller
LEDs[7:0]
Data[7:0]
Address Strobe
FromFPGA[31:0]
DSTB
Data Strobe
WRITE
Read/#Write
WAIT
To/From
FPGA
Switches[15:0]
Buttons[15:0]
Wait
ToFPGA[31:0]
FPGA
Control and monitor FPGA logic values
in real-time, over USB, from PC graphical interface
Digilent Adept 2
Figure 7. Digilent Adept 2 I/O Expansion Interface and FPGA Connections
VLightBar
To FPGA [31:0]
From FPGA [31:0]
23
0
VLEDs
15
14
13
12
11
10
9
8
7
6
5
4
3
2
1
0
15
14
13
12
11
10
9
8
2
1
0
VButtons
VSwitches
7
7
6
5
4
3
2
1
6
5
4
3
0
Using the Virtual I/Os in the Demo Application
By default, the virtual I/Os are disconnected and the USB controller’s I/O connections to the FPGA are high-impedance (Hi-Z).
To connect the virtual I/O, perform the following steps outlined in Figure 8.
1. From the Windows Start menu, select Start > All Program > Digilent > Adept > Adept.
2. Ensure that the Adept interface connects to the iCE40.
3. Click the I/O Ex tab.
6
iCEblink40-HX1K Evaluation Kit
User’s Guide
4. Click Start I/O. Remember, the associated I/O Expander design must be part of the compiled FPGA design
before the Virtual I/Os work.
5. If the virtual I/O expansion design is functioning correctly, the green virtual status LED will turn from red to
green.
Figure 8. Starting the Digilent Adept Virtual I/O Expansion Application
2
3
4
5
To disconnect the virtual I/O interface, simply click the Stop I/O button in the graphical interface.
Controlling the Physical LEDs from Virtual I/Os in the Demonstration Design
When active, the virtual I/Os optionally control the physical LEDs on the board, as shown in Figure 9. For example,
with the virtual I/Os active, change the position of virtual switch [7] (the bottom left switch in the graphical interface).
Note how the physical LEDs on the board change direction.
Change virtual switch [6] to the up position. Now, the physical LEDs are controlled by the virtual switches [3:0] and
virtual pushbuttons [3:0]. The values of the virtual switches are XORed together inside the FPGA. The virtual slide
switches set a specific value for the physical LEDs. The pushbutton momentarily inverts the value while the virtual
pushbutton is pressed in the graphical interface.
7
iCEblink40-HX1K Evaluation Kit
User’s Guide
Figure 9. Controlling the Physical LEDs from Virtual I/O
Virtual Switches
[7]
[3] [2] [1] [0]
Virtual Pushbuttons
[6]
[3] [2] [1] [0]
1: Scroll down
0: Scroll up
1: Control LEDs from Virtual I/Os
0: Control LEDs from FPGA
LD2
BTN1
LD3
BTN2
LD4
BTN3
LD5
BTN4
Physical Buttons
and LEDs
Direction
Controlling the Virtual Light Bar in the Demonstration Design
When the virtual I/Os are active, the virtual light bar lights up from left to right, controlled by logic inside the FPGA.
The virtual pushbuttons [15] and [14] control the light bar. Pushbutton [15] resets the light bar, clearing all the lights.
Pushbutton [14] forces the light bar to hold its current value.
Figure 10. Controlling the Virtual Light Bar
Lights Up from Left to Right
Light Bar
[15]
[14]
Reset
Light
Bar
Hold
Value
Controlling the Virtual LEDs in the Demonstration Design
The virtual I/O interface includes eight, round, green LEDs, as shown in Figure 11. The values displayed on these
virtual LEDs depends on the settings of virtual switches [9] and [8].
The eight LEDs are separated into left and right halves. When both virtual switches [9] and [8] are Low—the down
position—the left LEDs echo the scrolling pattern of the LEDs, regardless if a physical cap-sense button was
pressed. Use virtual switch [7] to reverse the direction of these LEDs. The right-most LEDs show the current toggle
status of the four physical cap-sense buttons.
Changing virtual switch [8] to High—the up position—the four left-most LEDs then show the current value of the
time-out counter than marks the five seconds after pressing a cap-sense button. Press a cap-sense button to reset
the timer and note that the toggle status of the physical button changes on the right-most LEDs. The timer resets
each time a physical button is pressed. Wait five seconds and the physical LEDs change back to the scrolling pattern.
8
iCEblink40-HX1K Evaluation Kit
User’s Guide
Figure 11. Controlling the Virtual LEDs
LEDs
[9]
[8]
[9]
[8]
[9]
[8]
Scrolling LED
pattern
Cap-sense
time-out counter
[3] [2] [1] [0]
Toggle value
of physical
cap-sense buttons
(push button to
change)
[3] [2] [1] [0]
When virtual switch [9] is High—in the up position—then the left LEDs are controlled by virtual switches [3:0] and
the right LEDs are controlled by virtual pushbuttons [3:0].
Virtual Values to and from FPGA in the Demonstration Design
The virtual I/O interface also includes a 32-bit value from the FPGA logic and a 32-bit value to the FPGA logic, as
shown in Figure 12. Two virtual switches, [14] and [15], control the behavior in of the virtual 32-bit values in the
demonstration design.
Figure 12. Virtual Values To and From the FPGA
To FPGA
0x1000ffff
From FPGA
efff0000
Send
Format: Hexadecimal
[15] [14]
No function
Continuously
increment
No function
Continuously
decrement
Input value
One’s complement
of input value
Input value
Reverse bit order
of input value
[15] [14]
[15] [14]
[15] [14]
[13]
Reset
Clocking Resources
The iCEblink40 board includes a Linear Technology LT1799 oscillator (X1 on the board and in the schematic) to
generate a 3.33 MHz clock.
FPGA Input
The output from the LT1799 oscillator feeds pin 13 of the iCE40HX1K FPGA. FPGA pin 13 is also the global buffer
input GBIN7.
9
iCEblink40-HX1K Evaluation Kit
User’s Guide
Supporting Other Frequencies
On the iCEblink40 board, the LT1799 produces a 3.3 MHz clock output by default. Other frequencies are possible
via simple modifications of the board using the 1x3 connections on JP2, as listed in Table 2.
Table 2. Selecting Other Oscillator Frequencies Using Jumper JP2
Clock Frequency
JP2 Setting
Jumper Position
3.33 MHz (default)
None
333 kHz
Upper Position
33.3 MHz
Lower Position
User LEDs
The iCEblink40 iCE40HX1K evaluation board includes four green user LEDs, located along the left side of the
board, as shown in Figure 1.
Operation
To light a user LED, drive the associated FPGA pin High, as shown in Table 3. To darken the LED, drive the associated FPGA pin Low.
Table 3. User LED Operation
Operation
FPGA Action
Light LED
Drive High (1)
Darken LED
Drive Low (0)
The LEDs may appear to glow slightly before the FPGA is configured or if the FPGA pin is unused. This is because
the FPGA I/Os have a soft pull-up resistor which may provide just enough current for the LED to glow dimly. To
completely turn off an LED, drive it Low.
FPGA Connections
The FPGA drives the user LEDs using the FPGA pins listed in Table 4. These same signals also connect to the J12
header located in the lower left corner.
10
iCEblink40-HX1K Evaluation Kit
User’s Guide
Table 4. User LED Connections
Designator
Location
FPGA Pin
Header Connections
LD2
LD2 [59]
59
J12.1
LD3
LD3 [56]
56
J12.2
LD4
LD4 [53]
53
J12.3
LD5
LD5 [51]
51
J12.4
Capacitive Touch Buttons
The iCEblink40 iCE40HX1K evaluation board has four capacitive-touch buttons, located toward the left side of the
board, as shown in Figure 1. These buttons have dedicated connections only to the FPGA. These signals go
nowhere else on the board and are not available on any of the breakout headers.
FPGA Connections
Table 5 lists the four capacitive touch buttons on the iCEblink40 board and the associated FPGA pins.
Table 5. Capacitive Touch Buttons
Designator
Location
FPGA Pin
BTN1
BTN1 [60]
60
BTN2
BTN2 [57]
57
BTN3
BTN3 [54]
54
BTN4
BTN4 [52]
52
Operation
Figure 13 shows the circuit used for each capacitive-touch button. Each button is attached to one I/O pin on the
FPGA. Each signal line includes a 100 k pull-up resistor to 3.3V and a 100 pF capacitor down to ground.
Figure 13. Example Capacitive Touch Button Circuit
I/O Pin
Capacitive
Touch Button
Sample
100 kΩ
Value
100 pF
Figure 15 shows the general overall flowchart for the demonstration design to read the value on a capacitive touch
button.
The sampling signal drives the voltage on the capacitive-touch button to ground in order to bleed of any residual
charge as shown in Figure 14. After a period of time, depending on the button sample frequency, the button is
allowed to float High.
Once the FPGA output goes to Hi-Z (high-impedance, floating, three-state), the 100k pull-up resistor to 3.3V
charges the 100 pF capacitor. After about an RC time constant ( or tau), the voltage on the pad exceeds the input
switching threshold of the FPGA. A finger pressed against the capacitive-touch button adds about another 5 pF of
capacitance, increasing the RC constant and delaying the Low-to-High transition for a pressed button.
11
iCEblink40-HX1K Evaluation Kit
User’s Guide
Figure 14. Capacitive Touch Timing Examples
Sampling
Signal
Drive pad to ground
Button:
No Finger
Allow pad to
float High
Switching
Threshold
Button Value:
No Finger
τ = RCBUTTON
Time delta between
pressed and unpressed button
~300-500 ns
Button:
Finger Press
Switching
Threshold
τ = R(CBUTTON + CFINGER)
Button Value:
Finger Press
The switching time difference between an unpressed and one or more pressed buttons is roughly 300 to 500 ns.
Using the 3.33 MHz input, this amounts to a one clock delay difference between an unpressed and pressed buttons.
The simple circuit used on the iCEblink40 board detects simultaneous button presses on up to three of the capacitive-touch buttons. Pressing all four buttons is the same as pressing no buttons.
12
iCEblink40-HX1K Evaluation Kit
User’s Guide
Figure 15. iCEblink40 Demo Application Capacitive Touch Button Flowchart
Start
Drive pin connected to
capacitive button Low long
enough to guarantee that
the pin is at GND, despite
the attached RC network.
Force pin to Hi-Z. The
external pull-up resistor pulls
the pin High and charges
the capacitor.
Did any pin
go High?
Yes
Wait one 3.3 MHz clock
period (300 ns).
Sample all pin values.
Yes
No
Are all
buttons
High?
Did pin
value change from
last sample?
Yes
Toggle pin value
13
iCEblink40-HX1K Evaluation Kit
User’s Guide
User I/O Connections
Figure 16 shows the location of the 3.3V-compatible digital I/O connections on the iCEblink40 board. Each connection shows the pin number of the FPGA I/O pin that attaches to the connection. Likewise, Table 6 lists the various
I/O headers and their designed usage.
Figure 16. Location of the 3.3V Digital I/O Connections and the FPGA Pin Number
[ 18]
GND
[ 12]
[ 99]
[ 96]
[ 94]
[ 91]
[ 89]
[ 86]
[ 83]
[ 81]
[ 79]
[ 74]
[ 72]
[ 69]
[ 66]
[ 87]
[ 85]
[ 82]
[ 80]
[ 78]
[ 73]
[ 71]
[ 68]
3.3V Arduino Shield Compatible
[ 19]
[ 16]
[ 15]
[ 100]
[ 97]
[ 95]
[ 93]
[ 90]
Digital I/O (3.3V)
Digital I/O (3.3V)
3.3V
GND
[ 7]
[ 8]
[ 9]
[ 10 ]
Dou ble PMOD12
[ 1]
[ 2]
[ 3]
[ 4]
PMOD
SPI PROM
Connections
[ 49 ]
[ 45 ]
[ 46 ]
[ 48 ]
GND
3.3V
PMOD
PMOD12
3.3V
GND
[ 20 ]
[ 21 ]
[ 24 ]
[ 25 ]
[ 33 ]
[ 28 ]
[ 27 ]
[ 26 ]
PMOD
PMOD
PMOD
[ 29]
[ 34]
[ 37]
[ 41]
[ 63]
[ 65]
Double-wide Digilent 2x6 Header
Digilent 2x6 Header
Double PMOD 12
PMOD12
PMOD
Digital I/O (3.3V)
Digilent 1x6 Header
14
PMOD
Clocks
User LEDs
PMOD1 2
PMOD
[ 13 ]
[ 33 ]
[ 30]
[ 36]
[ 40]
[ 42]
[ 62]
[ 64]
GND
3.3V
PMOD
GND
3.3V
[ 51]
[ 53]
[ 56]
[ 59]
PMOD12
iCEblink40-HX1K Evaluation Kit
User’s Guide
Table 6. Digital I/O Headers and Their Functions
I/O Header
Group
Header
Type
Location
Function
J2
2x8 0.1” centers
Top edge, middle
3.3V digital I/O. Compatible with 3.3V Arduino Shield boards.
J4
2x8 0.1” centers
Top edge, left side
3.3V digital I/O. Compatible with 3.3V Arduino Shield boards.
J1
2x6 0.1 centers
Left edge, top
3.3V digital I/O. 3.3V digital I/O. Compatible with Digilent 1x6 and
2x6 PMod modules. Also supports double PMod12 modules
when used with header J6.
J6
2x6 0.1 centers
Left edge bottom
3.3V digital I/O. Compatible with Digilent 1x6 and 2x6 PMod modules. Also supports double PMod12 modules when used with
header J1.
J7
1x6 0.1 centers offset Left edge, top
Production programming of USB controller.
J11
1x6 0.1 centers offset Middle, toward left
3.3V digital I/O. Connections between the mobile FPGA and the
SPI PROM. Compatible with Digilent 1x6 PMod modules.
J5
2x8 0.1” centers
Bottom edge, right side
3.3V digital I/O. Portions compatible with Digilent 1x6 and 2x6
PMod modules. Portions also compatible with 3.3V Arduino
Shield boards.
JP3
1x2 0.1” centers
Middle, to left of
FPGA
3.3V digital I/O. Clock connections from the LTC1799 oscillator
(GBIN7) and possible into GBIN2.
J12
1x6 0.1” centers
Bottom edge, left side
3.3V digital I/O. Connections to the user LED I/O. Compatible
with Digilent 1x6 Pmod modules.
Supported Pmod Peripheral Modules
As shown in Figure 16, the iCEblink40 board supports a variety of Pmod peripheral modules for easy I/O expansion. Table 7 lists the 0.1” through-hole headers on the iCEblink40 board that support Pmod modules. Pmod modules come in a few different form factors and each Pmod header includes power and ground supplies. Figure 17
shows the how the different Pmod form factors interrelate. The easiest way to support a Pmod module is to add the
appropriate female socket listed, or an equivalent. Straight-through or right-angle through-hole sockets are listed.
Male headers are also possible solutions when using the interface cable provided with most Pmod modules.
Table 7. Pmod Module Headers
Female Socket (Manufacturer/Part Number)
Header
J1, J12
J5
Type
Straight-through
Right-angle
2x6 header on 0.1” centers. Each is a Pmod12 header that
supports two six-pin Pmod modules. Both together form a
double-wide Pmod connection.
Sullins Connector
Solutions
PPPC062LFBN-RC
Sullins Connector
Solutions
PPPC062LJBN-RC
2x8 header on 0.1” centers. The left side of header J5 forms
a Pmod12 header, as shown in Figure 16. A 2x6 header similar to J1, J12 can also be used but must be mounted toward
the right end of the holes as marked.
Sullins Connector
Solutions
PPPC082LFBN-RC
Sullins Connector
Solutions
PPPC082LJBN-RC
As shown in Figure 17, a Pmod module has six connections—four I/O plus power and ground. A Pmod12 module
has 12 connections and the module is effectively two six-pin Pmod modules stacked together. Finally, a doublewide Pmod12 consists of two Pmod12 headers spaced apart. Most of the Pmod modules also include interface
cables to allow easy connection to other header types.
15
iCEblink40-HX1K Evaluation Kit
User’s Guide
Figure 17. Pmod Module Types
1
1
Pmod12
I/O
Pmod Pmod
I/O
3.3V
GN D
Pmod
3.3V
GND
Pmod12
Pmod12
Pmod Pmod
1
3.3V
GND
I/O
Pmod12
1
Pmod Pmod
3.3V
I/O
GND
Double-wide Pmod12
For a complete list of Pmod peripheral modules, visit the Digilent web site.
www.digilentinc.com/Products/Catalog.cfm?NavPath=2,401&Cat=9
Arduino Shield Board Support
The iCEblink40 board also mechanically and electrically supports select 3.3V Arduino Shield boards popular in the
microcontroller development community. The Shield connections are located on headers J4, J2, J8 and a portion of
J5 as shown in Figure 18. Headers jumper J4 and J2 are 3.3V digital I/O connections. Header J8 provides power
connections to the Shield board. The left side of header J5 also provides 3.3V digital I/O but the 3.3V and GND
connections do not connect to the Shield board.
Figure 18. Arduino Shield Board Connections
Arduino Shield Connections
iCE40HX1K
VQ100
Required Header Sockets
To support Arduino Shield boards, the indicated headers must be loaded with female socket headers on 0.1” headers, as listed in Table 19.
16
iCEblink40-HX1K Evaluation Kit
User’s Guide
Table 8. Sockets to Support Arduino Shield Boards
Header(s)
Description
Quantity
Manufacturer/Part Number
J2, J4, J5
2x8 female header socket on 0.1” centers
3
Sullins Connector Solutions
PPPC082LFBN-RC
J8
1x6 female header socket on 0.1” centers
1
Sullins Connector Solutions
PPPC061LFBN-RC
Tested Arduino Boards
Figure 19 shows the Arduino Shield boards have been tested for basic compatibility. Other Arduino Shield boards
may also be compatible.
Figure 19. Compatible Arduino Shield Boards
chipKITBasic I/O Shield
chipKIT Pmod Shield-Uno
USB Interface
The iCEblink40 board is powered by connecting the board to a computer USB port, a power USB hub, or a USBbased AC adapter, commonly used in consumer electronics. A typical USB port provides up to 500 mA at 5V, providing up to 2.5W of total power. The iCE40HX1K consumes SIGNIFICANTLY LESS power, even when operating
at full performance. However, be careful when using the board to power off-board peripheral funds.
Connector
The USB connector to the board is located in the upper left corner, labeled J3. The board connects using a standard USB cable with a male mini-B connector.
Power Supply
Figure 20 shows the iCEblink40 power supply circuit that derives power from the USB mini-B connector (J3). The
USB connector provides up to 500 mA at +5V DC. An Analog Devices ADP2140 regulator generates +1.2V for the
FPGA core VCC and +3.3V for all I/O connections. The regulator also indicates when power is good and lights up
the red power-good LED (LD1).
17
iCEblink40-HX1K Evaluation Kit
User’s Guide
Figure 20. iCEblink40 USB Power Supply Circuit
Power-Good LED
(LD1)
+5V
Mini-B USB
Connector (J3) (500 mA)
(JP1)
Analog Devices
+1.2V
VCC
ADP2140
(300 mA)
Voltage
Regulator
+3.3V
(600 mA)
iCE40HX1K
FPGA
VCCIO
Configuration
Done LED (LD6)
Jumper JP1 provides a convenient location from which to measure core power to the FPGA.
SPI Flash Programming
The USB interface also provides Flash programming for the on-board SPI PROM, as described in “Programming
the iCEblink40 Board” below.
Digilent Parallel Port (DPP)
The Digilent Parallel Port (DPP) interface is used for virtual I/O and debugging using a USB connection to the
board from a Windows PC. See “Virtual I/O Expansion Debugging Interface” on page 5 for additional information.
1Mbit SPI Configuration PROM
The configuration bitstream for the iCE40 FPGA is stored in a M25P10A 1Mbit SPI serial Flash PROM. The PROM
is large enough to hold two configuration images and supports the iCE40 WarmBoot feature, if so enabled within
the FPGA application. The PROM is physically located on the back side of the board.
Programming the iCEblink40 Board
The iCEblink40 board includes on-board USB-based programming support either from the Lattice iCEcube2 software or using a command from a console window or DOS box.
From iCEcube2
Figure 21 shows the command sequence for programming the SPI Flash PROM on the iCEblink40 board using the
iCEcube2 development software.
18
iCEblink40-HX1K Evaluation Kit
User’s Guide
Figure 21. Programming the iCEblink40 Board from iCEcube2
3
1
4
2
5
6
1. Select Tool > Programmer from the iCEcube2 menu bar.
2. Click the dropdown button (
) under Programming Hardware.
3. Select iCEblink40.
4. The bitstream file should already be set appropriately based on the iCEcube2 project settings. If not, click
Image Files Settings to select the configuration bitstream file.
5. Click Execute to program the iCEblink40 board.
If all is working correctly, the power-on LED and the configuration done LED will both go out momentarily as
iCEcube2 programs the on-board SPI Flash PROM. After programming is complete, both LEDs should light up
again and the FPGA will execute the new configuration image.
From Command Line
The iCEblink40 programming software can also be executed from a console window or DOS box. To open a console window or DOS box, click the Start button and type cmd in the textbox immediately above the Start button.
Executable Location
After installation, the programming software executable is called iceutil.exe and is located in the \SbtTools\sbt_backend\bin\win32\opt directory. The iecutil.exe executable can be copied into the same directory as
the FPGA bitstream image or can be pointed to on the command line.
FPGA Bitstream Configuration File
The required bitstream image is part of the iCEcube2 project. Multiple versions of the bitstream are stored in the
<projname>_Implmnt\sbt\outputs\bitmap directory. The raw hexadecimal version of the bitstream is called
<projname>_bitmap.hex. The alternate format of the same information is an Intel hexadecimal file called <projname>_bitmap_int.hex.
Raw Hexadecimal Command Example
<path>/iceutil -d iCE40 -res -cr -m M25P10A -fh -w <path/projname>_bitmap.hex
Intel Hexadecimal Command Example
<path>/iceutil -d iCE40 -res -cr -m M25P10A -fi -w <path/projname>_bitmap_int.hex
19
iCEblink40-HX1K Evaluation Kit
User’s Guide
Help
<path>/iceutil -help
Testing Core Power
Jumper JP1 provides the ability to measure core power consumption by the FPGA. Two power measurement methods are supported.
Note: The iCEblink40 HX1K evaluation board uses an early version of the iCE40HX1K silicon that has higher than
expected static current consumption. Although the demonstration application consumes less than 500 µA, the production silicon will consume even less current. Similarly, the lower power iCE40LP1K devices use even less power
than the iCE40HX1K FPGA.
Easy Method Using a Multimeter
Connect the iCEblink40 board through your high-accuracy multimeter. Use a meter with a minimum of 10,000
counts; 50,000 counts or more is recommended for better accuracy.
To take a quick measurement, follow these steps.
1. Disconnect power to the iCEblink40 board by removing the USB cable connection, either at the board or at the
computer.
2. Remove the jumper JP1, which isolates the FPGA’s core supply from the 1.2V supply on the board.
3. Connect your multimeter’s alligator or test clips to the stake pins on header JP1.
4. Configure the multimeter to measure current using its highest mA or Amp range. This setting typically has the
lowest voltage drop internally within the meter.
5. Re-connect the USB cable that supplies power to the iCEblink40 board and configure the FPGA device if necessary.
6. Observe the power reading on the multimeter. At low clock rates, which results in lower power consumption,
switch the meter to a lower amperage setting for better accuracy. However, this also may increase the resistance across the meter leads. Using too low of a meter setting causes a large voltage drop within the meter,
potentially violating the minimum input voltage specification to the FPGA device.
7. The value measured by the multimeter is a current. Convert the measurement to power using Equation 1. The
voltage is the operating voltage, the voltage across the jumper. This value can be accurately measured with a
second multimeter to show the voltage drop across the first. However, just measuring the initial voltage, before
taking any current readings, usually provides acceptable accuracy and the voltage drop across the meter is
generally small.
Power = Current  Voltage
(1)
Although this method is easy, here are a few caveats and pointers.
• Always start at the highest current setting for your meter. Using too small a setting may damage your
meter! After determining the maximum current range for your measurement, then you can safely use the appropriate lower current setting.
• The voltage drop across the meter leads may violate the minimum supply voltage specification for the mobileFPGA device. To determine the voltage drop, use a second multimeter to measure either the voltage across the
first meter’s leads during a test or the resistance between the first meter’s leads.
• Using the highest current measurement setting typically results in the lowest voltage drop.
20
iCEblink40-HX1K Evaluation Kit
User’s Guide
Using High-Precision, Small-Value Resistors
For more-accurate, time-sensitive measurements, place a low-value resistor across the jumper test point. According to Ohm’s Law, the current passing through the resistor produces a voltage drop. Measure the voltage differential across the resistor during expected operation. Convert the measurement to power using Equation 2. The
voltage is the measured voltage across the resistor; the resistance is the value of the resistor.
2
 Voltage 
Power = ---------------------------Resis tan ce
(2)
The following are a few guidelines on selecting a resistor.
• Use a high-precision resistor.
• The resistor must handle the power dissipated under the anticipated test conditions.
• Too small a resistor value may result in too small a voltage difference across the resistor to measure with your
test equipment.
• Too large a resistor value may result in too large of a voltage difference across the resistor. Too large a voltage
drop might violate the minimum voltage specifications for the FPGA device.
Figure 22 shows an example header block designed to fit over one of the jump locations. Measure the voltage drop
across the low-value resistor, either with a voltmeter or with data acquisition equipment.
Figure 22. Resistor Header Block
Voltmeter
Low Ω, High
Precision Resistor
This method is recommended for taking power measurements over time.
Mechanical Specifications
Figure 23 shows the mechanical dimensions for the iCEblink40 board, including the location of the four mounting
holes. With a jumper installed on JP1, the board height is approximately 0.700 inches high, including the four rubber feet mounted on the bottom side of the board.
21
iCEblink40-HX1K Evaluation Kit
User’s Guide
Figure 23. iCEblink40 HX1K Board Mechanical Dimension
iCE40HX1K
VQ100
Ordering Information
Description
Ordering Part Number
iCEblink40-HX1K Evaluation Kit
China RoHS Environment-Friendly
Use Period (EFUP)
ICE40HX1K-BLINK-EVN
Technical Support Assistance
Hotline: 1-800-LATTICE (North America)
+1-503-268-8001 (Outside North America)
e-mail: [email protected]
Internet: www.latticesemi.com
Revision History
Date
Version
Change Summary
May 2012
01.0
Initial release.
September 2012
01.1
Nomenclature change from “mobileFPGA” to “FPGA”.
© 2012 Lattice Semiconductor Corp. All Lattice trademarks, registered trademarks, patents, and disclaimers are as
listed at www.latticesemi.com/legal. All other brand or product names are trademarks or registered trademarks of
their respective holders. The specifications and information herein are subject to change without notice.
22
D
C
B
A
AT9 0US B2
C3
1nF/250V
J3
S4
S3
S1
G
ID
D+
DV
S2
US B-AS TB
US B-DS TB
US B-WRITE
US B-WAIT
26
25
23
22
GND
La ttice Semi
GND
US B3 V3
D+
C38
0.1uF
R3 7
22
C41
1uF
27
29
30
1
Chinese ROHS
R3 8 22
VCAP
D+/SCK
D-/SDATA
C44
0.1uF
AT9 0US B2 -16M U
C37
0.1uF
ROHS
GND
C35
0.1uF
VCC_ 3V3
US B-DB0
US B-DB1
US B-DB2
US B-DB3
US B-DB4
US B-DB5
US B-DB6
US B-DB7
US B-ON
6
7
8
9
10
11
12
13
CE
24
2
1
GND
AT9 0US B2
PC1/RES ET
PC0/XTAL2
XTAL1
IC3 D
3.0K
R2 8
US B5 V0
US B-S S_B
US B-S CK
US B-M OS I
US B-M IS O
D+
DUS B5 V0
GND
5
14
15
16
17
18
19
20
21
Atm el USB Pr ogr amming Block
US B5 V0
US B3 V3
D-
IC3 C
NOT STUF FED
1x6
IS P-RES ET
1
US B-M OS I
2
US B-M IS O
3
US B-S CK
4
GND
5
US B3 V3
6
J7
AT9 0US B2 -16M U
PD0/OC0B/INT0
PD1/AIN0 /INT1
PD2/RXD1 /AIN1 /INT2
PD3/TXD1 /INT3
PD4/INT4
PD5/XCK/P CINT1 2
PD6/RTS /INT6
PD7/CTS /HWB/T0 /INT7
AT9 0US B2
IC3 B
PC4/PCINT1 0
PC5/OC1B/PCINT9
PC6/OC1A/PCINT8
PC7/INT4 /ICP 1/CLK0
AT9 0US B2 -16M U
S1
5
4
3
2
1
S2
IC3 A
PC2/PCINT1 1
AT9 0US B2
AT9 0US B2 -16M U
PB0 /SS/PCINT0
PB1 /SCLK/P CINT1
PB2 /PDI/M OS I/PCINT2
PB3 /PDO/M IS O/PCINT3
PB4 /T1/PCINT4
PB5 /PCINT5
PB6 /PCINT6
PB7 /OC0A/OC1 C/PCINT7
GND
GND
R4
1M
S4
S3
31
R1 0
200
OUT
SYS CLK
C43
15pF
2
3.33 MHz (DEFAULT)
33.33 MHz
333 kHz
IS P-RES ET
8M Hz
X2
C42
15pF
200
R3 5
R3 2
10k
DIV= OPEN
DIV= VCC_ 3V3
DIV= GND
SET
V+
5
iCE4 0-DB7
iCE4 0-DB6
iCE4 0-DB5
iCE4 0-DB4
iCE4 0-DB3
iCE4 0-DB2
iCE4 0-DB1
iCE4 0-DB0
iCE4 0-WAIT
iCE4 0-WRITE
iCE4 0-DS TB
iCE4 0-AS TB
iCE4 0-CDONE
Ba sic oscilla tor
X1
200
200 R2 5
R2 4 200
200 R2 3
R2 1 200
200 R2 0
R1 9 200
200 R1 7
R1 6 200
200 R1 5
R1 4 200
200 R1 3
R1 2
US B-ON
iCE4 0-CRES ET
iCE4 0-SI
iCE4 0-SO
iCE4 0-SCK
iCE4 0-SS_B
LD1
R3
10
C1
8.2uF
2
10
5
9
8
7
NOT STUF FED
VCC_ 3V3
2
4 DIV
GND DIV
GND
LTC1 799CS 5#TRP BF
JP2
3
1
75
R8
200
R7
75
R6
Power-On LED
iCE4 0-CRES ET
R1
4.7K
VCC_ 3V3 US B5 V0
C12
10nF
C30
0.1uF
GND
C29
1uF
PM OD2-4
PM OD2-3
PM OD2-2
PM OD2-1
PM OD1-4
PM OD1-3
PM OD1-2
PM OD1-1
DS C1-11
SYS CLK
DS C1-12
DS C1-14
DS C1-15
DS C1-16
PM OD3-4
PM OD3-3
PM OD3-2
PM OD3-1
GND
C11
0.1uF
GND
4
2
1
2
3
4
7
8
9
10
12
13
15
16
18
19
20
21
24
25
1uH
L1
C4
10uF
C6
1uF
0
C32
10nF
31
38
VCCIO_ 2
VCCIO_ 2
IC2 B
VCC_ 3V3
J6
VCC_ 3V3
J1
NOT STUF FED
JP1
C8
10nF
GND
3
VCC
VCC
VCC
VCC
C22
0.1uF
VP P_2V5
VP P_FAS T
C21
0.1uF
75
76
11
35
61
77
C23
10nF
VCC_ CORE
4
GND
R2 7
4.7K
M 25P10-SS_B
iCE4 0-S CK
iCE4 0-S O
LD6
R3 0
10
R2 6
4.7K
R3 4
10K
WP
C26
10nF
4
1
3
6
5
C39
1uF
CS
WP
SCK
SDI
C40
10nF
iCE4 0VQ1 00
SPI_ VCC
R3 3
10K
C34
10nF
GND
C33
1uF
50
IC2 C
1x6
1
2
3
4
5
6
J8
GND
5
NOT STUF FED
IC2 D
HLD
J4
R3 6
10K
J2
C18
10nF
iCE4 0-S S_B
M 25P10-S S_B
iCE4 0-WAIT
SYS CLK
VCC_ 3V3
R3 9
0
J10
1x2
1
2
NOT STUF FED
JP3
NOT STUF FED
DS C2-07
DS C2-06
DS C2-05
DS C2-04
DS C2-03
DS C2-02
DS C2-01
IM OD-1
IM OD-2
IM OD-3
IM OD-4
CAP BTN1
LED1
CAP BTN2
LED2
CAP BTN3
LED3
CAP BTN4
LED4
C17
10nF
NOT STUF FED
GND
LED1
LED2
LED3
LED4
LED3
LED2
1x6
1
2
3
4
5
6
J12
NOT STUF FED
LED1
Foot
F3
Foot
F1
Foot
F4
Foot
F2
5
iCE4 0-SS_B
iCE4 0-SO
iCE4 0-SI
iCE4 0-SCK
GND
VCC_ 3V3
1x6
1
2
3
4
5
6
J11
Date:
File:
J5
VCC_ 3V3
Number
LED4
390
R3 1
390
R2 2
390
R1 1
390
R5
LD5
GND
C28
100pF
R1 8
100K
5%
GND
C36
100pF
R2 9
100K
5%
VCC_ 3V3
CAP BTN4
LD4
GND
C27
100pF
R9
100K
5%
VCC_ 3V3
CAP BTN3
LD3
GND
C5
100pF
R2
100K
5%
VCC_ 3V3
CAP BTN2
LD2
CAP BTN1
VCC_ 3V3
6
1
1
1
1
6013-500-002
5/3/2012
C:\Use rs\..\iCE4 0_Ev al_Board.S chDoc
6
Sheet f o 1/1
Drawn By: SK/GA
B .0
Revision
No Load
CapButton
o
BTN4
No Load
CapButton
o
BTN3
No Load
CapButton
o
BTN2
No Load
CapButton
o
BTN1
iC Eblink40HX1 Evaluation Kit
Tabloid
Size
Title
NOT STUF FED
Optional SPI PM OD support requested by Silic onBlu e field sales.
iCE4 0VQ1 00
74
73
72
71
69
68
66
65
64
63
62
60
59
57
56
54
53
52
51
C16
0.1uF
GND
C15
1uF
NOT STUF FED
M echanically compatible with Basic I/O shield.
PIO1
PIO1
PIO1
PIO1
PIO1
PIO1
PIO1
PIO1
PIO1
GBIN2 /PIO1
GBIN3 /PIO1
PIO1
PIO1
PIO1
PIO1
PIO1
PIO1
PIO1
PIO1
M 25P10-AVM N6
7
2
iCE4 0-SI
IC4
HOLD
GND
iCE4 0-SS_B
NOT ST UFFE D
SDO
VCC_ 3V3
GND
SB0 503EC-TR
D1
C25
10nF
US B5 V0
iCE4 0-CRES ET
VCC_ 3V3
C24
10nF
iCE40HX1K
iCE4 0VQ1 00
GND
GND
GND
GND
GND
GND
GND
GND
GND
GND
IC2 F
C20
1uF
GND
5
17
23
32
39
47
55
70
84
98
C19
1uF
IC2 E
iCE4 0VQ1 00
VCCIO_ 0
VCCIO_ 0
GND
88
92
VCC_ 3V3
VCC_ 3V3
C9
10nF
iCE4 0VQ1 00
GND
C7
0.1uF
C2
1uF
iCE4 0VQ1 00
PIO3 /DP00A
PIO3 /DP00B
PIO3 /DP01A
PIO3 /DP01B
PIO3 /DP02A
PIO3 /DP02B
PIO3 /DP03A
PIO3 /DP03B
PIO3 /DP04A
GBIN7 /PIO3 /DP04B
GBIN6 /PIO3 /DP05A
PIO3 /DP05B
PIO3 /DP06A
PIO3 /DP06B
PIO3 /DP07A
PIO3 /DP07B
PIO3 /DP08A
PIO3 /DP08B
C14
10nF
IC2 A
C13
10nF
C31
10nF
IC1
FB
SW
VOUT2
6
M echanically compatible with Double Wide PM OD
C10
1uF
VIN1
VIN2
PG
EN1
EN2
ADP 2140ACP Z3312R7
3
Power Measurement Test Point
SHUNT
VCC_ 1V2
VCC_ CORE
R4 0 No Load
iCE 40-A ST B
iCE 40-DST B
iCE 40-WR IT E
iCE 40-WA IT
GND
1
4
V CC
GND
3
32
A V CC
A GND
GND
PGND
3
P
1
Pmod 2x6
PMOD2-1
1 7
PMOD2-2
2 8
PMOD2-3
3 9
PMOD2-4
4 10
GND
5 11
6 12
PM OD1-1
PM OD1-2
PM OD1-3
PM OD1-4
GND
UV CC
PA D
P
UGND
28
6
14
22
V CCIO_3
V CCIO_3
V CCIO_3
26
27
28
29
30
33
34
36
37
40
41
42
iCE 40-A ST B
iCE 40-DST B
iCE 40-WR IT E
iCE 40-DB 7
iCE 40-DB 6
iCE 40-WA IT
iCE 40-DB 5
iCE 40-DB 4
iCE 40-DB 3
iCE 40-DB 2
iCE 40-DB 1
iCE 40-DB 0
PI O2
PI O2
PI O2
PI O2
PI O2
GB IN5/PIO2
GB IN4/PIO2
PI O2
PI O2
PI O2
PI O2/C
O2/CB
/ B SE L 0
PI O2/CB
O2/C
/ B SE L 1
DSC 1-10
DSC 1-09
DSC 1-08
DSC 1-07
DSC 1-06
DSC 1-05
DSC 1-04
DSC 1-03
DSC 1-02
DSC 1-01
DSC 2-16
DSC 2-15
DSC 2-14
DSC 2-13
DSC 2-12
DSC 2-11
DSC 2-10
DSC 2-09
DSC 2-08
PIO0
PIO0
PIO0
PIO0
PIO0
PIO0
PIO0
PIO0
GB IN0/PIO0
GB IN1/PIO0
PIO0
PIO0
PIO0
PIO0
PIO0
PIO0
PIO0
PIO0
PIO0
PI OS/SPI
OS/S
/ PI _SO
PI OS/S
OS/SPI
/ PI _SI
PI OS/S
OS/SPI
/ PI _SCK
PI OS/S
OS/SPI
/ PI _SS_B
45
46
48
49
58
67
V CC IO_1
V CC IO_1
100
99
97
96
95
94
93
91
90
89
87
86
85
83
82
81
80
79
78
CDONE
CR E SE T _B
43
44
iCE 40-CDONE
iCE 40-CR E SE T
Pmod 2x6
1 7
2 8
3 9
4 10
5 11
6 12
PM OD3-1
PM OD3-2
PM OD3-3
PM OD3-4
GND
8
V CC
GND
23
4
DSC1-15
GND
DSC1-11
DSC1-09
DSC1-07
DSC1-05
DSC1-03
DSC1-01
16 15
14 13
12 11
10 9
7
8
6
5
4
3
2
1
2x8
DSC 1-16
DSC 1-14
DSC 1-12
DSC 1-10
DSC 1-08
DSC 1-06
DSC 1-04
DSC 1-02
DSC2-15
DSC2-13
DSC2-11
DSC2-09
DSC2-07
DSC2-05
DSC2-03
DSC2-01
16 15
14 13
12 11
10 9
7
8
6
5
4
3
2
1
2x8
DSC 2-16
DSC 2-14
DSC 2-12
DSC 2-10
DSC 2-08
DSC 2-06
DSC 2-04
DSC 2-02
iCE 40-DB 6
iCE 40-DB 4
iCE 40-DB 2
iCE 40-DB 0
IMOD-4
IMOD-2
GND
16 15
14 13
12 11
10 9
8
7
6
5
4
3
2
1
2x8
iCE 40-DB 7
iCE 40-DB 5
iCE 40-DB 3
iCE 40-DB 1
IM OD-3
IM OD-1
GND
US B Mini AB
D
C
B
A
iCEblink40-HX1K Evaluation Kit
User’s Guide
Appendix A. Schematic
Figure 24. Schematic
iCEblink40-HX1K Evaluation Kit
User’s Guide
Appendix B. Bill of Materials (Major Components)
Table 9. Bill of Materials
Reference
Vendor
Part Number
Description
IC2
Lattice Semiconductor
iCE40HX1K-VQ100
iCE40 HX-series FPGA
IC1
Analog Devices
ADP2140ACPZ3312R7
Low-quiescent buck/LDO regulator (1.2V, 3.3V)
X1
Linear Technology
LTC1799CS5#TRPBF
Oscillator
IC4
Micron Technology
M25P10-AVMN6
1Mbit SPI serial configuration Flash PROM
IC3
Atmel Corporation
AT90USB162-16MU
USB programming and debugging interface
24