{"id":201,"date":"2013-01-15T13:41:48","date_gmt":"2013-01-15T13:41:48","guid":{"rendered":"http:\/\/www.electronic-products-development.com\/?p=201"},"modified":"2023-09-14T12:22:35","modified_gmt":"2023-09-14T11:22:35","slug":"creating-a-new-project","status":"publish","type":"post","link":"https:\/\/ibex.tech\/embedded\/microchip\/mplab-x\/projects\/creating-a-new-project","title":{"rendered":".Create New Project"},"content":{"rendered":"\n<h4 class=\"wp-block-heading\">XC8 Projects<\/h4>\n\n\n\n<p>Jump to our <a href=\"\/embedded\/microchip\/pic18\/xc8-compiler\/xc8-general\/new-xc8-project\">page here<\/a>.<\/p>\n\n\n\n<h4 class=\"wp-block-heading\">XC32 Projects<\/h4>\n\n\n\n<p>Jump to our <a href=\"\/embedded\/microchip\/pic32\/xc32\/xc32-general\/new-xc32-project\">page here<\/a>.<\/p>\n\n\n\n<h4 class=\"wp-block-heading\">Create MPLAB X Project<\/h4>\n\n\n\n<p>Run MPLAB X IDE<\/p>\n\n\n\n<p>Menu &gt; File &gt; New Project<\/p>\n\n\n\n<p>Categories: Microchip Embedded<\/p>\n\n\n\n<p>Projects: Standalone Project<\/p>\n\n\n\n<p>Select the device<\/p>\n\n\n\n<p>Select the debugging tool<\/p>\n\n\n\n<p>Select the Compiler to use<\/p>\n\n\n\n<p>Set project name and &#8220;Set as main project&#8221;<\/p>\n\n\n\n<h4 class=\"wp-block-heading\">Add Source Code Files<\/h4>\n\n\n\n<p>Add your initial project files to the projects &#8220;ProjectName.X&#8221; directory.<\/p>\n\n\n\n<p>Right click the project &gt; Add Existing Item &gt; Select the files<\/p>\n\n\n\n<p>Drag them into the Header Files and Source File folders.<\/p>\n\n\n\n<h4 class=\"wp-block-heading\">Setting Up Debug \/ Release Mode<\/h4>\n\n\n\n<p>Old MPLAB allowed you to use this macro in code:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>__DEBUG<\/code><\/pre>\n\n\n\n<p>to detect if a debug or release mode was selected. It was just built in, but its not in MPLAB X.<\/p>\n\n\n\n<p>So add this to a global header file when debugging:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>\n#ifndef __DEBUG\n\t#define __DEBUG\t\t\t\t\t\t\/\/&lt;&lt;&lt;&lt;&lt; COMMENT OUT FOR RELEASE\n#endif\n<\/code><\/pre>\n\n\n\n<h4 class=\"wp-block-heading\">Compiler Settings<\/h4>\n\n\n\n<p><em><strong>IMPORTANT &#8211; ENSURE YOU CHECK THE BASIC COMPILER SETUP OPTIONS TO HELP ENSURE YOU DON&#8217;T GET CAUGHT UP IN STUPID BUGS<\/strong><\/em><\/p>\n","protected":false},"excerpt":{"rendered":"<p>XC8 Projects Jump to our page here. XC32 Projects Jump to our page here. Create MPLAB X Project Run MPLAB X IDE Menu &gt; File &gt; New Project Categories: Microchip Embedded Projects: Standalone Project Select the device Select the debugging tool Select the Compiler to use Set project name and &#8220;Set as main project&#8221; Add [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[65],"tags":[],"class_list":["post-201","post","type-post","status-publish","format-standard","hentry","category-projects"],"_links":{"self":[{"href":"https:\/\/ibex.tech\/embedded\/wp-json\/wp\/v2\/posts\/201","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/ibex.tech\/embedded\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/ibex.tech\/embedded\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/ibex.tech\/embedded\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/ibex.tech\/embedded\/wp-json\/wp\/v2\/comments?post=201"}],"version-history":[{"count":25,"href":"https:\/\/ibex.tech\/embedded\/wp-json\/wp\/v2\/posts\/201\/revisions"}],"predecessor-version":[{"id":1359,"href":"https:\/\/ibex.tech\/embedded\/wp-json\/wp\/v2\/posts\/201\/revisions\/1359"}],"wp:attachment":[{"href":"https:\/\/ibex.tech\/embedded\/wp-json\/wp\/v2\/media?parent=201"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/ibex.tech\/embedded\/wp-json\/wp\/v2\/categories?post=201"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/ibex.tech\/embedded\/wp-json\/wp\/v2\/tags?post=201"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}