原创 【TI博客大赛】MSP430的MSPGCC编译环境

2012-11-21 13:09 1940 9 9 分类: MCU/ 嵌入式

相比Eclipse,codeblocks显得很小巧(不想要MinGW的话也不到30M),无需JAVA环境,运行速度也很快,支持搭建多种开发环境,是我摆弄东西的首选平台。至于它的其它优点,自行google吧。

我的mspgcc是放在D:\mspgcc目录下,TI官方的烧录软件我放在"D:\mspgcc\flash_fet"目录下 ,请读者自行修改。
开始:
1) 先安装好codeblocks 10.05,这个很简单。下面的一个是不带minGW的只有23M,带minGW的74M
http://sourceforge.net/projects/codeblocks/files/Binaries/10.05/Windows/codeblocks-10.05-setup.exe/download
http://sourceforge.net/projects/codeblocks/files/Binaries/10.05/Windows/codeblocks-10.05mingw-setup.exe/download
2)下载MSPGCC(新版的只有37M),解压到“D:\mspgcc”
http://sourceforge.net/projects/mspgcc/files/Windows/mingw32/mspgcc-20120406-p20120502.zip/download
3)下载TI LuanchPad软件包,并将里面Flasher,driver等解压到“D:\mspgcc”目录下。(附件)

4)运行codeblocks,点击Setting->Compiler and debugger..
选择编译器 “GNU GCC Compiler for MSP430”


可以点击运行了。成功后显示信息~~

-------------- Build: Release in CB_MSP430_test001 ---------------

msp430-gcc.exe -Wall -mmcu=msp430g2553 -Os -O3 -ID:\mspgcc\msp430\include -ID:\mspgcc\include -c CB_MSP430_test001.c -o obj\Release\CB_MSP430_test001.o
msp430-gcc.exe -LD:\mspgcc\msp430\lib\ldscripts\msp430g2553 -LD:\mspgcc\msp430\lib -LD:\mspgcc\lib -o bin\Release\CB_MSP430_test001.elf obj\Release\CB_MSP430_test001.o -s
Output size is 584.00 bytes
Running target post-build steps
msp430-objcopy -O ihex bin/Release/CB_MSP430_test001.elf bin/Release/CB_MSP430_test001.a43
D:/mspgcc/msp_fet/MSP430Flasher.exe -n msp4302553 -w bin/Release/CB_MSP430_test001.a43 -v -g -z [VCC]
** ERROR: Unable to access log file. Log disabled.
** Please make sure the directory 'Log' exists in line with the executable.
Evaluating additional triggers...done
Initializing interface on TIUSB port...done
Checking firmware compatibility...done
Reading FW version...done
Reading HW version...done
Powering up...done
Configuring...done
Accessing device...done
Reading device information...done
Loading file into device...done
Verifying transfer...done
Resetting device...done
Refreshing registers...
/* ----------------------------------------------------------------------------
* UseCase : MSP430Flasher.exe
* Arguments : -n MSP4302553 -w bin/Release/CB_MSP430_test001.a43 -v -g -z [VCC]
* ATTENTION: Default options used due to invalid argument list.
* ----------------------------------------------------------------------------
* Driver : loaded
* Dll Version : 20409001
* FwVersion : 30394216
* Interface : TIUSB
* HwVersion : E 2.0
* Mode : AUTO
* Device : MSP430G2xx3
* EEM : Level 1, ClockCntrl 1
* Prog.File : bin/Release/CB_MSP430_test001.a43 (ERASE_ALL, verified = TRUE)
* BSL Unlock : FALSE
* InfoA Access: FALSE
* VCC ON : TRUE
* UseCase specific tasks: ----------------------------------------------------
* Powering up...done
* Disconnecting from device...
* ----------------------------------------------------------------------------
* Driver : closed (No error)
* ----------------------------------------------------------------------------
*/
Process terminated with status 0 (0 minutes, 7 seconds)
0 errors, 0 warnings


文章评论0条评论)

登录后参与讨论
我要评论
0
9
关闭 站长推荐上一条 /2 下一条