Professional Documents
Culture Documents
DS50002184A
MPLAB
DSCs, KEELOQ
code hopping
devices, Serial EEPROMs, microperipherals, nonvolatile memory and
analog products. In addition, Microchips quality system for the design
and manufacture of development systems is ISO 9001:2000 certified.
QUALITY MANAGEMENT SYSTEM
CERTIFIED BY DNV
== ISO/TS 16949 ==
Trademarks
The Microchip name and logo, the Microchip logo, dsPIC,
FlashFlex, KEELOQ, KEELOQ logo, MPLAB, PIC, PICmicro,
PICSTART, PIC
32
logo, rfPIC, SST, SST Logo, SuperFlash
and UNI/O are registered trademarks of Microchip Technology
Incorporated in the U.S.A. and other countries.
FilterLab, Hampshire, HI-TECH C, Linear Active Thermistor,
MTP, SEEVAL and The Embedded Control Solutions
Company are registered trademarks of Microchip Technology
Incorporated in the U.S.A.
Silicon Storage Technology is a registered trademark of
Microchip Technology Inc. in other countries.
Analog-for-the-Digital Age, Application Maestro, BodyCom,
chipKIT, chipKIT logo, CodeGuard, dsPICDEM,
dsPICDEM.net, dsPICworks, dsSPEAK, ECAN,
ECONOMONITOR, FanSense, HI-TIDE, In-Circuit Serial
Programming, ICSP, Mindi, MiWi, MPASM, MPF, MPLAB
Certified logo, MPLIB, MPLINK, mTouch, Omniscient Code
Generation, PICC, PICC-18, PICDEM, PICDEM.net, PICkit,
PICtail, REAL ICE, rfLAB, Select Mode, SQI, Serial Quad I/O,
Total Endurance, TSHARC, UniWinDriver, WiperLock, ZENA
and Z-Scale are trademarks of Microchip Technology
Incorporated in the U.S.A. and other countries.
SQTP is a service mark of Microchip Technology Incorporated
in the U.S.A.
GestIC and ULPP are registered trademarks of Microchip
Technology Germany II GmbH & Co. KG, a subsidiary of
Microchip Technology Inc., in other countries.
All other trademarks mentioned herein are property of their
respective companies.
2013, Microchip Technology Incorporated, Printed in the
U.S.A., All Rights Reserved.
Printed on recycled paper.
ISBN: 978-1-62076-984-3
2013 Microchip Technology Inc. DS50002184A-page 3
MPLAB
Integrated Development Environment for development systems tools. This list is
focused on the MPLAB IDE, MPLAB SIM simulator, MPLAB IDE Project Manager
and general editing and debugging features.
Programmers The latest information on Microchip programmers. These include
the MPLAB PM3 and PRO MATE
Plus and PICkit 1 development programmers.
CUSTOMER SUPPORT
Users of Microchip products can receive assistance through several channels:
Distributor or Representative
Local Sales Office
Field Application Engineer (FAE)
Technical Support
Customers should contact their distributor, representative or field application engineer
(FAE) for support. Local sales offices are also available to help customers. A listing of
sales offices and locations is included in the back of this document.
Technical support is available through the web site at: http://support.microchip.com
DOCUMENT REVISION HISTORY
Revision A (July 2013)
Initial release of this document.
MPLAB
C Compiler for
PIC18 MCUs (formerly, and referred to here as, MPLAB C18) and the MPLAB XC8 C
Compiler, and how you might migrate C source code and compiler options that were
tailored to MPLAB C18 over to MPLAB XC8.
This guide will be useful for those porting projects to the MPLAB XC8 compiler, as well
as those programmers familiar with MPLAB C18 syntax and operation, who wish to
come up to speed quickly with MPLAB XC8 for new projects.
This chapter introduces the following overviews.
Using C18 Compatibility Mode
Migrating Projects to MPLAB XC8
Before the release of XC8, MPLAB C18 had been the only PIC18 C compiler offered
by Microchip. It is ANSI compliant and includes separate assembler and linker applica-
tions. Peripheral libraries are supplied to speed development. The MPLAB C18 com-
piler is being phased out, and no significant new development is planned for future
releases.
The MPLAB XC8 C compiler has replaced the MPLAB C18. This replacement compiler
is also ANSI compliant, includes a separate assembler and linker, and the same
peripheral library is supplied.
For existing projects designed for MPLAB C18 and future code development, you have
several options:
Continue to use the deprecated MPLAB C18 compiler.
Compile in C18 compatibility mode with the MPLAB XC8 compiler.
1
Migrate project and code to native MPLAB XC8 settings and syntax.
As MPLAB C18 will not be further developed, it is recommended that you only continue
to use this compiler for complete projects that are not being actively maintained. You
might also use this compiler if you need to exactly replicate a previous build output.
The MPLAB XC8 compatibility mode will be useful if you are unable to use the MPLAB
C18 compiler but cannot justify the time spent to migrate code over to the native
MPLAB XC8 syntax.
Microchip recommends that, if possible, code be migrated to MPLAB XC8 syntax. This
will guarantee support for projects into the future.
1.See the note box in Section 1.2 Using C18 Compatibility Mode concerning the availability of this
mode.
MPLAB