3.22EjemploDRM007 Co..
3.22EjemploDRM007 Co..
3.22EjemploDRM007 Co..
Create successful ePaper yourself
Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.
Source <strong>Co</strong>de<br />
Include Files<br />
#define DebounceDelay()<br />
WaitMs(30)<br />
#define WaitUntilUpButtonIsReleased() while((PORTB & OPTIONS_BUTTON) == 0x00)<br />
// General Boolean defines<br />
#define TRUE 1<br />
#define FALSE 0<br />
// Buttons Definition<br />
#define OPTIONS_BUTTON 0x08<br />
#define ENTER_BUTTON 0x04<br />
// MCU <strong>Co</strong>nfiguration<br />
#define EDGE_ALIGNED<br />
#define CENTER_ALIGNED<br />
#define INDEPENDENT_PWMS<br />
#define COMPLEMENTARY_MODE<br />
#define COP_DISABLE<br />
#define TOPNEG<br />
#define FAULT_1_AUTOMATIC<br />
#define FAULT_1_MANUAL<br />
#define FAULT_1_INT<br />
0x80<br />
0x00<br />
0x10<br />
0x00<br />
0x01<br />
0x20<br />
0x01<br />
0x00<br />
0x02<br />
/*****************************************************************************\<br />
* End main.h *<br />
******************************************************************************/<br />
;<br />
7.2.4 TIMER.H<br />
;<br />
/*****************************************************************************\<br />
* <strong>Co</strong>pyright (c) 2002, Motorola Inc.<br />
*<br />
* Motorola <strong>Co</strong>nfidential Proprietary<br />
*<br />
* ----------------------------------------------------------------------------*<br />
* File name : timer.h *<br />
* Project name: Brushless DC Motor Drive with the MR8 Microcontroller<br />
*<br />
* ----------------------------------------------------------------------------*<br />
* Author : Jorge Zambada *<br />
* Email : Jorge.Zambada@motorola.com *<br />
* Department : Mexico Applications Lab - SPS *<br />
* *<br />
* Description : File subroutines and State Flags values are defined in this<br />
*<br />
* document. Also Macro definitions are placed here. *<br />
\*****************************************************************************/<br />
BLDC Motor <strong>Co</strong>ntrol Board for Industrial and Appliance Applications<br />
DRM007<br />
MOTOROLA Source <strong>Co</strong>de 111