2013-01-18 61 views
1

我使用eclipse CDTstm32f0-discovery製作軟件,我使用ST-link來使用usb編程此控制器。Eclipse GDB結合OpenOCD

前幾天我進入調試使用OpenOCD6.0.1我的片我也跟着這個教程:

debugger tutorial

了幾個小時,我得到這個工作能夠一步真我的程序設置斷點和之後的所有其他一些調試的東西。現在,這是奇怪的事情發生。我開始改變我的配置 - >監控重置暫停 - >監控soft_reset_halt。我這樣做是因爲我最終希望開發一個stm32f0系列芯片的電路板,我只能用三根電線編程(SWD編程)。因爲我沒有得到這個工作,我恢復了設置,以監視重置暫停。

今天我想調試我的芯片,我遇到了以下情況,當我開始調試eclipse時,我發現我的設備處於其復位處理程序(這對我來說似乎是正確的,因爲顯示器復位暫停命令)openocd在這一點上輸出是:

Open On-Chip Debugger 0.6.1 (2012-10-07-10:34) 
Licensed under GNU GPL v2 
For bug reports, read 
    http://openocd.sourceforge.net/doc/doxygen/bugs.html 
adapter speed: 1000 kHz 
srst_only separate srst_nogate srst_open_drain 
Info : clock speed 1000 kHz 
Info : stm32f0x.cpu: hardware has 4 breakpoints, 2 watchpoints 
Info : accepting 'gdb' connection from 3333 
Info : device id = 0x20006440 
Info : flash size = 64kbytes 
Warn : acknowledgment received, but no packet pending 
undefined debug reason 6 - target needs reset 
target state: halted 
target halted due to debug-request, current mode: Thread 
xPSR: 0xc1000000 pc: 0x0800291c msp: 0x20002000 
Info : Padding image section 0 with 4 bytes 
target state: halted 
target halted due to breakpoint, current mode: Thread 
xPSR: 0x61000000 pc: 0x2000003a msp: 0x20002000 
Warn : stepi ignored. GDB will now fetch the register state from the target. 

現在,我想跨過復位處理程序,開始我的程序,然後我得到這樣的警告:

警告:步驟1忽略。 GDB現在將從 目標中獲取寄存器狀態。

一些谷歌搜索後,我無法找到什麼導致這一點。有沒有人有解決這個問題的線索?

回答

1

好吧,我發現了這一個。因爲我使用了多個stm32f0discovery板(一個在我的工作上,另一個在家裏的愛好)。董事會的配置不同。因此,我不得不更新沒有工作的板卡的固件。固件是2個版本,然後是我在家裏的版本。

問題解決了:)