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.

CCS: TMS570LC4357 - SafeTI Diagnosis Library : About boot test

Other Parts Discussed in Thread: TMS570LC4357, HALCOGEN, SAFETI-HERCULES-DIAG-LIB-CSP

Tool/software: Code Composer Studio

In TMS570LC4357 - SafeTI Diagnosis Library, there are a little SL_SelfTest.

The test items are like these.

    /* Boot time MIBSPI Analog Loopback Test */
    SL_SelfTest_MibSPI(MIBSPI_ANALOG_LOOPBACK_TEST,SL_MIBSPI2);

    SL_SelfTest_MibSPI(MIBSPI_ANALOG_LOOPBACK_TEST,SL_MIBSPI4);

    SL_SelfTest_MibSPI(MIBSPI_ANALOG_LOOPBACK_TEST,SL_MIBSPI3);

    SL_SelfTest_MibSPI(MIBSPI_ANALOG_LOOPBACK_TEST,SL_MIBSPI1);

    SL_SelfTest_MibSPI(MIBSPI_ANALOG_LOOPBACK_TEST,SL_MIBSPI5);


    //Boot time Software test of VIM functionality
       SL_SelfTest_VIM(VIM_SOFTWARE_TEST);

    //Boot time Software test of DMA functionality
       SL_SelfTest_DMA(DMA_SOFTWARE_TEST);

I have some questions.

1. These functions are acted as return fail(false) or pass(true).  But, there are no return value. I want to know how i can confirm the test is passed.

2. The test items are MIBSPI, VIM, DMA. The other items are not required in boot sequence?

3. In the main loop, the SL_SelfTest is executed. Can I confirm the test is acted as well by the periodicSTPassCount? (If the total test number is 118, the test result is periodicSTPassCount is 118 and periodicSTFailCount is 0)

  • Minwoo,

    Yes, you need to check the return value to check for pass or fail result from the diagnsostic self tests. It appears that you are looking at the halcogen generated source (HL_sys_startupc) for the safety diagnostic library.  This doesn`t implement return value and logging action to take if a failure is detected. I recommend that you look at the "demo_app\common\source\app_main_NoOS.c", this is not just the automated code generated from Halcogen but demonstrates how the failures can be logged.  The same tests are implemented using following in the modified demo app:

            retVal = SL_SelfTest_MibSPI(MIBSPI_SRAM_PARITY_TEST,SL_MIBSPI1);
            INCREMENT_PASS_FAIL_COUNTER(ST_PASS, retVal);
            retVal = SL_SelfTest_MibSPI(MIBSPI_SRAM_PARITY_TEST,SL_MIBSPI3);
            INCREMENT_PASS_FAIL_COUNTER(ST_PASS, retVal);
            retVal = SL_SelfTest_MibSPI(MIBSPI_SRAM_PARITY_TEST,SL_MIBSPI5);
            INCREMENT_PASS_FAIL_COUNTER(ST_PASS, retVal);

    There are couple of documents that we provide for determining what tests need to run at the time of boot during the boot sequence. One is the software Safety manual (included under docs that indicates what test maps which requirement that may be indicated in your usecase) and the second is the document SPNA106 that discusses Initialization of Hercules ARM Microcontrollers.

    The SDL is designed to provide diagnostic coverage to different portions of the chip. The periodic tests don`t always need to report pass but need to have the ability to catch a failure on the device but will report PASS when the safe function is working as expected. Typically along with the demo packages we also provide a compliance package that contains regression reports. We are working on providing those for TMS570LC43x parts but unitl then you can look at the test coverage reports using this self tests with different test cases and procedural outputs in the reports provided for TMS570LS31x. You can check the regression test reports for SDL with Compliance support package for test results for these periodic tests in the folder docs\TMS570LS31x\Test\ConsolidatedReports

    Regards,

    Rahul

    PS: If you don`t have the CSP reports you can request the  SAFETI-HERCULES-DIAG-LIB-CSP from here:

    http://www.ti.com/tool/SAFETI-HERCULES-DIAG-LIB-CSP