This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

MSP432程序烧写失败问题



仿真器使用的是XDS100 V3.0,MSP432供电电压3.3V,开发环境CCS6.1.1。自己设计的PCB板,开始一直能够烧写程序(带UCOS),后来为了验证MSP432在LPM4.5的功耗,写了一个简单的测试程序,第一次烧写这个测试程序成功了,之后就再也烧不进去了。测试程序代码如下:

void main(void)
{
    int n = 100000;
	
    WDTCTL = WDTPW | WDTHOLD;           // Stop watchdog timer
	
    P1SEL0 = 0x00;
    P1SEL1 = 0x00;
    P1DIR = 0xFF;
    P1OUT = 0x00;

    P2SEL0 = 0x00;
    P2SEL1 = 0x00;
    P2DIR = 0xFD;
    P2OUT = 0x00;

    P3SEL0 = 0x00;
    P3SEL1 = 0x00;
    P3DIR = 0xFF;
    P3OUT = 0x00;

    P4SEL0 = 0x00;
    P4SEL1 = 0x00;
    P4DIR = 0xFF;
    P4OUT = 0x00;

    P5SEL0 = 0x00;
    P5SEL1 = 0x00;
    P5DIR = 0x37;
    P5OUT = 0x00;

    P6SEL0 = 0x00;
    P6SEL1 = 0x00;
    P6DIR = 0xFF;
    P6OUT = 0x00;

    P7SEL0 = 0x00;
    P7SEL1 = 0x00;
    P7DIR = 0xFF;
    P7OUT = 0x00;

    P8SEL0 = 0x00;
    P8SEL1 = 0x00;
    P8DIR = 0xFF;
    P8OUT = 0x00;

    P9SEL0 = 0x00;
    P9SEL1 = 0x00;
    P9DIR = 0xFF;
    P9OUT = 0x00;

    P10SEL0 = 0x00;
    P10SEL1 = 0x00;
    P10DIR = 0xFF;
    P10OUT = 0x00;

    PJSEL0 = 0x00;
    PJSEL1 = 0x00;
    PJDIR = 0xFF;
    PJOUT = 0x00;

    P5OUT = 0x10;
    while (n--);
    P5OUT = 0x00;

    MAP_PCM_shutdownDevice(PCM_LPM35_VCORE0);
    __no_operation();
}

在CCS下“Test Connection”出现的错误信息如下:

[Start: Texas Instruments XDS100v3 USB Debug Probe]

Execute the command:

%ccs_base%/common/uscif/dbgjtag -f %boarddatafile% -rv -o -F inform,logfile=yes -S pathlength -S integrity

[Result]


-----[Print the board config pathname(s)]------------------------------------

C:\Users\ADMINI~1\AppData\Local\TEXASI~1\
CCS\ccs\0\0\BrdDat\testBoard.dat

-----[Print the reset-command software log-file]-----------------------------

This utility has selected a 100- or 510-class product.
This utility will load the adapter 'jioserdesusbv3.dll'.
The library build date was 'Sep 4 2015'.
The library build time was '21:59:23'.
The library package version is '6.0.14.5'.
The library component version is '35.35.0.0'.
The controller does not use a programmable FPGA.
The controller has a version number of '4' (0x00000004).
The controller has an insertion length of '0' (0x00000000).
This utility will attempt to reset the controller.
This utility has successfully reset the controller.

-----[Print the reset-command hardware log-file]-----------------------------

The scan-path will be reset by toggling the JTAG TRST signal.
The controller is the FTDI FT2232 with USB interface.
The link from controller to target is direct (without cable).
The software is configured for FTDI FT2232 features.
The controller cannot monitor the value on the EMU[0] pin.
The controller cannot monitor the value on the EMU[1] pin.
The controller cannot control the timing on output pins.
The controller cannot control the timing on input pins.
The scan-path link-delay has been set to exactly '0' (0x0000).

An error occurred while hard opening the controller.

-----[An error has occurred and this utility has aborted]--------------------

This error is generated by TI's USCIF driver or utilities.

The value is '-230' (0xffffff1a).
The title is 'SC_ERR_PATH_MEASURE'.

The explanation is:
The measured lengths of the JTAG IR and DR scan-paths are invalid.
This indicates that an error exists in the link-delay or scan-path.

[End: Texas Instruments XDS100v3 USB Debug Probe]

经检查,MSP432供电电压以及JTAG信号线连接都正常,以上的测试程序是否会使JTAG接口出现异常?或者是什么其他原因?

  • The link from controller to target is direct (without cable)

    从控制器到目标的连接是直接的(没有电缆)

     

    先检查下各处连接。如果有条件,用逻辑分析仪观察下jtag相关引脚的波形是否正常

  • 找到问题的原因了,犯了低级错误,我的测试程序里PJSEL0 = 0x00; PJSEL1 = 0x00;两句把PJ.4和PJ.5设成了普通IO,而不是TDI和TDO,导致JTAG不再起作用。

    解决方法:修改程序,使PJ.4和PJ.5为TDI和TDO功能,然后使用SWD方式把程序烧写进芯片,之后就可以再次使用JTAG烧写了。

    PS:MSP432的技术参考手册里,PJSEL0和PJSEL1的复位值都是0,即PJ口的所有引脚都设置成了普通IO,那么将PJ.4和PJ.5使能为TDI和TDO的设置是在芯片内置的BSL代码中实现的吗?

  • 你好,我想请问一下自己画的板子432芯片哪里买的?

  • 可以直接从官网购买,或者建议当地的代理商