embeded/FPGA - ALTERA2018. 1. 3. 23:49

문서를 보다 보니 Active Serial / Passive Serial 이라는 단어가 나와서 검색해보니..

일단 Active/Passive는 FPGA의 기준으로 보면 될 것 같다.

Active Serial은 FPGA가 활성화 되서 master 로서 EPCS나 EPCQ를 쓰는 것이고

Passive Serial은 FPGA가 플래시에 관여하지 않고 별도의 micom이나 다른 장치를 통해 플래시를 굽는 것이다.



[링크 : https://www.altera.com/support/support-resources/support-centers/devices/cfg-index/cfg-compare.html]


The Active Serial (AS) configuration scheme is supported in the 1 bit data width (AS x1) or the 4 bit data width (AS x4). The AS x4 scheme is supported only in Stratix® V devices. AS configuration can be performed using an Altera® serial configuration (EPCS) device or quad-serial configuration (EPCQ) device. During AS configuration, the Altera FPGA acts as the configuration master and the EPCS or EPCQ device acts as the configuration slave. The FPGA outputs the clock on the DCLK pin and receives the configuration data from the EPCS or EPCQ device on the data pin(s).

[링크 : https://www.altera.com/support/support-resources/support-centers/devices/cfg-index/cfg-as.html]


Passive serial (PS) configuration can be performed using an Altera® download cable, an Altera configuration device, or an intelligent host such as a microprocessor. During PS configuration, data is transferred from a configuration device, flash memory, or other storage device to the Altera device on the DATA0 pin. This configuration data is latched into the FPGA on the rising edge of DCLK. Configuration data is transferred at a rate of one bit per clock cycle.

[링크 : https://www.altera.com/support/support-resources/support-centers/devices/cfg-index/cfg-ps.html]


[링크 : https://www.altera.com/content/dam/altera-www/global/en_US/pdfs/literature/ug/ug_usb_blstr.pdf]


To program a device in JTAG or Passive Serial mode:

  1. On the File menu, click Open and select the Chain Description File that contains the JTAG or Passive Serial chain you wish set up.

  2. Plug the download cable into the system that contains the devices or device to program.

  3. If necessary, select the appropriate hardware setup for the chain.

  4. If necessary, in the Mode list, select JTAG or Passive Serial.

  5. If you are using JTAG mode, and you want to automatically add devices in a device chain to the programming list, click Auto Detect.

  6. Make sure the device name(s) displayed in the Device list matches the device(s) installed in the system.

  7. If you want, turn on one or more programming options in the programming list.

  8. To start programming or other optional action, click Start.

[링크 : http://quartushelp.altera.com/15.0/mergedProjects/program/pgm/pgm_pro_prog_single_as_device.htm]

Posted by 구차니

intel ME에 이어서 새로운(?) 하드웨어 버그

커널 스페이스 메모리가 유저 스페이스로 유출될 수 있는 결함

그럼.. intel ME 외에도 다른 (ring level 관련 하드웨어 버그니까..) MMU 쪽 버그인가?

[링크 : https://en.wikipedia.org/wiki/Memory_management_unit]


[링크 : https://tgd.kr/2251697]

[링크 : http://www.hwbattle.com/bbs/board.php?bo_table=cpumbram&wr_id=96704]

    [링크 : https://www.phoronix.com/scan.php?page=article&item=linux-415-x86pti&num=1]

    [링크 : https://www.theregister.co.uk/2018/01/02/intel_cpu_design_flaw/] << 요게 가장 원본인듯?

[링크 : http://www.ddanzi.com/...document_srl=500251668]

[링크 : http://www.fmkorea.com/889083531]



+

예전에 cpu 버그로 성능하락 건이 있었던게 기억나서 찾아 보는데..

intel이 아니라 AMD였네(페넘 TLB 버그)

[링크 : http://www.bodnara.co.kr/bbs/article.html?num=64466]


+

PCID - Process Context IDentifiers

머하는 녀석인지 모르겠네.. TLB 나오는거 봐서는 페이징 관련인가?

[링크 : http://www.felixcloutier.com/x86/INVPCID.html]


+

KASLR - Kernel address space layout randomization

[링크 : https://lwn.net/Articles/569635/]

[링크 : https://en.wikipedia.org/wiki/Address_space_layout_randomization]


위의 링크 중에서 잘은 모르겠지만.. 웹 브라우저에 javascript로 뚫는 예제를 보이는데

이번 문제는 AMD cpu에서는 발생하지 않았다고 하지만.. 이거랑 연관이 있는진 모르겠...네?

[링크 : https://www.vusec.net/projects/anc/]


+

2018.01.04

어디서 본 문서인데 링크 손실.. -_ㅠ

파이프라인 길이 증대로 인해서 branch prediction을 통해 미리 연산을 하는데

분기예측시에는 권한을 고려하지 않고 연산함으로서

현재 권한에 따라 미리 계산해두기 때문에 사용자 권한임에도 불구하고

분기예측으로 인해 커널 메모리를 접근가능한 문제가 발생하고

이 헛점을 노리면 적절한 타이밍과 분기문을 이용해서 현재의 문제가 발생했다 라는 글도 있었는데

잘은 모르겠네.. MMU에 분기예측에 그럼.. 현존 x86 아키텍쳐 전체에 대한 문제로 확대되는거 아닌가?

아니.. 반대로 폰 노이만 구조의 MMU를 장착하고 파이프라인으로 처리 성능을 늘린 모든

CPU에 대해서 해당 문제가 발생할 우려가 있을 것으로 보이는데?


[링크 : http://www.coolenjoy.net/bbs/27/1852001?sfl=wr_subject%7C%7Cwr_content&stx=branch&sop=and]

Posted by 구차니
embeded/Cortex-M4 Ti2018. 1. 3. 09:18

'embeded > Cortex-M4 Ti' 카테고리의 다른 글

c99 inline과 extern  (0) 2018.04.20
tm4c1231 부트로더 + RS485  (0) 2018.01.04
keil linker 옵션 entry  (0) 2017.12.28
tivaware bootloader + qs-rgb 테스트  (0) 2017.12.28
tm4c tivaware bootloader 빌드..  (2) 2017.12.26
Posted by 구차니
embeded/FPGA - ALTERA2018. 1. 3. 09:10

대부분이 LVTTL(3.3V로 작동해서 가능 한 듯?)


마우스 꽂아서 핑퐁 게임 ㄷㄷ

[링크 : http://www.fpga4fun.com/PongGame.html]


NTSC 콤포짓 영상 만들기

[링크 : http://excamera.com/sphinx/fpga-ntsc.html]


VGA test 패턴

[링크 : http://maximator-fpga.org/examples/]


ADV7123 비디오 DAC 이용한 예제

[링크 : https://eewiki.net/pages/viewpage.action?pageId=15925278]

1600x1200@100Hz 가능한 녀석인 듯

[링크 : https://people.ece.cornell.edu/land/courses/ece5760/DE1_SOC/ADV7123.pdf]

Posted by 구차니
embeded/FPGA - ALTERA2018. 1. 2. 23:10

왜 빠른가 했더니 FLASH에 한번도 안쓰고

전부 SRAM에 바로 적용해서 빨랐던 거였군.. -_-


quartus 에서 File - Convert Programming Files


Programming file type을 pof나 jic로 설정해주고

아래의 input files to convert 에서 

JIC는 Flash loader에서 Add Device, SOF Data에서 Add File을 해주고


pof는 SOF Data에서 Add File을 해주면 된다.


프로그래머에서는 구울수 있는 곳이 있는데

기본 프로젝트에서는 죄다 EP4CE22 로만 굽도록 되어 있어 구워도 전부 SRAM으로만 들어가

전원을 끊었다 연결하면 이전 작동으로 돌아가도록 되어있다.


아무튼 Auto Detect 눌러서 비슷한게 나오면 Change Device로 제대로 잡아주고


Device에서 우클릭 해서 Attach Flash Deivce로

EPCS64를 추가해준다.


그러면 신기하게도 Factory default enhanced SFL image라는게 생겨나는데

굽고 나서 add file 누르면 저 이미지가 사라지고, 그러면 jtag으로 구울수가 없다..

도대체 쟤는 어떻게 선택하지?

Posted by 구차니
embeded/FPGA - ALTERA2018. 1. 2. 22:05

데이터 시트랑 자료들 보다 보니.. IV 에는 고속 시리얼 버스 없고 PCIe도 없고

다만 LVDS는 있다고 하길래 HDMI 정도는 별도의 트랜시버 칩 없이 가능하지 않으려나?

생각했는데 역시나.. 누군가 해놓은게 있네.. ㄷㄷ


[링크 : http://sa89a.net/mp.cgi/ele/fpga_hdmi.htm]

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

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


+

카페자료

[링크 : http://cafe.naver.com/xinadist/21]

[링크 : http://cafe.naver.com/xinadist/22]

Posted by 구차니
embeded/FPGA - ALTERA2018. 1. 2. 20:33

sof - sram object file

rbf - raw binary file

pof - program object file

[링크 : https://www.altera.com/content/dam/altera-www/global/en_US/pdfs/literature/hb/cyclone-iv/cyiv-51008.pdf]


jic - JTAG Indirect Configuation file

[링크 : http://quartushelp.altera.com/14.1/mergedProjects/reference/glossary/def_jic.htm]


A SOF file programs the FPGA fabric directly (The FPGA's SRAM cells). 

The POF file is used to program an external configuration (A FLASH/EEPROM device - not the actual FPGA). 

[링크 : http://www.alteraforum.com/forum/showthread.php?t=53811]


progammer에서는 jic로 플래시에 굽네.. pof는 어디서 쓸려나?

Posted by 구차니
embeded/FPGA - ALTERA2018. 1. 2. 19:34

DE0-nano의 Altera Cyclone IV에 달린

EPCS64 는 8MB 인데.. 실제로 sof 파일들 보면 688KB로 나온다.

아무튼 NIOS2 예제들을 보면 용량이 조금 더 크게 나온다.

아무튼.. SOF 파일 자체에 FPGA 설정 부분과 NIOS 2 용량으로 구성이 되는것 같고

NIOS 2에서 EPCS Controller를 통해서 MICOM 내부 flash 쓰듯 쓸수 있다는 것을 봐서는

EPCS Controller 에서는 물리 주소와 논리주소로 구분하여 

NIOS 2에서 접근하도록 해주는 역활을 하는 것으로 추측된다.




0xE400이면 58368 인데.. 단위가 머냐...


[링크 : https://www.altera.com/content/dam/altera-www/global/en_US/pdfs/literature/ug/ug_embedded_ip.pdf]


SOPC Builder includes the EPCS device controller core, which is an interface core designed specifically to work with the EPCS device. 

[링크 :https://www.altera.com/content/dam/altera-www/global/en_US/pdfs/literature/hb/cfg/cyc_c51014.pdf]

[링크 : http://www.alterawiki.com/wiki/EPCS_Guide]

Posted by 구차니

'프로그램 사용 > notepad++' 카테고리의 다른 글

notepad++ for ubuntu?  (0) 2019.12.21
notepad++ 주석 삭제하기  (4) 2018.05.09
notepad++ 따옴표 자동완성 끄기  (0) 2017.12.10
notepad++ 줄순서 뒤바꾸기  (2) 2017.11.22
notepad++ XML 인덴트 적용하기  (0) 2017.07.26
Posted by 구차니

이것저것 테스트 중..

일단 eclipse에서 통합하는 것 보다는

eclipse 에서는 편집하고

cppcheck 독립 GUI 프로그램과

doxygen 독립 GUI 프로그램을 이용하는게 더 간편해 보인다.


eclipse + doxygen 설명 끝판왕 ㄷㄷ

[링크 : https://mcuoneclipse.com/2012/06/25/5-best-eclipse-plugins-1-eclox-with-doxygen-graphviz-and-mscgen/]

[링크 : http://5on7.blogspot.com/2016/01/08-01.html]

[링크 : https://codeyarns.com/2015/06/11/how-to-use-cppcheck-with-eclipse-cdt/]



com(alt+enter) 자동완성으로 comment

/* 엔터 (주석 자동완성)

/// 엔터

[링크 : https://questionfocus.com/change-doxygen-comment-style-in-eclipse.html]


java doxygen Alt-Shift-J

이건.. 다른 단축키와의 충돌로 사라진거 같기도 하고?

[링크 : http://zzznara2.tistory.com/75]


doxygen 문법 - 함수는 이 정도면 되려나?

/*

 * @brief 간략한 설명

@details 상세 설명

@param int a 변수 int a에 대한 설명

@return 반환갑 설명

 */ 

[링크 : http://onecellboy.tistory.com/342]


cppcheck에서 clang을 쓰려면 프로젝트 에서 경고 띄우도록 설정해야 하는 듯?

[링크 : https://sourceforge.net/p/cppcheck/wiki/Home/]


다운로드 링크

[링크 : https://www.eclipse.org/downloads]

[링크 : http://www.stack.nl/~dimitri/doxygen/download.html]

[링크 : https://sourceforge.net/projects/cppcheck/]

[링크 : http://releases.llvm.org/download.html]


2012/02/07 - [프로그램 사용/eclipse CDT & minGW] - eclipse cdt + eclox + doxygen

2015/09/30 - [Programming/C / Win32 / MFC] - Cppcheck

Posted by 구차니