Mikroelektronika MIKROE-724 データシート
mikroBasic PRO for dsPIC30/33 and PIC24
MikroElektronika
711
Using Microchip MPLAB® IDE with mikroElektronika compilers
This new feature will boost your productivity by enabling you to import your code in a non-mikroElektronika enironment
- Microchip’s MPLAB®.
With the introduction of COFF File in mikroElektronika compiler, it is possible to debug and analyze your code through
a software or hardware simulator.
Debugging Your Code
If your program has been built correctly, the compiler should generate a
.hex
file and a
.cof
file. The
cof
file contains
all the information necessary for high-level debugging in MPLAB®, and it should be loaded by selecting the
File ›
Import... menu in the MPLAB®.
Once you have done this, you have two choices: either to use MPLAB® ICD 2 Debugger, if you have the appropriate
hardware, or MPLAB® Simulator.
Trademarks:
The Microchip name and logo, the Microchip logo, Accuron, dsPIC, KEELOQ, KEELOQ logo, microID, MPLAB,
PIC, PICmicro, PICSTART, PRO MATE, rfPIC and SmartShunt are registered trademarks of Microchip Technology
Incorporated in the U.S.A. and other countries.
Related topics: COFF File, Using MPLAB® ICD 2 Debugger, Using MPLAB® Simulator
Using MPLAB® ICD 2 Debugger
Important:
- It is assumed that MPLAB® and USB drivers for MPLAB® ICD 2 Debugger are previously installed.
- Procedure described below is also relevant for MPLAB® ICD 3 Debugger.
- Be sure to import compiled
.hex
file prior to importing
.cof
file, because it contains configuration bit settings which
are essential for the proper functioning of the user code.
To successfully use MPLAB® ICD 2 Debugger with generated
.cof
file, follow the steps below:
1. First of all, start mikroBasic PRO for dsPIC30/33 and PIC24 and open the desired project. In this example, UART
project for EasydsPIC4A board and dsPIC30F4013 will be opened.
2. Open
Tools › Options › Output settings, and check the “Generate COFF file” option, and click the OK button.
3. After that, compile the project by pressing Ctrl + F9.
4. Connect USB cable and turn on power supply on EasydsPIC4A.
5. Program the MCU by pressing F11.
6. Connect external power supply, USB cable from PC and modular interface cable to the MPLAB® ICD 2
Debugger’s appropiate sockets, like on the picture below: