Migrating from MPLAB® IDE v8 to MPLAB® X IDE
Contents
Because MPLAB® X IDE is based on the NetBeans platform, many features will be different from the proprietary MPLAB IDE v8. Therefore, migrating to MPLAB X IDE from MPLAB IDE v8 or lower can be simplified by understanding the differences between the platforms.
Once these differences are understood, an MPLAB IDE v8 project can be imported into MPLAB X IDE as discussed in Import MPLAB 8 Project.
Source Base
MPLAB® X IDE is based on the open-source, cross-platform NetBeans platform. Third parties can easily add functionality as plug-ins. MPLAB X IDE components that are specific to Microchip products are still proprietary.
MPLAB IDE v8 is proprietary and Windows operating system based. Third parties can add to v8 with design information from the MPLAB development group.
Development Orientation
MPLAB® X IDE is project-based (no workspaces). In MPLAB X IDE, you must create a project to develop your application. Creating a project involves selecting a device, as well as selecting and setting up language tools, debug tools, programming tools, and other project specifics. This ensures all items needed for successfully developing an application are present. Multiple project grouping is handled by multiple configurations.
MPLAB IDE v8 is device-based. Although it is always highly recommended that you use a project in v8 to create your application, it is not required. Workspaces are used to contain some set-up information, including multi-project grouping.
Development Tool Selection
MPLAB® X IDE allows multiple tool selection
Example 1: Connect several MPLAB ICD 3 debuggers to several computer USB ports. Then access the Project properties to easily switch between the debuggers, which are identified by their serial numbers (SN).
Example 2: Connect one MPLAB ICD 3 debugger to a computer USB port and one MPLAB PM3 programmer to another USB port. Then access the Project properties to easily switch between the tools.
MPLAB IDE v8 does not allow multiple tool selections
Language Tool Selection
MPLAB® X IDE allows multiple language tool version selection
Example: Install two versions of the MPLAB C Compiler for PIC18 MCUs. Then access the Project properties to easily switch between versions of compiler toolchains.
MPLAB IDE v8 does not allow multiple language tool version selection
Debug Sessions
MPLAB® X IDE allows multiple debug and programming sessions. MPLAB X IDE allows you may have multiple debug sessions active in one IDE.
MPLAB IDE v8 allowed one debug or programming session. MPLAB IDE v8 allowed you to have multiple projects open in the IDE. However, you could only debug or program with one project at a time.
Build Configurations
MPLAB® X IDE allows multiple build configurations. MPLAB X IDE allows more than one build configuration.
MPLAB IDE v8 allowed only two configurations. MPLAB IDE v8 allowed you to select only between “Release” or “Debug” from the Build Configuration drop-down box and have use of __DEBUG in your own code.
To recreate the MPLAB IDE v8 functionality in MPLAB X IDE, you can create your own Debug configuration and __DEBUG macro.
Build/Programming Steps
MPLAB® X IDE provides multi-step options to debug and program. MPLAB X IDE has a “Debug Project” icon that builds, programs a target device with your program and a debug executive (for hardware tools), and runs your code in Debug mode in one click. Also available is a “Make and Program” icon that builds, programs a target device (for hardware tools), and runs your code in one click. If you do not want your program to run after make and program, use the “Hold in Reset” icon instead.
MPLAB IDE v8 required several manual steps to debug or program. MPLAB IDE v8 had a procedure that required completion before debugging or running code:
- select the correct build configuration (Release or Debug)
- build/make your code
- program the target with the code (for hardware tools)
- run your code.
For some tools, e.g., MPLAB Starter Kits, you still need to perform some steps independently. MPLAB X IDE provides this functionality under Debug>Discrete Debugger Operation.
Configuration Bits
MPLAB® X IDE uses configuration bits set in code. MPLAB X IDE requires that Configuration bits be set in code. However, you may temporarily change Configuration bits in the Configuration bits window when in a debug session and then write these settings to the Output window to paste into your code.
MPLAB IDE v8 used configuration bits set in code or a window. MPLAB IDE v8 allowed you to set Configuration bits in either code or the Configuration bits window. However, settings made in the window had to be manually entered into the code.
Hardware Tool Connection
MPLAB® X IDE debug tools are only connected during a session. MPLAB X IDE only connects debug or programmer tools to the target during a debug or programming session. Otherwise, they are not connected.
MPLAB IDE v8 debug tools were always connected. MPLAB IDE v8 connected to the debug and programmer tools as soon as the tool was selected. This configuration did not allow for multiple sessions.
To maintain this connection at all times in MPLAB X IDE, like MPLAB IDE v8, go to Tools > Options (mplab_ide > Preferences for Mac OS X), Embedded, Generic Settings tab, and check “Maintain active connection to hardware tool”.
Information Displays
MPLAB X IDE information is consolidated in one display. MPLAB X IDE has a Dashboard window that contains breakpoint resources, checksum, and memory gauge information. This window organizes this and future information in one place.
MPLAB IDE v8 information is spread over several displays. MPLAB IDE v8 had a breakpoint resources toolbar, checksum toolbar, and memory gauge window. Each feature was accessed differently.
Feature Updates
MPLAB® X IDE has many NetBeans features. MPLAB X IDE has many NetBeans editing and debug features. (See NetBeans Help for more details.) Periodically, MPLAB X IDE will update the NetBeans platform it is based upon. Then the IDE will be updated to the new NetBeans features. The MPLAB X IDE release notes will specify the NetBeans platform version that each version of MPLAB X IDE is built upon.
MPLAB IDE v8 had its own, proprietary features. MPLAB IDE v8 was a proprietary product. As such, third-party and community development was more difficult.
Menu Differences
The following table highlights the File menu changes from MPLAB® IDE v8 to MPLAB X IDE. Due to the changes in MPLAB X IDE, not all MPLAB IDE v8 menu items will map identically. Major differences are discussed under Comments.
File Menu Differences
MPLAB® IDE v8 | MPLAB® X IDE | Comments |
New | File > New File | Select associated project in file wizard |
Add New File to Project | Right click Header/Source Files > New | For an open project in the Projects tab |
Open | File > Open File | |
Close | File > Close | |
Save | File > Save | |
Save As | File > Save As | |
Save All | File > Save All | |
Open Workspace Close Workspace Save Workspace Save Workspace As | N/A | All data kept in projects, not workspaces |
Import | File > Import | Useful for HEX files |
Export | N/A | Project HEX file is located in the project folder |
File > Print File > Print to HTML File > Page Setup | ||
Recent Files | File > Open Recent Files | |
Recent Workspaces | N/A | All data kept in project directory |
Exit | File > Exit |
Edit Menu Differences
MPLAB® IDE v8 | MPLAB® X IDE | Comments |
Undo | Edit > Undo | |
Redo | Edit > Redo | |
Cut | Edit > Cut | |
Copy | Edit > Copy | |
Paste | Edit > Paste Edit > Paste Formatted | |
Delete | Edit > Delete | |
Select All | Edit > Select All Edit > Select Identifier | |
Find | Edit > Find Edit > Find Selection | |
Find Next | Edit > Find Next Edit > Find Previous | |
Find In Files | Edit > Find in Projects Edit > Replace in Projects | |
Replace | Edit > Replace | |
Go To | Navigate > Go to Line Navigate > Go to Declaration/Definition | |
Go To Locator | Navigate > Go to Symbol | |
Go Backward | Navigate > Back | |
Go Forward | Navigate > Forward | |
External DIFF | Tools > Diff | See also Tools > Options (mplab_ide > Preferences for Mac® OS X®), Miscellaneous, Diff tab |
Advanced | Source > Format Source > Shift Left/Right Source > Move Up/Down Source > Toggle Comment | |
Bookmarks | Navigate > Toggle Bookmark Navigate > Next Bookmark Navigate > Previous Bookmark | |
Properties | Tools > Options > Editor tab Tools > Options > Fonts & Colors | Use mplab_ide > Preferences instead of Tools > Options for Mac® OS X®. |
View Menu Differences
MPLAB® IDE v8 | MPLAB® X IDE | Comments |
Project | Window > Projects | |
Output | Window > Output | |
Toolbars | View > Toolbars | |
Save | File > Save | |
CPU Registers2 | Window > PIC Memory Views > CPU Registers | |
Call Stack | Window > Debugging > Call Stack | |
Disassembly Listing | Window > Debugging > Output > Disassembly Listing File | |
EEPROM | Window > PIC Memory Views > EE Data Memory | |
File Registers1 | Window > PIC Memory Views > File Registers | |
Flash Data | Window > PIC Memory Views > Data Memory | |
Hardware Stack | Window > PIC Memory Views > Hardware Stack Debug > Stack | |
LCD Pixel | Not available | |
Locals | Window > Debugging > Variables | |
Memory2 | Window > PIC Memory Views > Execution Memory | |
Program Memory1 | Window > PIC Memory Views > Program Memory | |
SFR/Peripherals2 | Window > PIC Memory Views > Peripherals | |
Special Function Registers1 | Window > PIC Memory Views > SFRs | |
Watch | Window > Debugging > Watches | See also: Debug > New Watch |
Memory Usage Gauge | Window > Dashboard | |
Trace | Window > Debugging > Trace | See also: File > Project Properties to enable trace |
Note 1: 8- and 16-bit devices Note 2: 32-bit devices |
Project Menu Differences
MPLAB® IDE v8 | MPLAB® X IDE | Comments |
Project Wizard | File > New Project | Always invoked for new project. |
New | File > New Project | Always invoked for new project. |
Open | File > Open Project File > Open Recent Project | |
Close | File > Close Project | |
Set Active Project | Run > Set Main Project | |
Quickbuild | Not supported | A project is required for all development. |
Package in .zip | Right click on project in Projects window, select Package | |
Clean | Right click on project in Projects window, select Clean or Clean and Build | |
Locate Headers | Right click on project in Projects window, select Locate Headers | |
Export Makefile | N/A | See the topic Working Outside the IDE in the MPLAB X IDE Help. |
Build All | Run > Run Project Debug > Debug Project | Programmer build/run Debug build/run |
Make | ||
Build Configuration | File > Project Properties, click Manage Configurations | There used to be only two configurations: Release and Debug. Now you determine how many you need. |
Build Options | File > Project Properties, click Toolchain Tool | Language tool set up |
Save Project | File > Save File > Save All | |
Save Project As | File > Save As | |
Add Files to Project | Right click on project folder in Projects window, select Add Existing Item | |
Add New File to Project | Right click on project folder in Projects window, select New | |
Remove File from Project | Right click on project file in Projects window, select Remove From Project | |
Select Language Toolsuite | File > New Project File > Project Properties | To select To change |
Set Language Tool Locations | Tools > Options, Embedded, Build Tools | Use mplab_ide > Preferences instead of Tools > Options for Mac® OS X®. |
Version Control | Team menu items | Other version control may be available as a plugin. |
Debugger Menu Differences
MPLAB® IDE v8 | MPLAB X IDE | Comments |
Select Tool | File > New Project File > Project Properties | To select To change |
Clear Memory | Not available. Use Fill Memory. | Window > PIC Memory Views >Memory Window, right click in window, then select 'Fill Memory' |
Run | Run > Run Main Project Debug > Debug Main Project Debug > Continue | Programmer Run Debug Run Run from Halt |
Animate | Not supported | |
Halt | Debug > Pause | |
Step Into | Debug > Step Into | |
Step Over | Debug > Step Over | |
Step Out | Debug > Step Out | |
Reset | Debug > Reset | |
Breakpoints | Debug > New Breakpoint Debug > Toggle Breakpoint | Set a breakpoint in code by clicking in the gutter next to a line of code. |
Settings | File > Project Properties | |
Stopwatch | Window > Debugging > Stopwatch |
Programmer Menu Differences
MPLAB® IDE v8 | MPLAB® X IDE | Comments |
Select Programmer | File > New Project File > Project Properties | To select To change |
Enable Programmer | Not available. Automatically enabled on programming | Unless Tools > Options, Embedded, Generic Settings, “Maintain active connection to hardware tool” checked |
Disable Programmer | Not available. Automatically disabled after programming | |
Program | Make and Program Device | On Run toolbar |
Verify | Not available | See MPLAB® IPE |
Read | Read Device Memory | On Run toolbar |
Blank Check All | Not available | See MPLAB IPE |
Blank Check OTP | Not available | See MPLAB IPE |
Erase Flash Device | Available on custom toolbar | View > Toolbars > Custom See also MPLAB IPE |
Reset Program Statistics | Not available | See MPLAB IPE |
Download OS | File > Project Properties, debug tool category, Firmware option | The IDE will automatically choose the most up-to-date firmware to download |
Tools Menu Differences
MPLAB® IDE v8 | MPLAB® X IDE | Comments |
Data Monitor and Control Interface (DMCI) and other plugins | Tools > Plugins Tools > Embedded | To install To use |
MPLAB® Macros | Edit > Start Macro Recording Edit > Stop Macro Recording | After recording, you can enter a macro name and shortcut. |
RTOS Viewer | Tools > Plugins Tools > Embedded | To install To use |
Configure Menu Differences
MPLAB® IDE v8 | MPLAB® X IDE | Comments |
Select Device | File > New Project File > Project Properties | To select To change |
Configuration Bits | Window > PIC Memory Views > Configuration Bits | |
External Memory | Window > PIC Memory Views > Program/Execution Memory | External memory is displayed as part of program or execution memory |
ID Memory | Window > PIC Memory Views > User ID Memory | |
Settings | Tools > Options | Use mplab_ide > Preferences for Mac® OS X® |
Window Menu Differences
MPLAB® IDE v8 | MPLAB® X IDE | Comments |
---|---|---|
Close All | Window > Close All Documents | |
Cascade | Not supported | |
Tile Horizontally | Drag and drop window | |
Tile Vertically | Drag and drop window | |
Arrange Icons | View > Toolbars > Customize | |
Window Sets | Window > Document Groups | |
Create Window Set | Window > Document Groups > New Document Group | |
Destroy Window Set | Window > Document Groups > Manage | |
Recent Windows | Not supported |
Help Menu Differences
MPLAB® IDE v8 | MPLAB® X IDE | Comments |
Topics | Help > Contents Help > Tool Contents Help > Online Docs and Support | Add PDFs under Important Files in the Projects Window. |
Release Notes | Start Page, Learn & Discover, Users Guide & Release Notes | |
Driver Installation | N/A | Drivers installed with MPLAB X IDE See Hardware Tool webpage for uninstall |
Check for Updates | N/A | Updates automatically enabled |
Web Links | How do I? | Developer Help |
About MPLAB® IDE | Help > About |
Tool Support Differences
Development Tool | In MPLAB® X IDE? |
MPLAB® PICkit™ 4 | ✔ |
PICkit 3 | ✔ |
PICkit 2 | ✔ |
PICkit 1 | ❌ |
MPLAB® ICD 4 | ✔ |
MPLAB ICD 3 | ✔ |
MPLAB ICD 2 | ❌ |
MPLAB® REAL ICE™ In-Circuit Emulator | ✔ |
MPLAB® ICE 2000 | ❌ |
MPLAB ICE 4000 | ❌ |
MPLAB® PM3 | ✔ |
PROMATE II | ❌ |
PICSTART® Plus | ❌ |
MPLAB VDI | ❌ |
Plug-in Support Differences
Plug-Ins1 | In MPLAB® X IDE? |
DMCI | ✔ |
dsPIC® Filter Design2 | ✔ |
dsPICworks Data Analysis2 | ✔ |
Graphical Display Designer | ✔ |
KeeLoq® Plugin | ✔ |
Memory Starter Kit | ✔ |
PC-Lint | ✔ |
RTOS Viewer | ✔ |
AN851 Bootloader | ❌ |
AN901 BLDC Tuning Interface | ❌ |
AN908 ACIM Tuning Interface | ❌ |
dsPIC30F SMPS Buck Converter | ❌ |
dsPIC33F SMPS Buck/Boost Converter | ❌ |
MATLAB®/Simulink® | ❌ |
Segmented Display Designer | ❌ |
Note 1: To see available plug-ins, select Tools > Plugins, “Available Plugins” tab. Note 2: For Windows® operating systems only. |
Other Migration Considerations
The following are issues with MPLAB® X IDE and MPLAB IDE v8 projects. If you do not see your issue here, consult the documentation for MPLAB X IDE.
Importing an MPLAB® IDE v8 Project - Settings
Settings that were saved in a workspace in MPLAB® IDE v8 (such as tool settings) will not be transferred to the new MPLAB X IDE project. Refer to the MPLAB IDE v8 help for what is stored in a workspace (MPLAB IDE Reference > Operational Reference > Saved Information.)
Importing an MPLAB® IDE v8 Project - Modified Linker Scripts
If you have modified your MPLAB® IDE v8 project linker script so that it includes an object file, the linker will be unable to find the file when imported into MPLAB X IDE because the build paths for MPLAB IDE v8 and MPLAB X IDE are different.
So you may see an error like:
<install path>ld.exe: cannot find the file.o
since in MPLAB IDE v8, all build-related files are in one directory, whereas in MPLAB® X IDE build files are in different subdirectories.
You can edit your linker script to work with MPLAB X IDE by using wild cards. For example, change:
.init :
{
KEEP (crti.o(.init))
:
} >kseg0_program_mem
to:
.init :
{
KEEP (*crti.o(.init))
:
} >kseg0_program_mem
Alternatively, you can use an address attribute that allows you to place functions in C code.