Terasic t-core User manual

Type
User manual
T-Core
User Manual
1
www.terasic.com
September 24, 2020
T-Core
User Manual
1
www.terasic.com
September 24, 2020
CONTENTS
Chapter 1 Introduction ..................................................................................................... 2
1.1 Package Contents ................................................................................................................................... 2
1.2 T-Core System CD ................................................................................................................................. 3
1.3 Layout and Components ........................................................................................................................ 3
1.4 Block Diagram of the Board .................................................................................................................. 5
1.5 Getting Help ........................................................................................................................................... 6
Chapter 2 Using the T-Core ............................................................................................ 7
2.1 Configuration of MAX 10 FPGA on T-Core .......................................................................................... 7
2.2 Clock Circuitry ..................................................................................................................................... 15
2.3 Using the Push-buttons, Switches and LEDs ....................................................................................... 16
2.4 Using WS2812B RGB LED ................................................................................................................. 18
2.5 Using 2x6 TMD GPIO Expansion Headers ......................................................................................... 21
2.6 1x10 A/D Converter and Analog Input ................................................................................................ 22
2.7 Using QSPI Flash ................................................................................................................................. 23
Chapter 3 Example Designs ........................................................................................... 25
3.1 T-Core Factory Configuration .............................................................................................................. 25
3.2 Control RGB LED in Nios II ............................................................................................................... 28
3.3 Control External RGB LED in Nios II ................................................................................................. 32
3.4 ADC Measurement ............................................................................................................................... 33
3.5 RISC-V ................................................................................................................................................. 36
Chapter 4 Programming the Configuration Flash Memory ..................................... 46
4.1 Internal Configuration .......................................................................................................................... 47
4.2 Using Dual Compressed Images .......................................................................................................... 49
Chapter 5 USB Blaster II Cable Feature .................................................................... 59
T-Core
User Manual
2
www.terasic.com
September 24, 2020
Chapter 1
Introduction
The T-Core presents a robust hardware design platform built around the Intel MAX 10 FPGA. The
MAX 10 FPGA is well equipped to provide cost effective, single-chip solutions in control plane or
data path applications and industry-leading programmable logic for ultimate design flexibility. With
MAX 10 FPGA, you can get lower power consumption / cost and higher performance. When you
need high-volume applications, including protocol bridging, motor control drive, analog to digital
conversion, and handheld devices, the T-Core MAX 10 FPGA is your best choice.
The T-Core development board includes hardware such as on-board USB Blaster II, QSPI Flash,
ADC-Header, WS2812B RGB LEDs and 2x6 TMD expansion header. By leveraging all of these
capabilities, the T-Core is the perfect solution for showcasing, evaluating, and prototyping the true
potential of the Intel MAX 10 FPGA.
T-Core also supports RISC-V CPU with on-board JTAG debug, it is an ideal platform for learning
RISC-V CPU design or embedded system design.
1
1.
.1
1
P
Pa
ac
ck
ka
ag
ge
e
C
Co
on
nt
te
en
nt
ts
s
Figure 1-1 shows a photograph of the T-Core package.
Figure 1-1 The T-Core package contents
T-Core
User Manual
3
www.terasic.com
September 24, 2020
The T-Core package includes:
The T-Core board
USB Mini-B Cable
Flat Ribbon Cable
1
1.
.2
2
T
T-
-C
Co
or
re
e
S
Sy
ys
st
te
em
m
C
CD
D
The T-Core System CD contains the documentation and supporting materials, including the User
Manual, reference designs and device datasheets.
User can download this System CD from the web (http://T-Core.terasic.com/cd).
1
1.
.3
3
L
La
ay
yo
ou
ut
t
a
an
nd
d
C
Co
om
mp
po
on
ne
en
nt
ts
s
This section presents the features and design characteristics of the board.
A photograph of the board is shown in Figure 1-2 and Figure 1-3. It depicts the layout of the board
and indicates the location of the connectors and key components.
Figure 1-2 Development Board (top view)
T-Core
User Manual
4
www.terasic.com
September 24, 2020
Figure 1-3 Development Board (bottom view)
This board has many features that allow users to implement a wide range of designed circuits, from
simple circuits to various multimedia projects.
The following hardware are provided on the board:
F
FP
PG
GA
A
D
De
ev
vi
ic
ce
e
MAX 10 10M50DAF484C7G Device
Integrated dual ADCs, each ADC supports 1 dedicated analog input and 8 dual function
pins
50K programmable logic elements
1,638 Kbits M9K Memory
5,888 Kbits user flash memory
144 18 × 18 Multiplier
4 PLLs
P
Pr
ro
og
gr
ra
am
mm
mi
in
ng
g
a
an
nd
d
C
Co
on
nf
fi
ig
gu
ur
ra
at
ti
io
on
n
On-Board USB Blaster II (Mini USB connector)
M
Me
em
mo
or
ry
y
D
De
ev
vi
ic
ce
e
QSPI Flash (Support RISC-V)
T-Core
User Manual
5
www.terasic.com
September 24, 2020
C
Co
on
nn
ne
ec
ct
to
or
rs
s
2x6 TMD GPIO Header
1x10 ADC Header
WS2812B RGB LED Expansion Header
S
Sw
wi
it
tc
ch
he
es
s,
,
B
Bu
ut
tt
to
on
ns
s
a
an
nd
d
L
LE
ED
Ds
s
4 Green LEDs
4 Dip Switches
2 Push Buttons with Debounced.
4 WS2812B RGB LED
P
Po
ow
we
er
r
5V DC input from USB or external power connector.
1
1.
.4
4
B
Bl
lo
oc
ck
k
D
Di
ia
ag
gr
ra
am
m
o
of
f
t
th
he
e
B
Bo
oa
ar
rd
d
Figure 1-4 gives the block diagram of the board. To provide maximum flexibility for the user, all
connections are made through the MAX 10 FPGA device. Thus, the user can configure the FPGA to
implement any system design.
Figure 1-4 Board Block Diagram
T-Core
User Manual
6
www.terasic.com
September 24, 2020
1
1.
.5
5
G
Ge
et
tt
ti
in
ng
g
H
He
el
lp
p
Here are the addresses where you can get help if you encounter any problem:
Terasic Inc.
9F., No.176, Sec.2, Gongdao 5th Rd, East Dist, Hsinchu City, 30070. Taiwan
Email: [email protected]
Tel.: +886-3-5750-880
Web: http://T-Core.terasic.com
T-Core
User Manual
7
www.terasic.com
September 24, 2020
Chapter 2
Using the T-Core
This chapter provides instructions to use the board and the peripherals description.
2
2.
.1
1
C
Co
on
nf
fi
ig
gu
ur
ra
at
ti
io
on
n
o
of
f
M
MA
AX
X
1
10
0
F
FP
PG
GA
A
o
on
n
T
T-
-C
Co
or
re
e
There are two types of configuration method supported by T-Core:
1. JTAG configuration: configuration using JTAG port.
JTAG configuration scheme allows you to directly configure the device core through JTAG pins -
TDI, TDO, TMS, and TCK pins. The Quartus Prime software automatically generates .sof files that
are used for JTAG configuration with a download cable in the Quartus Prime software program.
2. Internal configuration: configuration using internal flash.
Before internal configuration, you need to program the configuration data into the configuration
flash memory (CFM) which provides non-volatile storage for the bit stream. The information is
retained within CFM even if the T-Core board is turned off. When the board is powered on, the
configuration data in the CFM is automatically loaded into the MAX 10 FPGA.
JTAG Chain on T-Core Board
Figure 2-1 shows the JTAG interface of T-Core board, which uses the USB Blaster II (UB2) circuit
to connect to the host PC. The JTAG interface of the T-Core board can be divided into common
FPGA configuration and RISC-V applications. Users can configure or debug the MAX10 FPGA on
the T-Core through the UB2 interface and Quartus software on the host PC. You can also use the
UB2 circuit to download the binary file from the host PC to RISC-V application. The two position
switches on the SW2 can control whether the MAX10 FPGA and RISC-V application will appear in
the JTAG chain of the T-Core board.
T-Core
User Manual
8
www.terasic.com
September 24, 2020
Figure 2-1 The JTAG configuration scheme
Figure 2-2 The JTAG Switch for MAX10 FPGA and RISC-V
Figure 2-2 shows the factory settings of the SW2. The SW2.1 position is used for enable/disable
the MAX 10 FPGA in the JTAG chain. When set to ON, the MAX10 FPGA will appear in the
JTAG chain of T-Core. SW2.2 is the JTAG chain switch for RISC-V applications. If it is turned off,
the application will not appear in the JTAG chain. For more information about the RISC-V
application, please refer to section 3.5 for more information.
Table 2-1 is the setting of SW2 and its function.
Table 2-1 MAX10 and RISC-V JTAG Chain setting for SW2
SW2 Position
Description
RISC-V (SW2.2)
OFF
MAX10 and RISC-V off chain
ON
MAX10 off chain and RISC-V on chain
OFF
MAX10 on chain and RISC-V off chain
ON
MAX10 on chain and RISC-V on chain
T-Core
User Manual
9
www.terasic.com
September 24, 2020
Configure the FPGA in JTAG Mode
The following shows how the FPGA is programmed in JTAG mode step by step.
1. Open the Quartus Prime programmer, please choose Tools > Programmer. The Programmer
window opens. See Figure 2-3.
Figure 2-3 Programmer Window
2. Click Hardware Setup, as circled in Figure 2-3.
3. If it is not already turned on, turn on the USB-Blaster [USB-0] option under currently selected
hardware and click Close to close the window. See Figure 2-4.
T-Core
User Manual
10
www.terasic.com
September 24, 2020
Figure 2-4 Hardware Setting
4. Click Auto Detect to detect all the devices on the JTAG chain, as circled in Figure 2-5.
Figure 2-5 Detect FPGA device in JTAG mode
5. Select detected device associated with the board, as circled in Figure 2-6.
T-Core
User Manual
11
www.terasic.com
September 24, 2020
Figure 2-6 Select 10M50DA device
6. FPGA is detected, as shown in Figure 2-7.
Figure 2-7 FPGA detected in Quartus Prime programmer
T-Core
User Manual
12
www.terasic.com
September 24, 2020
7. Right click on the FPGA device and click “Change File to open the .sof file to be
programmed, as highlighted in Figure 2-8.
Figure 2-8 Open the .sof file to be programmed into the FPGA device
8. Open the output_files folder and select the .sof file to be programmed, as shown in Figure
2-9.
T-Core
User Manual
13
www.terasic.com
September 24, 2020
Figure 2-9 Select the .sof file to be programmed into the FPGA device
9. Click “Program/Configure” check box and then click “Start” button to download the .sof file
into the FPGA device, as shown in Figure 2-10.
Figure 2-10 Program .sof file into the FPGA device
T-Core
User Manual
14
www.terasic.com
September 24, 2020
Internal Configuration
The configuration data to be written to CFM will be part of the programmer object file (.pof).
This configuration data is automatically loaded from the CFM into the MAX 10 devices when
the board is powered up.
Please refer to Chapter 4: Programming the Configuration Flash Memory (CFM) for the
basic programming instruction on the configuration flash memory (CFM).
Figure 2-11 High-Level Overview of Internal Configuration for MAX 10 Devices
Status LED
The T-Core development board includes board-specific status LEDs to indicate board status. Please
refer to Table 2-2 for the description of the LED indicator. Please refer to Figure 2-12 for detailed
LED location.
Figure 2-12 Status LED position
T-Core
User Manual
15
www.terasic.com
September 24, 2020
Table 2-2 Status LED
Reference
LED Name
Description
LED4
JTAG RX
Illuminate when data is transferred from USB Host to JTAG.
LED5
JTAG TX
Illuminate when data is transferred from JTAG to USB Host.
LED6
CONF_DONE
Illuminates when the FPGA is successfully configured.
LED7
Status
Illuminates Bard status
D3
5V
Illuminates when Input power is active. Not Installed.
D4
Power Good
Illuminates when board power system is OK.
2
2.
.2
2
C
Cl
lo
oc
ck
k
C
Ci
ir
rc
cu
ui
it
tr
ry
y
Figure 2-13 shows the default frequency of all external clocks to the MAX 10 FPGA. A clock
generator is used to distribute clock signals with low jitter. The two 50MHz clock signals connected
to the FPGA are used as clock sources for user logic. One 24MHz clock signal is connected to the
clock inputs of USB microcontroller of USB Blaster. One 10MHz clock signal is connected to the
PLL1 and PLL3 of FPGA, the outputs of these two PLLs can drive ADC clock. The associated pin
assignment for clock inputs to FPGA I/O pins is listed in Table 2-3.
Warning!!
Do not modify the clock generator settings.
Incorrect setting will cause the system to not work.
Figure 2-13 Clock circuit of the FPGA Board
Table 2-3 Pin Assignment of Clock Inputs
Signal Name
FPGA Pin No.
Description
I/O Standard
ADC_CLK_10
PIN_N5
10 MHz clock input for ADC (Bank 3B)
3.3-V LVTTL
MAX10_CLK1_50
PIN_P11
50 MHz clock input(Bank 3B)
3.3-V LVTTL
MAX10_CLK2_50
PIN_N14
50 MHz clock input(Bank 3B)
3.3-V LVTTL
T-Core
User Manual
16
www.terasic.com
September 24, 2020
2
2.
.3
3
U
Us
si
in
ng
g
t
th
he
e
P
Pu
us
sh
h-
-b
bu
ut
tt
to
on
ns
s,
,
S
Sw
wi
it
tc
ch
he
es
s
a
an
nd
d
L
LE
ED
Ds
s
User-Defined Push-buttons
The board includes two user defined push-buttons that allow users to interact with the MAX 10
FPGA device. Each of these switches is debounced using a Schmitt Trigger circuit as indicated in
Figure 2-14. A Schmitt trigger feature introduces hysteresis to the input signal for improved noise
immunity, especially for signal with slow edge rate and act as switch debounce in Figure 2-15 for
the push-buttons connected. Table 2-4 list the pin assignment of user push-buttons.
Figure 2-14 Connections between the push-button and MAX 10 FPGA
Figure 2-15 Switch debouncing
Table 2-4 Pin Assignment of Push-buttons
Signal Name
FPGA Pin No.
Description
I/O Standard
KEY[0]
PIN_AB9
Push-button[0]
3.3 V SCHMITT TRIGGER"
KEY[1]
PIN_AA9
Push-button[1]
3.3 V SCHMITT TRIGGER"
User-Defined Dip Switch
There are 4 position dip switches connected to FPGA on the board (See Figure 2-16). These
switches are used as level-sensitive data inputs to a circuit. Every one of the switches is connected
directly and individually to a pin on the MAX 10 FPGA. When the switch is in the ON position
Pushbutton releasedPushbutton depressed
Before
Debouncing
Schmitt Trigger
Debounced
T-Core
User Manual
17
www.terasic.com
September 24, 2020
(closest to the edge of the board), it provides a low logic level to the FPGA, and when the switch is
in another position, it provides a high logic level. Table 2-5 list the pin assignments of the user
switches.
Figure 2-16 Connections between the slide switches and MAX 10 FPGA
Table 2-5 Pin Assignment of Slide Switches
Signal Name
FPGA Pin No.
Description
I/O Standard
SW[0]
PIN_AB16
Dip Switch[0]
3.3-V LVTTL
SW[1]
PIN_Y16
Dip Switch[1]
3.3-V LVTTL
SW[2]
PIN_V16
Dip Switch[2]
3.3-V LVTTL
SW[3]
PIN_AB17
Dip Switch[3]
3.3-V LVTTL
User-Defined LEDs
There are also four user-controllable LEDs connected to FPGA on the board. Each LED is driven
directly and individually by a pin on the MAX 10 FPGA; driving its associated pin to a high logic
level turns the LED on, and driving the pin low turns it off. Figure 2-17 is the connections between
LEDs and MAX 10 FPGA. Table 2-6 list the pin assignment of user LEDs.
T-Core
User Manual
18
www.terasic.com
September 24, 2020
Figure 2-17 Connections between the LEDs and MAX 10 FPGA
Table 2-6 Pin Assignment of LEDs
Signal Name
FPGA Pin No.
Description
I/O Standard
LED[0]
PIN_AA16
LED [0]
3.3-V LVTTL
LED[1]
PIN_AB15
LED [1]
3.3-V LVTTL
LED[2]
PIN_AA15
LED [2]
3.3-V LVTTL
LED[3]
PIN_AA14
LED [3]
3.3-V LVTTL
2
2.
.4
4
U
Us
si
in
ng
g
W
WS
S2
28
81
12
2B
B
R
RG
GB
B
L
LE
ED
D
The board has Built-in the four Color LED (WS2812B) with intelligent controller (See Figure 2-18)
and the four LED are connected in series controlled by one GPIO line. The WS2812B is an
intelligent control LED light source that the control circuit and RGB chip are integrated in a
package of 5050 components. It internal includes intelligent digital port data latch and signal
reshaping amplification drive circuit. Also includes a precision internal oscillator and a 12V voltage
programmable constant current control part, effectively ensuring the pixel point light color height
consistent.
Figure 2-18 Level Shift between the REG LEDs and MAX 10 FPGA
T-Core
User Manual
19
www.terasic.com
September 24, 2020
Control Method
For the WS281B RGB LED, each R/G/B color can be independently controlled, and each color can
be adjusted from level 0 to 255. Therefore, each color needs to use 8bit control, and each LED
needs 24bit control. The 24 bits corresponds to the Figure 2-19.
Figure 2-19 Composition of 24bit data
The logic 1 or 0 of each bit is determined as shown in Figure 2-20. It is determined by the length of
the voltage level in a period. Detailed specifications can refer to Table 2-7.
Figure 2-20 Sequence Chart
Table 2-7 Code Timing
Code Status
Description
Timing
T0H
0 code, high voltage time
220ns~380ns
T1H
1 code, high voltage time
580ns~1µs
T0L
0 code, low voltage time
580ns~1µs
T1L
1 code, low voltage time
220ns~420ns
RES
Frame unit, low voltage time
>280µs
The data transfer protocol of the WS281 use single NRZ communication mode. As shown in Figure
2-21, after the pixel power-on reset, the DI port receive data from controller, the first pixel collect
initial 24bit data then sent to the internal data latch, the other data which reshaping by the internal
signal reshaping amplification circuit sent to the next cascade pixel through the DO port. After
transmission for each pixel, the signal to reduce 24bit. Pixel adopt auto reshaping transmit
technology, making the pixel cascade number is not limited the signal transmission, only depends
on the speed of signal transmission.
  • Page 1 1
  • Page 2 2
  • Page 3 3
  • Page 4 4
  • Page 5 5
  • Page 6 6
  • Page 7 7
  • Page 8 8
  • Page 9 9
  • Page 10 10
  • Page 11 11
  • Page 12 12
  • Page 13 13
  • Page 14 14
  • Page 15 15
  • Page 16 16
  • Page 17 17
  • Page 18 18
  • Page 19 19
  • Page 20 20
  • Page 21 21
  • Page 22 22
  • Page 23 23
  • Page 24 24
  • Page 25 25
  • Page 26 26
  • Page 27 27
  • Page 28 28
  • Page 29 29
  • Page 30 30
  • Page 31 31
  • Page 32 32
  • Page 33 33
  • Page 34 34
  • Page 35 35
  • Page 36 36
  • Page 37 37
  • Page 38 38
  • Page 39 39
  • Page 40 40
  • Page 41 41
  • Page 42 42
  • Page 43 43
  • Page 44 44
  • Page 45 45
  • Page 46 46
  • Page 47 47
  • Page 48 48
  • Page 49 49
  • Page 50 50
  • Page 51 51
  • Page 52 52
  • Page 53 53
  • Page 54 54
  • Page 55 55
  • Page 56 56
  • Page 57 57
  • Page 58 58
  • Page 59 59
  • Page 60 60
  • Page 61 61
  • Page 62 62
  • Page 63 63
  • Page 64 64
  • Page 65 65

Terasic t-core User manual

Type
User manual

Ask a question and I''ll find the answer in the document

Finding information in a document is now easier with AI