⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 f2407cap.h

📁 TI的digital motor control lib的源代码。了解TI的编程规范
💻 H
字号:
/* ==================================================================================
File name:        F2407CAP.H                     
                    
Originator:	Digital Control Systems Group
			Texas Instruments
Description:  
This file defines handy constants for register initializations
contains prototypes for the functions in F2407_CAP?.(C/ASM),
and has definitions of structs etc.
=====================================================================================
 History:
-------------------------------------------------------------------------------------
 9-15-2000	Release	Rev 1.0                                                  
---------------------------------------------------------------------------------- */

/* F2407 Register TxCON                                                        */
/*----------------------------------------------------------------------------*/
#ifndef __F2407CAP_H__
#define __F2407CAP_H__


#include "..\include\F2407BMSK.H"

/*-----------------------------------------------------------------------------
    Initialization states for T2CON,T4CON and CAPCONA,CAPCONB 
------------------------------------------------------------------------------*/
#define CAP_INIT_STATE    0xA050
#define TIMER_INIT_STATE (FREE_RUN_FLAG+TIMER_CONT_UP+TIMER_CLK_PRESCALE_X_128+ \
                          TIMER_ENABLE_BY_OWN+TIMER_ENABLE+                   \
                          TIMER_CLOCK_SRC_INTERNAL+ TIMER_COMPARE_LD_ON_ZERO)

/*-----------------------------------------------------------------------------
Define the structure of the Capture Driver Object 
------------------------------------------------------------------------------*/
typedef struct { int time_stamp;
                 int (*init)();       /* Pointer to the init function         */
                 int (*read)();       /* Pointer to the init function         */
               } CAPTURE;

/*-----------------------------------------------------------------------------
Define a handle for the CAPTURE object
------------------------------------------------------------------------------*/
typedef CAPTURE *CAPTURE_handle;



/*------------------------------------------------------------------------------
Prototypes for the functions in F243_CAP.C
------------------------------------------------------------------------------*/
void F2407_EV1_CAP_Init(CAPTURE_handle);
int  F2407_EV1_CAP1_Read(CAPTURE_handle);                                             

/*------------------------------------------------------------------------------
Default Initializer for the F2407_EV1 CAPTURE Object
------------------------------------------------------------------------------*/
#define F2407EV1CAP1    {1,    \
                        (int (*)(int))F2407_EV1_CAP_Init,  \
                        (int (*)(int))F2407_EV1_CAP1_Read  \
                         }

/*------------------------------------------------------------------------------
Target Independent Default Initializer CAPTURE Object
------------------------------------------------------------------------------*/
#define CAPTURE_DEFAULTS F2407EV1CAP1


#endif /*  __F2407_CAP_H__ */




⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -