본문 바로가기

Cortex-M/GigaDevice

GD32F130 SSM - 개발환경 설정 (STM32CubeIDE 오류, Arduino 만들기)

 

 

 

기존에 사용했던 GD시리즈는 STM32과 동일한 핀맵이고 개발툴도 STM32CubeIDE를 그대로 사용하여 개발 할 수 있었는데 GD32F130은 동일하게 동작하지 않는다. 아무래도 ST사에서 사용할수 없도록 하지 않았을까...

 

[GD32-48 SSM] GD32F303 개발환경 설정 및 성능 테스트(STM32CubeIDE 이용)

GigaDevice사의 GD32시리즈는 STM32시리즈와 동일 핀맵으로 호환 가능하으로 STM32를 대체해서 사용 할수 있다고 한다. 우선 GD32의 개발환경 설정과 간단한 성능 측정을 해 보자 개발환경은 ST사의 STM32C

nexp.tistory.com

 

 

 

우선 STM32CubeProgramer 에서 디바이스 인식은 되지만 프로그램이 정상적으로 Write되지 않는다.

 

 

디바이스 ID 가 달라서 그런것 같다.

  18:45:06 : Error: Unable to get core ID
  18:45:06 : Error: failed to download Segment[0]
  18:45:06 : Error: failed to download the File
  18:45:06 : RUNNING Program ... 
  18:45:06 :   Address:      : 0x08000000
  18:45:06 : Application is running, Please Hold on...
  18:45:06 : Start operation achieved successfully
  18:45:06 : Error: Unable to get core ID
  18:45:06 : Error: Unable to get core ID
  18:45:06 : Warning: Connection to device 0x410 is lost
  18:45:06 : Disconnected from device.
  18:45:06 : ST-LINK error (DEV_CONNECT_ERR)

GD사에서 제공하는 예제 코드중 가장 쉽게 테스트 해 볼수 있는 것으로  Arduino 가 있다.

GD32F303 Arduino 만들기  참고

 

Arduino IDE의 Board Manager에서 GD32F1x0 Generic series를 선택 하면된다.

 

 

디바이스는 20핀 페키지의 GD32F130F8로 선정한다.

 

 

펌웨어 업로드 방법은 기존과 같이 STLink로 잘 동작한다.

 

 

기본 예제를 구동하면 문제 없이 잘 컴파일 되고 다운로드 되는것을 확인 할 수 있다.

xPack OpenOCD, i386 Open On-Chip Debugger 0.11.0-00155-ge392e485e (2021-03-15-16:48)
Licensed under GNU GPL v2
For bug reports, read
	http://openocd.org/doc/doxygen/bugs.html
hla_swd
0
Info : The selected transport took over low-level target control. The results might differ compared to plain JTAG/SWD
Info : clock speed 1000 kHz
Info : STLINK V2J40M27 (API v2) VID:PID 0483:374B
Info : Target voltage: 3.264950
Info : stm32f1x.cpu: hardware has 6 breakpoints, 4 watchpoints
Info : starting gdb server for stm32f1x.cpu on 3333
Info : Listening on port 3333 for gdb connections
target halted due to debug-request, current mode: Thread 
xPSR: 0x01000000 pc: 0x08000a34 msp: 0x20002000
** Programming Started **
Info : device id = 0x13030410
Info : flash size = 64kbytes
** Programming Finished **
** Verify Started **
** Verified OK **
** Resetting Target **
shutdown command invoked

 

 

GD32의 가장 장점이 ST제품을 코드레벨까지 호환되는 것 이었는데... GD32F130 시리즈는 안되는것 같다. 

 

반응형