Release Mode: A project built in release mode is capable of running independently on the target hardware without any control or intervention by MPLAB X and any of its associated debug tools. When connected to a debug tool, MPLAB X has no control of a target device in release mode other than to hold it in reset or to program it.
There are several options available when building a project in release mode. It is not necessary to explicitly choose a "Release" mode when performing a release build.
Build Project (Make)
Builds (makes) the project in release mode. This will build only files that have changed since the last build.
Clean and Build Project (Build All / Rebuild)
Cleans (deletes) all files generated by the previous build and then builds all files in the project the project in release mode.
Builds (makes) the project in release mode, programs the target, and releases the device from reset so that the program starts running. The debug tool has no control over the program's execution in this mode.
Program Target Project
Programs the target device in release mode and holds the target device in reset.
The build process in MPLAB® X is a little different from other development environments. If you are working with a target board and wish to build and run your code on it, you do not need to do a Build or Clean and Build first. Instead, you simply need to do a Run Project.
The Run Project button performs the following tasks:
- Build (make) the project in release mode.
- If there are no build errors, your application is programmed into the target device using the debug/programming tool selected in the project options.
- The target device is released from reset and your code begins running unless you have selected Hold In Reset from the toolbar.