-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix example project doxygen hierarchy; Copy and modify a demo from Pa…
…rallax to demonstrate the helpfulness of PropWare
- Loading branch information
David Zemon
committed
Feb 1, 2014
1 parent
f2d247c
commit ce3d8bb
Showing
12 changed files
with
183 additions
and
62 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
/** | ||
@defgroup _propware_examples Examples | ||
@brief Example projects to demonstrate the capabilities and the simplicity of developing projects using PropWare | ||
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,25 +1,61 @@ | ||
/** | ||
* @file L3G_Demo.h | ||
* | ||
* @author David Zemon | ||
*/ | ||
/** | ||
* @brief Demonstration using various functions of the L3G gyroscope | ||
* | ||
* @project L3G_Demo | ||
* | ||
* @author David Zemon | ||
* | ||
* @copyright | ||
* The MIT License (MIT)<br> | ||
* <br>Copyright (c) 2013 David Zemon<br> | ||
* <br>Permission is hereby granted, free of charge, to any person obtaining a | ||
* copy of this software and associated documentation files (the "Software"), to | ||
* deal in the Software without restriction, including without limitation the | ||
* rights to use, copy, modify, merge, publish, distribute, sublicense, and/or | ||
* sell copies of the Software, and to permit persons to whom the Software is | ||
* furnished to do so, subject to the following conditions:<br> | ||
* <br>The above copyright notice and this permission notice shall be included | ||
* in all copies or substantial portions of the Software.<br> | ||
* <br>THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS | ||
* OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | ||
* SOFTWARE. | ||
*/ | ||
|
||
#ifndef L3G_DEMO_H_ | ||
#define L3G_DEMO_H_ | ||
|
||
/** | ||
* @defgroup _propware_example_l3g L3G Gyroscope Demo | ||
* @ingroup _propware_examples | ||
* @{ | ||
*/ | ||
|
||
#include <propeller.h> | ||
#include <PropWare.h> | ||
#include <l3g.h> | ||
|
||
#define MOSI BIT_0 | ||
#define MISO BIT_1 | ||
#define SCLK BIT_2 | ||
#define CS BIT_4 | ||
#define FREQ 10000 | ||
/** Pin number for MOSI (master out - slave in) */ | ||
#define MOSI BIT_0 | ||
/** Pin number for the clock signal */ | ||
#define SCLK BIT_1 | ||
/** Pin number for MISO (master in - slave out) */ | ||
#define MISO BIT_2 | ||
/** Pin number for chip select */ | ||
#define CS BIT_4 | ||
/** Frequency (in Hertz) to run the SPI protocol */ | ||
#define FREQ 10000 | ||
|
||
#define DEBUG_LEDS BYTE_2 | ||
|
||
void error (const int8_t err); | ||
|
||
/**@}*/ | ||
|
||
#endif /* L3G_DEMO_H_ */ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
# @file Makefile | ||
# | ||
# @author David Zemon | ||
# @project PropWare_Demo | ||
|
||
PRJ = PropWare_Demo | ||
|
||
NAME = $(PRJ) | ||
OBJS = $(PRJ).o | ||
BOARD = QUICKSTART | ||
MODEL = lmm | ||
CFLAGS = -Os | ||
|
||
# Insert your own path here - it should be the same directory that contains "common.mk" | ||
ifndef PROPWARE_PATH | ||
PROPWARE_PATH = ../../.. | ||
endif | ||
|
||
# Optionally, specify where your compiler is installed | ||
ifndef PROPGCC_PREFIX | ||
# Default = /opt/parallax | ||
PROPGCC_PREFIX = /path/to/compiler/directory | ||
endif | ||
|
||
all: $(NAME).elf | ||
|
||
include $(PROPWARE_PATH)/common.mk |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.