SensorTag编译错误Error[e16]: Segment ISTACK (size: 0xc0 align: 0) is too long for segment definition.
问题:
IAR 8051 8.302,编译TI的BLE-CC254x-1.4.0的SensorTag工程,对此工程没有进行任何改动,直接编译,出现如下错误:

分析:
参考TI技术论坛【http://www.deyisupport.com/question_answer/wireless_connectivity/bluetooth/f/103/t/51684.aspx】
从讨论得知是IAR的配置问题
故需修改IAR工程配置
解决:
依次打开Project -> Options -> General Option -> Target,在Target标签中找到“Number of virtual”,原来默认为16,修改为8。如下:

重新make SensorTag工程,编译成功。
类似的,其他BLE工程,如SimpleBLEPeripheral等,编译时出现同样的错误,按照上述解决方法,即可解决。
http://bbs.eeworld.com.cn/thread-420601-1-1.html
IAR 8.3以后的版本编译TI BLE Stack会报类似如下的错误
- Error[e16]: Segment ISTACK (size: 0xc0 align: 0) is too long for segment definition. At least 0xe more bytes needed. The problem occurred while processing the segment
- placement command "-Z(IDATA)ISTACK+_IDATA_STACK_SIZE#08-_IDATA_END", where at the moment of placement the available memory ranges were "IDATA:4e-ff"
解决办法是:
找到
- C:\Texas Instruments\BLE-CC254x-1.4.0\Projects\ble\common\cc2540\ti_51ew_cc2540b.xcl
把里面的
- -Z(DATA)VREG+_NR_OF_VIRTUAL_REGISTERS=08-7F
这一句 改成
- -Z(DATA)VREG=08-7F
参考资料:
http://blog.csdn.net/zhangjs0322/article/details/34108663
http://www.deyisupport.com/question_answer/wireless_connectivity/bluetooth/f/103/t/51684.aspx



