arm/最新のOpenOCDを使ったフラッシュへの書き込みとデバッグ
をテンプレートにして作成
[
トップ
] [
新規
|
一覧
|
単語検索
|
最終更新
|
ヘルプ
]
開始行:
[[FrontPage]]
#contents
2010/03/31からのアクセス回数 &counter;
しばらくARMから離れていたら、最新のOpenOCDが大きく、
機能アップしており、様変わりしていました。
** 最新のOpenOCD(ver. 0.4.0)を使ってフラッシュに書き込む ...
新しい機能で面白いと思ったのが、(([[xoのブログ>http://www...
- sourceコマンドでfind指定でファイルをインクルードする機能
- コンフィグファイル内に関数(proc)を記述できること
sourceコマンドでのfind指定は以下のような形式で使用します。
#pre{{
source [find target/lpc2214.cfg]
}}
これまで、JTAGとボードに合わせてopenocd.cfgを作っていまし...
#pre{{
telnet_port 4444
gdb_port 3333
source [find interface/my-jtag.cfg]
source [find target/lpc2214.cfg]
}}
のように簡単に記述することができます。
コンフィグ内のprocを使うと、フラッシュへの書き込みとデバ...
#pre{{
# OpenOCD lpc2214 cfg with Flash proc
telnet_port 4444
gdb_port 3333
source [find interface/my-jtag.cfg]
source [find target/lpc2214.cfg]
# 高速書き込みのために追加
arm7_9 dcc_downloads enable
arm7_9 fast_memory_access enable
proc flash_program {ELF_FILENAME} {
halt
flash probe 0
flash write_image erase $ELF_FILENAME
echo "flash program complete. reset and run"
resume
reset run
exit
}
init
}}
できあがったopenocd.cfgを使ってlpc2214のフラッシュに書き...
#pre{{
$ /opt/local/bin/openocd -f openocd.cfg -c "flash_program...
Open On-Chip Debugger 0.4.0 (2010-03-29-18:37)
Licensed under GNU GPL v2
For bug reports, read
http://openocd.berlios.de/doc/doxygen/bugs.html
trst_and_srst srst_pulls_trst srst_gates_jtag trst_push_p...
jtag_nsrst_delay: 100
jtag_ntrst_delay: 100
2000 kHz
dcc downloads are enabled
fast memory access is enabled
Info : clock speed 2000 kHz
Info : JTAG tap: lpc2214.cpu tap/device found: 0x4f1f0f0f...
Info : Embedded ICE version 4
Info : lpc2214.cpu: hardware has 2 breakpoint/watchpoint ...
target state: halted
target halted in ARM state due to debug-request, current ...
cpsr: 0x200000d3 pc: 0x0000015c
flash 'lpc2000' found at 0x00000000
auto erase enabled
Warn : Verification will fail since checksum in image (0x...
different from calculated vector checksum (0x9edfff21).
Warn : To remove this warning modify build tools on devel...
vector checksum.
wrote 8192 bytes from file blink.elf in 0.308415s (25.939...
flash program complete. reset and run
Info : JTAG tap: lpc2214.cpu tap/device found: 0x4f1f0f0f...
}}
LPCベクターのチェックサムが合わない旨エラーがでますが、無...
http://forum.sparkfun.com/viewtopic.php?t=16417&sid=fab1a...
** Eclipseを使ったデバッグ [#cbc6ba80]
新しいOpenOCDでは、デバッグの設定も変わっていました。
以下のURLで使える設定を見つけました。
http://homepage3.nifty.com/zus/ARM_LPC2388_Dev_Main.html
上記サイトを参考にCommandsタグのInitialize commandsを以下...
#pre{{
target remote localhost:3333
file blink.elf
monitor reset
monitor halt
monitor debug_level 2
load
monitor soft_reset_halt
set mem inaccessible-by-default off
monitor debug_level 0
thbreak main
}}
** コメント [#a4539b8a]
#vote(おもしろかった[7],そうでもない[0],わかりずらい[0])
皆様のご意見、ご希望をお待ちしております。
#comment_kcaptcha
終了行:
[[FrontPage]]
#contents
2010/03/31からのアクセス回数 &counter;
しばらくARMから離れていたら、最新のOpenOCDが大きく、
機能アップしており、様変わりしていました。
** 最新のOpenOCD(ver. 0.4.0)を使ってフラッシュに書き込む ...
新しい機能で面白いと思ったのが、(([[xoのブログ>http://www...
- sourceコマンドでfind指定でファイルをインクルードする機能
- コンフィグファイル内に関数(proc)を記述できること
sourceコマンドでのfind指定は以下のような形式で使用します。
#pre{{
source [find target/lpc2214.cfg]
}}
これまで、JTAGとボードに合わせてopenocd.cfgを作っていまし...
#pre{{
telnet_port 4444
gdb_port 3333
source [find interface/my-jtag.cfg]
source [find target/lpc2214.cfg]
}}
のように簡単に記述することができます。
コンフィグ内のprocを使うと、フラッシュへの書き込みとデバ...
#pre{{
# OpenOCD lpc2214 cfg with Flash proc
telnet_port 4444
gdb_port 3333
source [find interface/my-jtag.cfg]
source [find target/lpc2214.cfg]
# 高速書き込みのために追加
arm7_9 dcc_downloads enable
arm7_9 fast_memory_access enable
proc flash_program {ELF_FILENAME} {
halt
flash probe 0
flash write_image erase $ELF_FILENAME
echo "flash program complete. reset and run"
resume
reset run
exit
}
init
}}
できあがったopenocd.cfgを使ってlpc2214のフラッシュに書き...
#pre{{
$ /opt/local/bin/openocd -f openocd.cfg -c "flash_program...
Open On-Chip Debugger 0.4.0 (2010-03-29-18:37)
Licensed under GNU GPL v2
For bug reports, read
http://openocd.berlios.de/doc/doxygen/bugs.html
trst_and_srst srst_pulls_trst srst_gates_jtag trst_push_p...
jtag_nsrst_delay: 100
jtag_ntrst_delay: 100
2000 kHz
dcc downloads are enabled
fast memory access is enabled
Info : clock speed 2000 kHz
Info : JTAG tap: lpc2214.cpu tap/device found: 0x4f1f0f0f...
Info : Embedded ICE version 4
Info : lpc2214.cpu: hardware has 2 breakpoint/watchpoint ...
target state: halted
target halted in ARM state due to debug-request, current ...
cpsr: 0x200000d3 pc: 0x0000015c
flash 'lpc2000' found at 0x00000000
auto erase enabled
Warn : Verification will fail since checksum in image (0x...
different from calculated vector checksum (0x9edfff21).
Warn : To remove this warning modify build tools on devel...
vector checksum.
wrote 8192 bytes from file blink.elf in 0.308415s (25.939...
flash program complete. reset and run
Info : JTAG tap: lpc2214.cpu tap/device found: 0x4f1f0f0f...
}}
LPCベクターのチェックサムが合わない旨エラーがでますが、無...
http://forum.sparkfun.com/viewtopic.php?t=16417&sid=fab1a...
** Eclipseを使ったデバッグ [#cbc6ba80]
新しいOpenOCDでは、デバッグの設定も変わっていました。
以下のURLで使える設定を見つけました。
http://homepage3.nifty.com/zus/ARM_LPC2388_Dev_Main.html
上記サイトを参考にCommandsタグのInitialize commandsを以下...
#pre{{
target remote localhost:3333
file blink.elf
monitor reset
monitor halt
monitor debug_level 2
load
monitor soft_reset_halt
set mem inaccessible-by-default off
monitor debug_level 0
thbreak main
}}
** コメント [#a4539b8a]
#vote(おもしろかった[7],そうでもない[0],わかりずらい[0])
皆様のご意見、ご希望をお待ちしております。
#comment_kcaptcha
ページ名:
SmartDoc