1. 安装 gdbstub
在电话上安装gdbstub.sis。这个文件由Nokia SDK在默认下在以下路径中安装:C:\ Symbian\7.0s\Series60_v20\Epoc32\release\armi\urel\.
2. 创建 gdbstub.ini
你应该创建一个文件夹 C:\ gdbstub。并且在这个文件中使用记事本,创建一个包含以下内容的文件gdbstub.ini。
|
General |
Bluetooth |
|
[COMMSERV] |
[COMMSERV] |
|
PDD=EUART%d |
PDD=EUART1 |
|
LDD=ECOMM |
LDD=ECOMM |
|
CSY=IRCOMM |
CSY=BTCOMM |
|
PORT=0 |
PORT=0 |
|
RATE=115200 |
RATE=9600 |
3. 创建 gdb.ini
在计算机中创建一个目录并且一定要在c:\ bbb,把gdb.ini放入这个文件夹。Gdb.ini文件内容如下:
symbol-file //c/symbian/7.0s/series60_v20/epoc32/release/armi/udeb/aaa.sym epoc-exec-file c:\system\apps\aaa\aaa.app target epoc com3 break NewApplication source //c/symbian/7.0s/shared/epoc32/gcc/share/epoc-des.ini
用适当的名字替换所有的bbb和aaa
注意: 请检查你正在使用通道数,在线路3中放入适当的com 数到它中,不包括:infra=2,Bluetooth=3
注意: com数通常不大于4并且大于1。
4. 编辑
程序的调试将会使用armi udeb:
abld创建armi udeb
如果有任何错误或警告,就把epoc32/release/armi/urel中的复制到epoc32/release/armi/udeb。
5. 更新pkg文件
现在找到程序的xxx.pkg文件然后改变所有的路径以便在目录armi\ udeb下编译。
然后创建sis文件并而安装
6.启动调试器
1.你应该有一个叫做FExplorer的程式,或者下载它并安装它。、
2.通过这个程式到目录 : c:\ system\program\gdbstub.exe
3.检查为dll文件在c:\ system\lib\ :下的gdbseal.dll 和 gdbseng.dll
4.启动gdbstub.exe 。
5.在你的计算机DOS中, 在目录c:\ bbb下并且运行gdb.exe-nw
(gdb.exe将与Symbian SDK一起并且确定它在系统路径之中)
以下信息将会出现:
GNU gdb 4.17-psion-98r2 Copyright 1998 Free Software Foundation, Inc. GDB is free software, covered by the GNU General Public License, and you are welcome to change it and/or Breakpoint 1 at 0x(some adress): file <your source file that contains NewApplication> gdb>
然后在gdb提示下,键入run。将会出现以下信息:
Starting program: warning: Application started but no document specified. The application may panic at some point if it is document based and if there is no existing default document. Breakpoint 1 0x(some adress): file <your source file that contains NewApplication> Breakpoint 1, NewApplication () at file <your source file that contains NewApplication> <some sourcecode> Current language: auto; currently c++
注意 : 在gdb指令中检查Symbian SDK 文件从而得到更多的帮助。
清单
:
I硬件:
1. PC机
2. 兼容的Bluetooth / InfraRed
3. Symbian电话
II软件:
PC :
1. Symbian SDK(可以免费的从Symbian/Nokia站点得到)
2. VC++6.0
3. Bluetooth驱动程序(可以在CD与Bluetooth得到)
4. gdb.ini
Symbian 电话:
1. gdbstub.sis
2. gdbstub.ini
3. fexplorer.sis
此文为开发视界原创转载者请注明出处否则追究法律责任
|