29.01.2015 Views

AN QP and ARM7/9 - Quantum Leaps

AN QP and ARM7/9 - Quantum Leaps

AN QP and ARM7/9 - 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.

1 Introduction<br />

This Application Note describes how to use the <strong>QP</strong>/C <strong>and</strong> <strong>QP</strong>/C++ state machine frameworks version<br />

4 or higher with the <strong>ARM7</strong> or ARM9 processors. This document describes the following two main<br />

implementation options:<br />

1. The cooperative “Vanilla” kernel available in the QF real-time framework; <strong>and</strong><br />

2. The preemptive run-to-completion QK kernel.<br />

To focus the discussion, this Application Note uses the IAR Embedded Workbench ® for ARM (EWARM<br />

version 5.30 KickStart edition, which is available as a free download from the IAR website www.iar.com).<br />

However, most of the code described here is generic ARM/THUMB <strong>and</strong> should be easily adapted to any<br />

ARM development toolset, such as the RealView ® , Keil, Green Hills, or GNU.<br />

This Application Note does not contain any executable examples, which are provided in the <strong>QP</strong><br />

Development Kits (QDKs) for specific <strong>ARM7</strong>/ARM9 boards. The QDKs for ARM are available as<br />

separate downloads from www.state-machine/arm.<br />

NOTE: Even though this Application Note is based on the IAR toolset for ARM, the provided explanations are<br />

applicable to most toolsets supporting <strong>ARM7</strong>/ARM9 processors.<br />

NOTE: This Application Note pertains both to C <strong>and</strong> C++ versions of the <strong>QP</strong> state machine frameworks. Most of<br />

the code listings in this document refer to the <strong>QP</strong>/C version. Occasionally the C code is followed by the equivalent<br />

C++ implementation to show the C++ differences whenever such differences become important.<br />

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

1 of 31

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

Saved successfully!

Ooh no, something went wrong!