【应用手册】Nios II MPU Usage
This application note covers the basic features of the Nios® II processor’s optional
memory protection unit (MPU), describing how to use it without the support of an
operating system (OS). When the Nios II MPU is enabled and properly configured, it
monitors all processor data and instruction accesses and triggers exceptions when
illegal accesses are attempted.
This application note includes two design examples, with notes about how the
examples work. These examples walk you through making use of the Nios II
processor's MPU in an environment based on the Altera® hardware abstraction layer
(HAL), without an OS. One of the examples uses the MPU to detect the following
three issues commonly seen when debugging embedded systems:
■ Stack overflow
■ Null pointer
■ Wild pointer
an540.pdf