Eclipse에서 WIZwiki-W7500 library 포팅하기 Tutorial

목차:

1.     프로젝트 생성

2.     WIZwiki-W7500 library 포팅 방법

3.     F/W 다운로드 방법

 

1. 프로젝트 생성

-. WIZwiki-W7500 보드 사진

 

-. 개발환경 셋팅은 하기 사이트를 참조합니다.

English : http://opensrclab.tistory.com/33

국문 : http://opensrclab.tistory.com/1

-. Eclipse를 실행합니다.

-. 메뉴에서 File->New-> C Project를 선택합니다.

 -. Project name 필드에 사용하고자 하는 프로젝트명을 입력하고 Project type으로 Hello World ARM Cortex-M C/C++ Project를 선택 후 Next를 클릭합니다.

 -. Processor core필드의 Cortex-M0를 확인하고 Trace output으로 Semihosting STDOUT stream을 선택 후 Next를 클릭합니다.

 

 

 -. Toolchain path에 설치한 GNU ToolchainC:\Program Files (x86)\GNU Tools ARM Embedded\4.8 2014q1\bin path를 입력 후 Finish를 클릭합니다.

 -. 생성된 프로젝트를 확인합니다.

2. WIZwiki-W7500 library 포팅 방법

-. 하기 사이트를 참조하여 W7500 library 파일을 다운로드 합니다.

http://wizwiki.net/wiki/doku.php?id=products:w7500:library

-. W7500-1.0.2\W7500x_Library_Examples\Libraries\W7500x_stdPeriph_Driver\inc W7500-1.0.2\W7500x_Library_Examples\Libraries\W7500x_stdPeriph_Driver\src 디렉토리의 파일들을 각각 WIZwiki-W7500_blinky\system\include\W7500x WIZwiki-W7500_blinky\system\src\W7500x 디렉토리에 복사한 후 Eclipse에서 F5를 눌러서 Refresh 시킵니다.

 -. W7500-1.0.2\W7500x_Library_Examples\Libraries\CMSIS\Device\WIZnet\W7500\Include 디렉토리의 system_W7500x.h, W7500x.h 파일들을 WIZwiki-W7500_blinky\system\include\cmsis 디렉토리에 복사 후 Eclipse에서 F5를 눌러서 Refresh 시킵니다.

 -. W7500-1.0.2\W7500x_Library_Examples\Libraries\CMSIS\Device\WIZnet\W7500\Source\system_W7500x.c 파일을 WIZwiki-W7500_blinky\system\src\cmsis 디렉토리에 복사 후 Eclipse에서 F5를 눌러서 Refresh 시킵니다.

 -. vectors_W7500x.c를 첨부된 파일로 교체 후 Eclipse에서 F5를 눌러서 Refresh 시킵니다.

 vectors_W7500x.c

 -. W7500-1.0.2\W7500x_Library_Examples\Projects\Peripheral_Examples\GPIO\Blink_LED 디렉토리의 main.c, W7500x_conf.h, W7500x_it.c, W7500x_it.h 파일들을 WIZwiki-W7500_blinky\src 디렉토리에 복사 후 Eclipse에서 F5를 눌러서 Refresh 시킵니다.

 -. mem.ld 파일의 FLASH start address0x00000000으로 변경 후 저장합니다.

 -. 프로젝트의 Properties를 선택합니다.

 -. C/C++ General->Paths and Symbols->Symbols->GNU C에서 add를 선택 후 USE_STDPERIPH_DRIVER 를 추가합니다.

 -. C/C++ General->Paths and Symbols->Source Location->/WIZwiki-W7500_blinky/system->Edit Filter->Add Multiple을 선택 후 src/diag/trace_impl.c W7500x_gpio.c를 이외의 파일들을 추가하고 Refresh(F5) 시킵니다.

 -. C/C++ General->Paths and Symbols->Includes->GNU C에서 Add 선택 후 src 디렉토리를 추가합니다.

 -. C/C++ Build->Settings->Tool Settings->Target Processor에서 ARM family 셋팅을 cortex-m0로 설정합니다.

 -. C/C++ Build->Settings->Tool Settings->Cross ARM GNU Create Flash Image->General에서 Output file formatraw binary로 설정합니다.

 -. 사용하지 않는 Timer.c, Timer.h 파일을 삭제 후 Eclipse에서 Refresh(F5) 시킵니다.

 -. Build Project를 이용해서 컴파일을 진행합니다.

 3. F/W 다운로드 방법

-. WIZwiki-W7500 보드의 OpenSDA USB 포트를 PC와 연결합니다.

 -. WorkspaceWIZwiki-W7500_blinky\Debug 디렉토리에 생성된 바이너리 파일을 MBED 드라이브로 복사합니다.

참조 https://developer.mbed.org/handbook/Windows-serial-configuration

WIZwiki-W7500_blinky.bin

 -. F/W update reset 시킵니다.

 


+ Recent posts