1- This README provides a quick overview of QP-nano for Arduino.
1+ This README provides a quick overview of QP for Arduino.
22Please refer to the companion webiste to this project at:
33
44https://www.state-machine.com/arduino
55
66
77Software Installation on Windows
88================================
9- The QP-nano adaptation for Arduino is distributed in a single ZIP
10- archive qpn -<ver >_ arduino-1.8.x.zip, where <ver > stands for version of
11- the QP-nano framework .
9+ The QP adaptation for Arduino is distributed in a single ZIP
10+ archive qp -<ver >_ arduino-1.8.x.zip, where <ver > stands for version of
11+ the QP frameworks .
1212
13- You need to unzip the qpn -<ver >_ arduino-1.8.x.zip archive into your
13+ You need to unzip the qp -<ver >_ arduino-1.8.x.zip archive into your
1414Arduino-Sketchbook folder. To find out where your Sketchbook folder is,
1515or to configure a different location for your Sketchbook folder, you
1616need to open the Arduino IDE and select File | Preferences menu. The
1717sketchbook location will be shown at the top of the Preferences dialog
1818box. Once you identify the Sketchbook folder, you simply unzip the whole
1919archive to your Sketchbook.
20-
21-
22- Software Installation on MacOS
23- ==============================
24- The Mac funtionality has been tested, but other users will likely find
25- issues. Please submit issues at https://sourceforge.net/p/qpc/bugs/ and
26- submit questions and suggestions at
27- https://sourceforge.net/p/qpc/discussion/668726/
28-
29- Install Dependencies
30- --------------------
31- 1 . Install the AVR-GCC tooltrain for Mac OS X. Following are the commands
32- to install using Homebrew (must have Homebrew installed):
33-
34- > ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install )"
35- > brew tap osx-cross/avr
36- > brew install avr-libc
37- > brew install avrdude --with-usb
38-
39- 2 . Install Arduino for Mac OS X by placing the Arduino application in the
40- Applications folder. Open the application at least one time to overcome
41- security warnings.
42-
43- 3 . Install Install QP-nano for Arduino into your Documents/Arduino folder
44- (documentation refers to this as the Arduino Sketchbook folder).
45-
46- 4 . Install QM.
47-
48- Instructions for Configuring External Tools for a Model
49-
50- 1 . Ensure the model is not open in QM.
51-
52- 2 . Copy the Blinky model's settings
53- (libraries/qpn_avr/examples/blinky/.blinky.macos) from your Arduino
54- Sketchbook folder to the model's folder.
55-
56- 3 . Rename the settings file to your model's name (i.e., .mymodel).
57-
58- 4 . Open QM and edit the settings from External Tools.
59-
60- Once you have a working .model file, copy it to other models and use it as
61- a starting point.
62-
63- Known Issues
64- ------------
65- 1 . The serialterm External Tool is working by opening a Terminal window.
66- An additional Terminal window also appears and can be safely closed. When
67- the Terminal window displaying the Arduino's output is closed, the port is
68- busy and can no longer be accessed. Work-around is to unplug and
69- re-connect the Arduino from the Mac's USB port.
70-
71-
72- Building the Examples in the QM Modeling Tool
73- =============================================
74-
20+
21+
22+ Provided Libraries
23+ ==================
24+ The archive qp-<ver >_ arduino-1.8.x.zip contains two external libraries
25+ for Arduino:
26+
27+ qpcpp_sam -- QP/C++ framework for SAM-based Arduinos (ARM Cortex-M)
28+ qpn_avr -- QP-nano framework for AVR based Arduinos
29+
30+
31+ Working with the Examples
32+ =========================
33+ Each QP library contains the examples sub-directory, which contans the
34+ QM model file and the generated code. The intended way of working with
35+ the examples is to use the QM modeling tool to modify the state diagrams
36+ and the code, and to use the Arduino IDE only to build and upload
37+ the code to the Arduino board(s).
38+
7539****
76- NOTE: To start working with the freeware QM modeling tool, you need to
77- download the tool from https://sourceforge.net/projects/qpc/files/QM .
40+ NOTE: The preferences in the Arduino IDE should be set up to
41+ "Use external editor" so that the IDE will update the code each time
42+ it is re-generated by the QM modeling tool.
7843****
79-
80- Each QP-nano example for Arduino (in the examples_avr folder) contains
81- a QM model, which is a file with the extension .qm., such as
82- <Sketchbook >\examples_avr\blinky\blinky.qm. These models and the QM
83- modeling tool take Arduino programming to the next level. Instead of
84- coding the state machines by hand, you draw them with the free QM
85- modeling tool, attach simple action code to states and transitions, and
86- you generate the complete Arduino sketch automatically-—literally by a
87- press of a button.
44+
45+ When you unzip the archive into your Sketchbook directory, the examples
46+ provided in each QP library shows up in the Arduino IDE under the menu:
47+
48+ File|Examples|Examples from Custom Libraries
8849
8950
9051Licensing
9152=========
92- The QP-nano framework for Arduino is licensed under the modified GPLv3
93- license (see file GPLv3.txt) with the QP-Arduino Exception (see file
94- QP-Arduino_GPL_Exception.txt). Specifically, the Exception removes the
95- requirement to expose your propriatory source code as long as you deploy
96- it on an Arduino-Certified board.
53+ The QP real-time embedded frameworks for Arduino are licensed under the
54+ modified GPLv3 license with the QP-Arduino Exception (see file
55+ QP-Arduino_GPL_Exception.txt in the root of the archive). Specifically,
56+ the Exception removes the requirement to expose your propriatory source
57+ code as long as you deploy it on an Arduino-Certified board.
9758
9859The QM graphical modeling tool is freeware. The QM tool is provided
9960under the terms of a simple End-User License Agreement (EULA).
@@ -105,11 +66,6 @@ Please refer to the companion webiste to this project at:
10566
10667https://www.state-machine.com/arduino
10768
108- Specifically, the Application Note: "Event-Driven Arduino Programming
109- with QP and QM" is available from:
110-
111- https://www.state-machine.com/doc/AN_Event-Driven_Arduino_QP-nano.pdf
112-
11369
11470Support Questions
11571=================
0 commit comments