Initial commit for stepper controller
[radiotelescope.git] / stepper_controller / arduino / stepper / qm_code / stepper.h
1 /*****************************************************************************
2 * Model: C:/Documents and Settings/Harry McNally/My Documents/project/arduino/stepper/arduino/stepper/stepper.qm
3 * File:  ./qm_code/stepper.h
4 *
5 * This file has been generated automatically by QP Modeler (QM).
6 * DO NOT EDIT THIS FILE MANUALLY.
7 *
8 * Please visit www.state-machine.com/qm for more information.
9 *****************************************************************************/
10 //
11 // Product: Radiotelescope - Stepper Motor Controller
12 // Version: 0.1
13 // Date:    25 November 2010
14 //
15 //                      +-----------------------+
16 //                      |   d e c i s i o n s   |
17 //                      +-----------------------|
18 //                      | a n d   d e s i g n s |
19 //                      +-----------------------+
20 //
21 // Copyright (C) 2009 Decisions and Designs Pty Ltd. All rights reserved.
22 //
23 // This software may be distributed and modified under the terms of the GNU
24 // General Public License version 2 (GPL) as published by the Free Software
25 // Foundation and appearing in the file GPL.TXT included in the packaging of
26 // this file. Please note that GPL Section 2[b] requires that all works based
27 // on this software must also be made publicly available under the terms of
28 // the GPL ("Copyleft").
29 //
30 // Contact information:
31 // Decisions and Designs Web site: http://www.decisions-and-designs.com.au
32 // e-mail:                         [email protected]
33 //
34
35 #ifndef stepper_h
36 #define stepper_h
37
38 #include "bsp.h" /* for board specific STEP_PERIOD macro */
39
40 /* Stepping definitions */
41 #define SLOW_STEP_PERIOD STEP_PERIOD(500000L)
42 #define MIN_SETUP_TIME STEP_PERIOD(1000L) 
43 #define MID_SET_TIME   0x8000   
44 #define MAX_SETUP_TIME (0xffff - PULSE_TIME)
45 #define PULSE_TIME     STEP_PERIOD(100L)
46
47 #define STEPPER_SIGS()          \
48     NEXT_STEP_TIME_SIG,         \
49     SET_ACCELERATION_SIG,       \
50     SET_BASE_SPEED_SIG,         \
51     SET_SLEW_SPEED_SIG,         \
52     SET_TOTAL_STEPS_SIG,        \
53     SET_DIRECTION_UP_CW_SIG,    \
54     SET_DIRECTION_DOWN_CCW_SIG, \
55     START_LINEAR_SLEW_SIG
56
57 #endif                                                         /* stepper_h */

UCC git Repository :: git.ucc.asn.au