17.01.2015 Views

QDK PIC24/dsPIC-XC16 - Quantum Leaps

QDK PIC24/dsPIC-XC16 - Quantum Leaps

QDK PIC24/dsPIC-XC16 - Quantum Leaps

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

<strong>QDK</strong><br />

<strong>PIC24</strong>/<strong>dsPIC</strong>-<strong>XC16</strong><br />

www.state-machine.com/pic<br />

2.2 Building and Running the Examples<br />

The examples included in this <strong>QDK</strong> are based on the standard DPP application implemented with active<br />

objects (see <strong>Quantum</strong> <strong>Leaps</strong> Application Note: “Dining Philosophers Problem Application” [QL AN-DPP<br />

08] included in this <strong>QDK</strong>). The example directory contains the MPLABX workspaces and project file that<br />

you can load into the MPLABX IDE, as shown in Figure 5.<br />

Figure 5: The MPLABX IDE with the DPP example<br />

Active build<br />

configuration<br />

Build<br />

tool<br />

Debug<br />

tool<br />

2.2.1 Building the Example Projects in the MPLABX IDE<br />

1. Connect the USB cable between the Microstick II board and the PC.<br />

2. Launch the MPLABX IDE and open the project (menu File | Open Project...) located in \-<br />

examples\pic24_dspic\vanilla\xc16\dpp-qk-microstick2-pic24.X\). Figure 5 shows the<br />

screen shot of the MPLABX IDE after opening the project.<br />

3. Select the build configuration from the combo box next to the hammer tool (Figure 5)<br />

4. Build the project by clicking on the hammer tool.<br />

2.2.2 Programming the Example to Run under the MPLAB Debugger<br />

After a successful build, you can load the program to the target device by pressing the Debug button,<br />

which is shown in Figure 5.<br />

Copyright © <strong>Quantum</strong> <strong>Leaps</strong>, LLC. All Rights Reserved.<br />

9 of 35

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!