embeded/FPGA - ALTERA2018. 6. 20. 11:23

흐음. 이거 설정 안해서 EPCS 부팅이 안되던 건가..

그냥 flash programmer를 통해서 해본적이 없어서 모르겠네..


아무튼 기본적 de0-nano 프로젝트 에서 dual-purpose pins에 할당된 내용이다.


사용가능한 옵션으로는 여러가지가 있지만 대개 "Use as regular I/O"로 설정하는 듯 하다.

[링크 : http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.dui0430a/BABIAIHE.html]


On the Dual-purpose pins page (Assignments > Devices > Device and Pin Options), ensure that the following pins are assigned to the respective values:

— Data[0] = Use as regular I/O

— Data[1] = Use as regular I/O

— DCLK = Use as regular I/O

— FLASH_nCE/nCS0 = Use as regular I/O

[링크 : https://www.altera.com/en_US/pdfs/literature/ug/ug_embedded_ip.pdf] 167page

'embeded > FPGA - ALTERA' 카테고리의 다른 글

modelsim 길이 측정하기  (0) 2018.06.27
de0-nano LVDS  (0) 2018.06.26
modelsim define clock  (0) 2018.06.19
modelsim과 timescale 그리고 50Mhz  (0) 2018.06.18
modelsim nativelink  (0) 2018.06.18
Posted by 구차니
embeded/FPGA - ALTERA2018. 6. 19. 15:55

조금 만져본바로는

define clock이

apply wave를 통해 생성하는 것 보다 가벼운 느낌이다.


얘도 timescale에 따라가지는지는 확인해봐야 겠지만

`timescale 1ns/1ns 

설정하고 Period를 20으로 잡아주니 50MHz의 클럭이 생성된다(클럭 주기 20ns)

[링크 : http://www.pldworld.com/_hdl/2/_ref/se_html/manual_html/c_gui82.html]

'embeded > FPGA - ALTERA' 카테고리의 다른 글

de0-nano LVDS  (0) 2018.06.26
dual purpose pins  (0) 2018.06.20
modelsim과 timescale 그리고 50Mhz  (0) 2018.06.18
modelsim nativelink  (0) 2018.06.18
modelsim 클럭연결하기  (0) 2018.06.15
Posted by 구차니
embeded/FPGA - ALTERA2018. 6. 18. 15:06

modelsim에서 시뮬레이션 할 때

timescale의 값에 설정된 단위대로 돌게 되는데 일반적으로 1ns/10ps를 자주 쓴다.

앞에는 # 뒤에 오는 숫자의 단위 시간이고 

만약 timescale 10ns로 한다면 #1은 1ns대신 10ns로 설정되게 된다.


`timescale 1ns/100ps


module Counter_tb;


reg        clk;

reg        rst_n;

wire [7:0] cnt;

// 20 ns 이다..

parameter PERIOD = 20; 


Counter counter (

  .CLK(clk),

  .RST_N(rst_n),

  .CNT(cnt)

);


initial begin

  #0  clk   = 1'b0;

      rst_n = 1'b0;

  #10 rst_n = 1'b1;

end


// 50MHz 코멘트를 잘달자

always #(PERIOD/2) clk = ~clk;


endmodule 

[링크 : https://blog.naver.com/bohkyou/100093456018]


50MHz는 20ns 주기이고 high / low duty를 고려하면 50% 일 경우

10ns 의 high, 10ns의 low를 유지하면 된다.

그렇기에 timescale 1ns/10ps의 경우

#10 clk = 1;

#10 clk = 0;

으로 반복해서 수행하면 충분해야 할텐데..

의미로 간격 바꾸고 modelsim에서 돌리면 내가 의도한 것과 다르게 나오는 느낌..


조금더 공부를 해봐야 알 듯 하다 ㅠㅠ

'embeded > FPGA - ALTERA' 카테고리의 다른 글

dual purpose pins  (0) 2018.06.20
modelsim define clock  (0) 2018.06.19
modelsim nativelink  (0) 2018.06.18
modelsim 클럭연결하기  (0) 2018.06.15
intel FPGA를 이용한 Processor Logic 설계입문 관련 링크  (0) 2018.06.15
Posted by 구차니
embeded/FPGA - ALTERA2018. 6. 18. 10:30

카페 보다 보니 저걸 설정해서 하면 quartus 내에서 더 편하게 한다는데

기본 설정은 none으로 되어있다고 설정을 해야 한다고 한다.

[링크 : https://www.altera.com/.../modelsim/exm-ncsim-native-link.html]

[링크 : https://www.youtube.com/watch?v=PmVVXQchv2c]



'embeded > FPGA - ALTERA' 카테고리의 다른 글

modelsim define clock  (0) 2018.06.19
modelsim과 timescale 그리고 50Mhz  (0) 2018.06.18
modelsim 클럭연결하기  (0) 2018.06.15
intel FPGA를 이용한 Processor Logic 설계입문 관련 링크  (0) 2018.06.15
quartus 2 qar file  (0) 2018.06.11
Posted by 구차니
embeded/FPGA - ALTERA2018. 6. 15. 16:53

이런 저런 방법이 있는데 어떻게 쓰는건지 감이 1도 안오네..

[링크 : http://www.newtc.co.kr/download/FB-CY6/NTC_FPGA_강좌_02_로직_시뮬레이터_사용법.pdf]


waveform 어쩌구 통해서 시뮬레이션에 쓸 문장을 생성하는 듯?

[링크 : https://youtu.be/uSGsQjXWnXk?t=420]


waveform editor

[링크 : https://www.altera.co.jp/ja_JP/pdfs/literature/hb/qts/qts_qii53017.pdf]

어쩌다 먼가 된거 같긴한데 안된건가? ㅠㅠ


[링크 : http://www.ednc.com/wp/wp-content/uploads/2015/06/modelsim_questa_10.4_tutorial.pdf]


How do I generate clock in Verilog ?

There are many ways to generate clock in Verilog; you could use one of the following methods:


Method #1

 1 initial begin

 2  clk = 0;

 3 end

 4    

 5 always begin

 6    #5  clk = ~clk;

 7 

 8 end

You could download file clock_always.v here

 

Method #2

 1 initial begin

 2   clk = 0;

 3   forever begin

 4      #5  clk = ~clk;

 5   end

 6 end

You could download file clock_forever.v here


Method #3

 1 initial begin

 2   clk = 0;

 3 end

 4 

 5 always begin

 6    #5  clk = 0;

 7    #5  clk = 1;

 8 end 

[링크 : http://www.asic-world.com/verilog/verifaq2.html]


+

2018.06.18

하다 보니.. 클럭 연결을 할게 아니라

# 명령중 반복을 통해서 특정 시간대에 클럭처럼 신호를 발생시키도록 해야

시뮬레이션에서 정상적으로 계산이 가능 한 듯?


음.. #5 하면.. 100Mhz로 작동하는건가?



'embeded > FPGA - ALTERA' 카테고리의 다른 글

modelsim과 timescale 그리고 50Mhz  (0) 2018.06.18
modelsim nativelink  (0) 2018.06.18
intel FPGA를 이용한 Processor Logic 설계입문 관련 링크  (0) 2018.06.15
quartus 2 qar file  (0) 2018.06.11
HDMI de0-nano  (0) 2018.06.05
Posted by 구차니
embeded/FPGA - ALTERA2018. 6. 15. 10:15

책에 사용한 소스 받는 곳 찾는 중


[링크 : http://digitalfilter.com]


Shift-JIS라 한글 윈도우에서 wordpad나 notepad로 열면 깨져서 안나온다 -_ㅜ

아무튼 저자가 암호 공개를 책 산 사람에게만 공개하고 있으니 저자의 뜻을 따르겠지만..

압축 - 압축 - 자동압축 파일 이런식으로 꽁꽁 싸매놓는건 무지 귀찮네...

FpgaOriginal.zipを展開するには,パスワードが必要です.


パスワードは,


 第1部 1日目 図1-23のタイトルにある8ケタの数字

 第2部 15日目 図15-15のタイトルにある5文字のアルファベット

 Appendix A 図A-4のタイトルにある7文字のアルファベット


以上をハイフンでつないだ文字列です.


例:12345678-YYYYY-ZZZZZZZ


すべて半角文字,アルファベットは大文字小文字に注意してください. 

[링크 : http://www.cqpub.co.jp/toragi/nios2/index.htm] << 100메가

[링크 : http://www.cqpub.co.jp/hanbai/books/48/48191.htm]

[링크 : http://www.cqpub.co.jp/toragi/nios2/movies/movie.htm]

'embeded > FPGA - ALTERA' 카테고리의 다른 글

modelsim nativelink  (0) 2018.06.18
modelsim 클럭연결하기  (0) 2018.06.15
quartus 2 qar file  (0) 2018.06.11
HDMI de0-nano  (0) 2018.06.05
de0-nano 그리고 modelsim 사용법  (0) 2018.06.04
Posted by 구차니
embeded/FPGA - ALTERA2018. 6. 11. 10:10

zip이나 tar는 아닌 독자 규격이거나 헤더를 변형한 녀석인 듯?

아무튼 프로젝트 열듯 더블 클릭해서 열면 해당 파일이 있던 곳에 압축이 풀리고

프로젝트 파일과 폴더가 풀려서 나온다.


Archiving Projects

You can save the elements of a project in a single, compressed Quartus II Archive File (. qar) by clicking

Project > Archive Project.

The .qar captures logic design, project, and settings files required to restore the project.

Use this technique to share projects between designers, or to transfer your project to a new version of the

Quartus II software, or to Altera support. You can optionally add compilation results, Qsys system files, and

third-party EDA tool files to the archive. If you restore the archive in a different version of the Quartus II

software, you must include the original .qdf in the archive to preserve original compilation results.

[링크 : https://www.altera.com.cn/zh_CN/pdfs/literature/hb/qts/qts_qii52012.pdf]

Posted by 구차니
embeded/FPGA - ALTERA2018. 6. 5. 10:55
Posted by 구차니
embeded/FPGA - ALTERA2018. 6. 4. 16:32

일단 하나 검색했으니 집에가서 따라해봐야지


RTL Level Simulation with ModelSim

- Synthesis 이후에 시뮬레이션 가능

Gate Level Simulation

- 전체 컴파일 이후에 시뮬레이션 가능

[링크 : http://idlelogiclabs.com/2011/12/04/using-modelsim-with-quartus-ii-and-the-de0-nano/]


게이트-레벨시뮬레이션은타이밍시뮬레이션에서 기능적결과의차이만을확인한다. 만약게이트-레벨시뮬레 이션은문제없고타이밍시뮬레이션이실패했다면, 넷리스트 가아닌타이밍으로발생된부분임을나타낸다. 백-어노테이트 타이밍 시뮬레이션은 타이밍 정보가 있는 게이트-레벨 시뮬레이션이다. 이를 위해 FPGA 벤더는 VITAL (VHDL Gate Level) 넷리스트 또는 Verilog 넷리스 트를 생성한다 

[링크 : http://www.itfind.or.kr/COMIN/file24639-FPGA%20디버깅%20방법.pdf]

Posted by 구차니
embeded/FPGA - ALTERA2018. 6. 3. 23:07

output 대신에

output reg를 쓰니 해결..

c언어 때 처럼 무슨 문제인지 감이 영안오네...


[링크 : https://electronics.stackexchange.com/...left-hand-side-of-assignment-must-have-a-variable-data-type]

Posted by 구차니