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

📄 sci_drv.h

📁 ST72T63游戏杆源程序
💻 H
字号:
/**** (c) 1998  SGS-Thomson Microelectronics **********************

PROJECT  :       EVALUATION BOARD - ST7 SCI DEMO SYSTEM
COMPILER :       ST7 HICROSS C (HIWARE)
MODULE  :        sci_drv.h
CREATION DATE :  10/10/98
AUTHOR :         Cyril Troise
-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-
                                   UPS Project
-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-
                 
******************************************************************************/

/* STATIC DECLARATIONS *******************************************************/
/* List of all the variables/constant defined in another module and used in  */
/* this one.                                                                 */
/* MODEL => static type_name var_name;  or #define                           */

/* SCI possible speeds ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~*/ 
/* The application is validated on a ST72311, using a 8MHz fcpu clock.          */
/* The use of the extended prescalers is not required for the speeds below.    */   
   #define BRR_SPEED   0x1B; /* RX = 31250  TX = 31250 */

/* SCI register initial values ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~*/ 
/* extended prescalers Baud rate register                                   */
  #define FIRST_PAD_SPEED   0x0B; /* RX=31250 TX=128k. */
  #define NOT_FIRST_PAD_SPEED   0x09              /* RX=128k TX=128k        */                      
  
  #define CR1_8B_MODE  0x00                  /*                 8 bits word */
/* Mode selection.                                                          */  
  #define CR1_MODE      CR1_8B_MODE                                         

/* SCI register values ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~*/ 
/* Control register in reception only mode.                                  */ 
  #define CR2_RX_VAL   0x04        /* Reception only mode without interrupts.*/ 
/* Control register in reception only mode.                                  */ 
  #define CR2_RX_INT   0x24        /* Reception only mode with interrupts.   */ 
/*; Control register in transmission only mode.                              */
  #define CR2_TX_VAL   0x08     /* Transmission only mode without interrupts.*/

/* FUNCTION DESCRIPTIONS *****************************************************/
/* Description of all the functions defined in this module.                  */
/* MODEL => [static] type_name var_name;  or #define                         */

//extern void SCI_Init    (void);
extern void SCI_Tx      (char* /*buff_add*/,char /*Nb*/);
extern void SCI_Rx      (char /*Nb*/);


⌨️ 快捷键说明

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