stm32c8t6自己做的板子用swd下载不了程序

2019-08-17 02:27发布

本帖最后由 bruceleegyx 于 2017-7-5 10:22 编辑

能识别芯片,但是到最后一步下载的时候出错了,弹出下图那个提示框。我的下载模式没选错,芯片我是64K的,选的是128K的,因为列表中看不到64K的,不过我之前选的128K的也没影响。
JLink info:
------------
DLL: V4.15n, compiled Jun 18 2010 19:55:09
Firmware: J-Link ARM V8 compiled Nov 28 2014 13:44:46
Hardware: V8.00
S/N : 87461523
Feature(s) : RDI, FlashBP, FlashDL, JFlash, GDBFull

* JLink Info: Found SWD-DP with ID 0x1BA01477
* JLink Info: TPIU fitted.
* JLink Info:   FPUnit: 6 code (BP) slots and 2 literal slots
ROMTableAddr = 0xE00FF003

Target info:
------------
Device: STM32F103C8
VTarget = 3.306V
State of Pins:
TCK: 0, TDI: 0, TDO: 1, TMS: 1, TRES: 1, TRST: 1
* JLink Info: Found SWD-DP with ID 0x1BA01477
* JLink Info: TPIU fitted.
* JLink Info:   FPUnit: 6 code (BP) slots and 2 literal slots
Hardware-Breakpoints: 6
Software-Breakpoints: 2048
Watchpoints:          4
JTAG speed: 4000 kHz

Erase Done.
Programming Failed!

友情提示: 此问题已得到解决,问题已经关闭,关闭后问题禁止继续编辑,回答。
9条回答
bruceleegyx
2019-08-17 21:30
1812090658@qq.c 发表于 2017-7-6 11:40
是不是软件装的有问题,报错但是程序是否下载成功,我下载Cortex-M0+的时候也会报错,试试使用J-Flash下载H ...

用J-Flash我也试过了,还是不行。应该不是MDK下载的问题,我有一块板子成功了,是可以用MDK下载的。下面是J-Flash出错的代码,您看看:
Application log started
- J-Flash ARM V4.08i (J-Flash compiled Jul 31 2009 18:25:26)
- JLinkARM.dll V4.08i (DLL compiled Jul 31 2009 18:23:57)
Reading flash device list [C:Program Files (x86)SEGGERJLinkARM_V408iETCJFlashFlash.csv] ...
- List of flash devices read successfully (586 Devices)
Reading MCU device list [C:Program Files (x86)SEGGERJLinkARM_V408iETCJFlashMCU.csv] ...
- List of MCU devices read successfully (353 Devices)
Opening project file [C:Program Files (x86)SEGGERJLinkARM_V408iDefault.jflash] ...
- Project opened successfully
Connecting ...
- Connecting via USB to J-Link device 0
- J-Link firmware: V1.20 (J-Link ARM V8 compiled Nov 28 2014 13:44:46)
- JTAG speed: 5 kHz (Fixed)
- Initializing CPU core (Init sequence) ...
    - Initialized successfully
- JTAG speed: 2000 kHz (Auto)
- Connected successfully
Opening data file [C:UsersAdministratorDesktopGPS电子罗盘数据采集 - 副本 (2)output工程模板.hex] ...
- Data file opened successfully (8184 bytes, 1 range, CRC = 0x00C4B7A8)
Auto programming target (8184 bytes, 1 range) ...
- Erasing affected sectors ...
    - ERROR: PC of target system has unexpected value after blank checking. (PC = 0xFFFFFFFE)!
---------------------------------------------------------------------- Registers -------------------------------------------------------------------------------------
            PC   = FFFFFFFE
Current:        R0   = 00003800,        R1   = 08000000,        R2   = 00000100,        R3   = 00003800
            R4   = 20000000,        R5   = 000037FC,        R6   = 000000FF,        R7   = 20000133
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------

    - ERROR: Failed to erase sectors
- ERROR: Failed to auto program target
Disconnecting ...
- Disconnected

一周热门 更多>