The application validation mechanism allows the bootloader to validate the application before executing it. Three methods are implemented to allow for different levels of code footprint and security:
- None: Application is not validated and assumed to be always valid. An external event can be used to force bootloader mode. Not recommended.
- Reset vector: If the reset vector is different from 0xFFFF (erased state), the application is assumed to be valid and is executed.
- CRC_CCITT: A CRC CCITT is calculated for the whole application image and compared to an expected value. Note that the BSL-based protocol (see Section 2.4.2.1) uses CRC CCITT, so this validation method is recommended when using the BSL-based protocol. Additionally, this method does not take into account applications that modify the contents of flash such as data logging. When this type of application executes, the CRC CCITT stored in flash becomes incorrect and the bootloader will not allow the application to run even though it may be valid. When developing an application that modifies flash, it is recommended to use the reset vector validation method.
Note that the validation methods can prevent execution of corrupted applications, but they do not ensure the integrity and functionality of the application, which is the responsibility of the user. If the application does not have the intended functionality, the MSP430 device can still be recovered using a hardware entry sequence.