ÀÌ ¸Å´º¾óÀº JKÀüÀÚ(JK Electronics) ¿¡ ÀÇÇؼ­ ¼öÁ¤, ÀÛ¼º µÇ¾ú°í ¼ÒÀ¯±Ç ¶ÇÇÑ
JKÀüÀÚ(JK Electronics)
ÀÇ °ÍÀÔ´Ï´Ù. ¼ÒÀ¯±ÇÀÚÀÇ Çã°¡¸¦ ¹ÞÁö ¾Ê°í ¹«´ÜÀ¸·Î ¼öÁ¤, »èÁ¦Çϰųª ¹èÆ÷ ÇÒ ¼ö ¾ø½À´Ï´Ù.

 

 

Cortex-M3 STM32F103 ½Ã¸®Áî ´Ù¿î·Îµå °¡À̵å


 
* Update history

- 2012.3.26 : Ãʱâ Release


 
1. Ÿ°Ùº¸µå¿Í ¿¬°á ¹× USB µå¶óÀ̹ö ¼³Ä¡
2. CPU Detect
3. JCS ½ºÅ©¸³Æ® ÆÄÀÏ ¼öÁ¤
4. JCS ½ºÅ©¸³Æ® ÆÄÀÏ ½ÇÇà


   
 
1. Ÿ°Ùº¸µå¿Í ¿¬°á ¹× USB µå¶óÀ̹ö ¼³Ä¡

ARM JTAG »ç¿ëÀÚ °¡ÀÌµå ¸¦ ÂüÁ¶ÇϽñ⠹ٶø´Ï´Ù.

2. CPU Detect

(1) ARMJTAG Server ¸¦ ½ÇÇà ÇÕ´Ï´Ù.

armjtag

(2) "Tap Configure" ¸¦ ½ÇÇà ÇÕ´Ï´Ù.

armjtag

"DEFAULT" ¸¦ ¼±Åà ÇÕ´Ï´Ù.

armjtag

(3) "Debug Port Configure" ¸¦ ½ÇÇà ÇÕ´Ï´Ù.

armjtag

"JTAG" ¸¦ ¼±ÅÃÇصµ µÇ°í, "SWD" ¸¦ ¼±ÅÃÇصµ µÇÁö¸¸ ¿©±â¼­´Â "SWD" ¸ðµå·Î Çϵµ·Ï ÇÏ°Ú½À´Ï´Ù.

armjtag

(4) "Target Manager " ¸¦ ½ÇÇà ÇÕ´Ï´Ù.

armjtag

"CORTEX-M3" ¸¦ ¼±Åà ÇÕ´Ï´Ù.

armjtag

(5) "JTAG Clock " Àº ¼±Åà ÇÏÁö ¾Ê¾Æµµ µË´Ï´Ù.

(6) "Target Detect" ¸¦ ÇÕ´Ï´Ù.

armjtag

3. JICECommander/Easy FlashLoader¸¦ ÀÌ¿ëÇÑ ¹æ¹ý

JICECommander¸¦ ½ÇÇàÇÕ´Ï´Ù.

arm-jtag

JICECommander¿¡¼­ À§ÀÇ ±×¸²ÀÇ ¾ÆÀÌÄÜÀ» ´­·¯¼­ "Easy FlashLoader" ¸¦ ½ÇÇà ÇÕ´Ï´Ù.

arm-jtag

Cortex-M4ÀÇ °æ¿ì "STM32F4xxG" ¸¦ ¼±ÅÃÇÕ´Ï´Ù. CPU¿¡ µû¶ó¼­ ¾Ë¸ÂÀº Loader¸¦ ¼±Åà ÇÏ½Ã¸é µË´Ï´Ù.
±×¸®°í "Select Downlaod Image" ¸¦ Ŭ¸¯Çؼ­ ´Ù¿î·Îµå ÇÏ·Á´Â bin or hex ÆÄÀÏÀ» ¼±Åà ÇÕ´Ï´Ù.

arm-jtag

"Start Download" ¹öÆ°À» ´­·¯¼­ JICECommander »ó¿¡¼­ ´Ù¿î·Îµå°¡ Á¤»óÀûÀ¸·Î ÀÌ·ç¾î Áö´ÂÁö¸¦ È®ÀÎ ÇÕ´Ï´Ù.

4. JCS ½ºÅ©¸³Æ® ÆÄÀÏÀ» ÀÌ¿ëÇÑ ¹æ¹ý

(1) "jcs ½ºÅ©¸³Æ® ¿¡µðÅÍ" ¸¦ ½ÇÇà ÇÕ´Ï´Ù.

armjtag

(2) "jcs ½ºÅ©¸³Æ®" ÆÄÀÏÀ» ·Îµù ÇÕ´Ï´Ù.

armjtag

STM32F107VCT6 ¿¡ ´ëÇÑ ¿¹Á¦·Î ÁøÇà Çϵµ·Ï ÇÏ°Ú½À´Ï´Ù.

±âº» Á¦°ø ½ºÅ©¸³Æ® ÆÄÀÏÀº "C:\Program Files\JICE\flashloader\st\stm32f10x(high_density)" ¿¡ ÀÖ½À´Ï´Ù.

armjtag

"stm32f10x_program.jcs" ÆÄÀÏÀ» ¼±Åà ÇÕ´Ï´Ù.

armjtag

±âº»Á¦°ø ½ºÅ©¸³Æ®ÀÇ À§Ä¡´Â STM32F10x ÀÇ Flash-density ¿¡ µû¶ó¼­ ´Þ¶ó Áú ¼ö ÀÖ½À´Ï´Ù. ¾Æ·¡ Flash »çÀÌÁ CPU Part ÀÔ´Ï´Ù.
CPU µÚÂÊ ÆÄÆ® ¹øÈ£¿¡ µû¶ó¼­ "C:\Program Files\JICE\flashloader\st" Æú´õ¿¡¼­ ½ºÅ©¸³Æ® ÆÄÀÏÀ» ´Ù¸£°Ô ·Îµù Çؼ­ »ç¿ë ÇØ¾ß ÇÕ´Ï´Ù.

- Low-density : STM32F103x4/6 ½Ã¸®Áî
- Medium-density : STM32F103x8/B
- High-density : STM32F103xC/D/E

- XL-density : STM32F103xF/G

armjtag

Generic Part Number Package FLASH Size (Prog) (kB) Internal RAM Size (kB) Density

STM32F103C4
LQFP 48 7x7x1.4 1 16 6 low-density

STM32F103C6
LQFP 48 7x7x1.4 1 VFQFPN48 32 10 low-density

STM32F103C8
LQFP 48 7x7x1.4 1 64 20 medium-density

STM32F103CB
LQFP 48 7x7x1.4 1 128 20 medium-density

STM32F103R4
LQFP 64 10x10 TFBGA 5x5x1.2 64 F8x8 0.5 16 6 low-density

STM32F103R6
LQFP 64 10x10 TFBGA 5x5x1.2 64 F8x8 0.5 32 10 low-density

STM32F103R8
LQFP 64 10x10 TFBGA 5x5x1.2 64 F8x8 0.5 64 20 medium-density

STM32F103RB
LQFP 64 10x10 TFBGA 5x5x1.2 64 F8x8 0.5 128 20 medium-density

STM32F103RC
LQFP 64 10x10 WLCSP64L 256 48 high-density

STM32F103RD
LQFP 64 10x10 WLCSP64L 384 64 high-density

STM32F103RE
LQFP 64 10x10 WLCSP64L 512 64 high-density

STM32F103RG
LQFP 64 10x10 1024 96 xl-density

STM32F103T4
VFQFPN 36 6x6x1.0 PITCH 0.50 16 6 low-density

STM32F103T6
VFQFPN 36 6x6x1.0 PITCH 0.50 32 10 low-density

STM32F103T8
VFQFPN 36 6x6x1.0 PITCH 0.50 64 20 medium-density

STM32F103TB
VFQFPN 36 6x6x1.0 PITCH 0.50 128 20 medium-density

STM32F103V8
LFBGA 10x10x1.7 100 F10x10 0.8 LQFP 100 14x14 64 20 medium-density

STM32F103VB
LFBGA 10x10x1.7 100 F10x10 0.8 LQFP 100 14x14 128 20 medium-density

STM32F103VC
LFBGA 10x10x1.7 100 F10x10 0.8 LQFP 100 14x14 256 48 high-density

STM32F103VD
LFBGA 10x10x1.7 100 F10x10 0.8 LQFP 100 14x14 384 64 high-density

STM32F103VE
LFBGA 10x10x1.7 100 F10x10 0.8 LQFP 100 14x14 512 64 high-density

STM32F103VG
LQFP 100 14x14 1024 96 xl-density

STM32F103ZC
LFBGA 10x10x1.7 144 F12x12 0.8 LQFP 144 20X20X1.4 2 256 48 high-density

STM32F103ZD
LFBGA 10x10x1.7 144 F12x12 0.8 LQFP 144 20X20X1.4 2 384 64 high-density

STM32F103ZE
LFBGA 10x10x1.7 144 F12x12 0.8 LQFP 144 20X20X1.4 2 512 64 high-density

STM32F103ZF
LQFP 144 20X20X1.4 2 768 96 xl-density

STM32F103ZG
LQFP 144 20X20X1.4 2 1024 96 xl-density

STM32F105R8
LQFP 64 10x10 64 20 medium-density

STM32F105RB
LQFP 64 10x10 128 32 medium-density

STM32F105RC
LQFP 64 10x10 256 64 high-density

STM32F105V8
LQFP 100 14x14 64 20 medium-density

STM32F105VB
LFBGA 10x10x1.7 100 F10x10 0.8 LQFP 100 14x14 128 32 medium-density

STM32F105VC
LQFP 100 14x14 256 64 high-density

STM32F107RB
LQFP 64 10x10 128 48 medium-density

STM32F107RC
LQFP 64 10x10 256 64 high-density

STM32F107VB
LQFP 100 14x14 128 48 medium-density

STM32F107VC
LFBGA 10x10x1.7 100 F10x10 0.8 LQFP 100 14x14 UNSAWN WAFER V.I. 100% 256 64 high-density


(3) ·ÎµùÇÑ "jcs ½ºÅ©¸³Æ®" ÆÄÀÏÀ» ¼öÁ¤ ÇÕ´Ï´Ù.

armjtag

- STM32F107VCT6 ½ÇÁ¦ ½ºÅ©¸³Æ® ÆÄÀÏ ³»¿ë ÀÔ´Ï´Ù.


print "STM32F10x High Density Size Flash Program Script."

;ÀÌ ¸í·ÉÀº JICECommander ¸¦ ½ÇÇàÇÏ´Â ¼ø°£ Target Àº halt µÇ¹Ç·Î ÇÊ¿ä¾øÀ» ¼ö ÀÖ½À´Ï´Ù.
;±×·¯³ª JICECommander ¸¦ ½ÇÇàÇسõÀº »óÅ¿¡¼­ ´Ù½Ã Target À» ÀçºÎÆÃÇϸé
;Target Àº ´Ù½Ã halt µÇ¾î¾ß ÇϹǷΠÀ̶§´Â ÇÊ¿äÇÕ´Ï´Ù.
target.stop

; ´Ù¿î·Îµå¿¡ »ç¿ëÇÒ Flash agent binary ÆÄÀÏÀÇ À§Ä¡¸¦ ÁöÁ¤ ÇÕ´Ï´Ù.
; STM32FÀÇ °æ¿ì Flash density ¿¡ µû¶ó¼­ ´Þ¶ó Áý´Ï´Ù.

; 0x20000000 ´Â STM32F ¿¡¼­ RAMÀÇ ½ÃÀÛ ¹øÁö ÀÔ´Ï´Ù.

mem.load "C:\Program Files\JICE\flashloader\st\stm32f10x(high_density)\stm32f10x_high_density_flash_agent(12.03.06).bin" 0x20000000

; Flash agent Parameter ¼³Á¤ ÀÔ´Ï´Ù.
; 0x20000000 : Flash agentÀÇ ARM start address - ´ëºÎºÐ mem.load ¿¡¼­ »ç¿ëÇß´ø RAM ½ÃÀÛ ÁÖ¼Ò¿Í ÀÏÄ¡
; 0x20002000 : Flash Agent parameter ¿µ¿ªÀÇ ½ÃÀÛ address ÀÔ´Ï´Ù.
; 0x1000 : Flash buffer size ÀÔ´Ï´Ù. º¸ÅëÀº 0x1000 À» »ç¿ëÇÏ¸é µË´Ï´Ù.

flash.agent 0x20000000 0x20002000 0x1000


; cortex-m stack & program counter setting :
; cortex-m3 ÀÇ °æ¿ì ù¹ø° vector°¡ stack pointer ÀÌ°í ±×´ÙÀ½ÀÌ reset vector ÀÌ´Ù.
; Flash agent°¡ RAM»ó¿¡ Á¸ÀçÇϱ⠶§¹®¿¡ stack, pc ¸¦ RAMÀÇ ½ÃÀÛ ÁÖ¼Ò·Î ºÎÅÍ Àо ¼¼Æà ÇÏ°í ÀÖ´Ù.
mem.read 0x20000000 %32
reg.r13.write.before

mem.read 0x20000004 %32
reg.pc.write.before

print "Flash Erase"
flash.erase

;¸í·ÉÀ» »ç¿ëÇÏÁö ¾Ê°í Script ·Î ´ëü ½Ã
;execute "C:\Program Files\JICE\flashloader\st\stm32f10x(high_density)\stm32f10x_flash_mass_erase.jcs"

; °è¼Ó ÁøÇà ÇÒ °ÍÀΰ¡ ÇÏ´Â ¸Þ¼¼Áö âÀ» º¸¿©ÁØ´Ù.

check.show "flash erased. next step is flash download. go?"

print "Down binary : stm32f10x internal flash start address 0x08000000"

; 0x08000000 : STM32ÀÇ °æ¿ì FlashÀÇ ½ÃÀÛ ÁÖ¼Ò ÀÌ´Ù. ¿ø·¡´Â Cortex-M3¿¡¼­ ¿ø·¡Àº 0x0 ÀÌÁö¸¸ STM32¿¡¼­´Â Remap µÇ¾î ÀÖ´Ù.
flash.program "D:\JKElectronics\STM32\\stm32_middle\prj\MDK-ARM\STM32F107VCT6_100\stm32_core.bin" 0x08000000




(4) Hex ÆÄÀÏ Æ÷¸ËÀ» Bin ÆÄÀÏ·Î º¯È¯
KEIL ÄÄÆÄÀÏ·¯ÀÇ °æ¿ì ±âº»ÀûÀ¸·Î Ãâ·Â Æ÷¸ËÀÌ Hex ÆÄÀÏ ÀÔ´Ï´Ù. ÀÌ·² °æ¿ì Hex ÆÄÀÏÀ» Bin ÆÄÀÏ·Î º¯È¯ ÈÄ ´Ù¿î·Îµå¸¦ ÁøÇà ÇØ¾ß ÇÕ´Ï´Ù.

"Output Converter" ¸¦ ½ÇÇà ÇÕ´Ï´Ù.

armjtag

º¯È¯ÇÒ Hex ÆÄÀÏÀ» ¼±Åà ÇÕ´Ï´Ù.

armjtag

Bin ÆÄÀÏ·Î º¯È¯ÀÌ ¿Ï·áµÈ È­¸é ÀÔ´Ï´Ù.

armjtag

(5) ¼öÁ¤µÈ ½ºÅ©¸³Æ® ÀúÀå

¹Ýµå½Ã ½ºÅ©¸³Æ®¸¦ ¼öÁ¤ÇÑ ´ÙÀ½ ¾Æ·¡ÀÇ ¾ÆÀÌÄÜ or "File/Save" ¸í·ÉÀ» ÀÌ¿ëÇؼ­ ½ºÅ©¸³Æ®¸¦ ÀúÀåÇØ¾ß ÇÕ´Ï´Ù. ¾ÆÁ÷ "CTRL+S" µîÀÇ ´ÜÃàÅ°´Â Áö¿øÇÏÁö ¾Ê°í ÀÖ½À´Ï´Ù.

armjtag

(5) ¼öÁ¤ÇÑ "jcs ½ºÅ©¸³Æ®" ÆÄÀÏÀ» ½ÇÇà ÇÕ´Ï´Ù.

armjtag

"17" ¹ø ¿¡¼­ ¼öÁ¤ÇÑ ½ºÅ©¸³Æ®¸¦ ½ÇÇàÇؼ­ ½ÇÁ¦·Î binary ÆÄÀÏÀ» Target º¸µå¿¡ ´Ù¿î·Îµå¸¦ ÁøÇà ÇÕ´Ï´Ù.

armjtag

armjtag

"GO" ¸¦ ÀÌ¿ëÇؼ­ °è¼Ó ÁøÇàÀ» Çϸé Flash ´Ù¿î·Îµå°¡ ¿Ï·á µË´Ï´Ù.

armjtag

´Ù¿î·Îµå°¡ ¿Ï·áµÇ°í ³ª¼­ TargetÀ» Reset ½ÃŲ ÈÄ °á°ú¸¦ È®ÀÎ ÇÕ´Ï´Ù.