NXP Semiconductors EVKmimx8mm Скачать руководство пользователя страница 23

The post-build calculation is different for each IDE:
In the IAR IDE, the CRC is calculated by the IDE directly using the linker (see Options->Build Action). The Flash test is fully
integrated to the example project in the IAR IDE. It is necessary only to turn this test on in the 

safety_config.h

 file.

In the uVision Keil IDE, the CRC is calculated by the Srecord third-party tool, which is called from the IDE (see Options → User
→ After Build) The Flash test is fully integrated to the example project in the uVison Keil IDE. It is only necessary to turn this test
on in the 

safety_config.h

 file. In case of any issues, see 

Arm uVison Keil IDE postbuild CRC

In the MCUXpresso IDE, the CRC is calculated by the Srecord third-party tool. The user must do some additional steps. For more
information, see 

MCUxpresso postbuild CRC

.

 

The invariable memory test example uses the 

crc.bat file for post-build calculation, so this example does not work

on a Unix/Mac operating system.

  NOTE  

 

When you debug your application with the Flash test turned on, be careful when using the breakpoint. The software
breakpoint usually changes the CRC result and causes a safety error.

  NOTE  

6.5 Variable memory test

The variable memory on the supported MCU is an on-chip RAM.
The RAM memory test is provided by the MarchC or MarchX tests.
The test copies a block of memory to the backup area defined by the linker. Be sure that the BLOCK_SIZE parameter is smaller
than the backup area defined by the linker.

 

This test cannot be interupted.

  NOTE  

6.6 Program counter test

The CPU program counter register test procedure tests the CPU program counter register for the stuck-at condition. The program
counter register test can be performed once after the MCU reset and also during runtime.

 

The program counter test cannot be interrupted.

  NOTE  

6.7 Stack test

This test routine is used to test the overflow and underflow conditions of the application stack. The testing of the stuck-at faults in
the memory area occupied by the stack is covered by the variable memory test. The overflow or underflow of the stack can occur
if the stack is incorrectly controlled or by defining the "too-low" stack area for the given application.

 

Choose a correct pattern to fill the tested area. This pattern must be unique to the application.

  NOTE  

6.8 Watchdog test

The watchdog test provides the testing of the watchdog timer functionality. The test is run only once after the reset. The test causes
the WDOG reset and compares the preset time for the WDOG reset to the real time.
For this test to run correctly, it is necessary to keep the WDOG_backup variable in a part of memory which is not corrupeted by
the WDOG reset.

Variable memory test

i.MX8M Safety Example , Rev. 3, 07/2021

NXP Semiconductors

23

Содержание EVKmimx8mm

Страница 1: ...i MX8M Safety Example NXP Semiconductors Document identifier IEC60730BIMX8MXEUG User s Guide Rev 3 07 2021...

Страница 2: ...guide 3 Chapter 2 Hardware settings 4 Chapter 3 File structure 7 Chapter 4 Example application 9 Chapter 5 Running example 14 Chapter 6 IEC60730B tests 22 Chapter 7 Revision history 25 NXP Semiconduc...

Страница 3: ...gh the MCUXpresso SDK website This example user s guide describes how to set the hardware correctly and how to use the example code with the IEC60730B Safety library The library user s guide is the ma...

Страница 4: ...bugger The default debugger in the example project is set to J Link FreeMASTER FreeMASTER communication is used via an external J Link plugin The hardware settings are as follows 1 Connect the 12 V po...

Страница 5: ...he 12 V power supply J302 USB port and the J Link debug probe to the board and switch the SW101 switch to power on the board 2 Connect a USB C cable between the host PC and the J301 USB port this port...

Страница 6: ...Figure 2 Hardware connection of EVK MIMX8MN EVK MIMX8MN Nano i MX8M Safety Example Rev 3 07 2021 NXP Semiconductors 6...

Страница 7: ...tains the source files for the peripheral test this is a common cross core These tests are compiled to library libIEC60730B_ core _COM_ compiler _ version a The compiler folder contains compiler suppo...

Страница 8: ...gure 4 Figure 4 Example of project structure in example folder This folder contains the example source file and three folders for the IDE project file iar mcux mdk The following files are generated by...

Страница 9: ...K library and safety example related folders The safety related folders are the following Board this folder contains the files related to the board used clock_config h pin_config h board h and so on C...

Страница 10: ...t The project_setup_ your_board c file contains the setup functions clock port UART and so on The file contains the handling function for safety routines from the IEC60730B library and also the test i...

Страница 11: ...the Device Manager Two new COM ports should appear Open both COM ports in the serial terminal with settings mentioned above The COM port with the higher number shows the output of the bootloader The o...

Страница 12: ...size 256 Bytes erase size 4 KiB total 32 MiB SF 20480 bytes 0x0 Erased OK device 0 offset 0x0 size 0x4864 SF 18532 bytes 0x0 Written OK The image is now downloaded into the QSPI flash Turn the board o...

Страница 13: ...test The file contains the fs_dio_test_ platform _t list of structures The pointers to these structures are collected in the dio_safety_test_items array which is used in the example application 4 5 So...

Страница 14: ...e post build command calls the crc hex bat file which supports the CRC16 and CRC32 calculations The crc hex bat file is in your SDK package in the sdk_package middleware safety_iec60730b tools crc fol...

Страница 15: ...ipt The linker script depends on the IDE used The exact description for the supported IDE is in the following chapter 5 1 2 Arm uVison Keil IDE postbuild CRC The safety example in the uVision Keil use...

Страница 16: ...This command loads the YOUR_PROJECT _crc hex file from the debug relative path and this address is relative to the project file YOUR_PROJECT uvprojx in the presented case It means that the file is in...

Страница 17: ...d steps Post build steps menu Copy and paste the following post build string into it arm none eabi objcopy v O ihex BuildArtifactFileName BuildArtifactFileBaseName hex ProjDirPath crc_hex bat ConfigNa...

Страница 18: ...table can be defined as the following structure The safety related FLASH CRC value fs_crc_t c_sfsCRC __attribute__ used section flshcrc ui16Start 0xA55AU ui32FlashStart uint32_t __ROM_start__ ui32Fla...

Страница 19: ...ile 5 1 3 3 Flash loader configuration It is necessary to set a correct output file for the download to the target There are the following two ways to do this in the MCUXpresso IDE 1 Using the Debug c...

Страница 20: ...g GUI Flash Tool Only the SEGGER J Link probes in the GUI Flash Tool support hex files In the GUI Flash Tool settings select Workspace Configuration PROJECT_NAME _crc hex file for download Post build...

Страница 21: ...Figure 6 GUI Flash Tool SEGGER J Link Post build CRC calculation i MX8M Safety Example Rev 3 07 2021 NXP Semiconductors 21...

Страница 22: ...re tests all CPU registers for the stuck at condition except for the program counter register The program counter test is implemented as a stand alone safety routine Some tests stay in an endless loop...

Страница 23: ...by the MarchC or MarchX tests The test copies a block of memory to the backup area defined by the linker Be sure that the BLOCK_SIZE parameter is smaller than the backup area defined by the linker Th...

Страница 24: ...Some debuggers do not allow the WDOG reset Due to this it is necessary to turn off the WDOG when debugging the application NOTE Watchdog test i MX8M Safety Example Rev 3 07 2021 NXP Semiconductors 24...

Страница 25: ...er SDK Description 0 2 9 0 Intial release 1 2 10 0 Change devices supported in SDK rel 2 10 2 2 10 0 Post build description added 3 Version cover SDK 2 9 and SDK 2 10 release document for web NXP Semi...

Страница 26: ...ould implement appropriate design and operating safeguards to minimize the risks associated with their applications and products NXP the NXP logo NXP SECURE CONNECTIONS FOR A SMARTER WORLD COOLFLUX EM...

Отзывы: