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

📄 uart.h

📁 关于zigbee厂家jennic的zigbee通信模块JN5139的一些示例程序。
💻 H
字号:
/***************************************************************************/
/*!
 *\MODULE              Wireless UART with Flow Control
 *
 *\COMPONENT           $RCSfile: Uart.h,v $
 *
 *\VERSION             $Name:  $
 *
 *\REVISION            $Revision: 1.5 $
 *
 *\DATED               $Date: 2008/03/26 14:40:45 $
 *
 *\STATUS              $State: Exp $
 *
 *\AUTHOR              Ian Morris
 *	   \n			   Martin Looker
 *
 *\DESCRIPTION         Controls transmission and reception of data on the UART.
 */
/*\CHANGE HISTORY
 *
 * $Log: Uart.h,v $
 * Revision 1.5  2008/03/26 14:40:45  mlook
 * Now scans channels
 *
 * Revision 1.4  2008/03/20 10:39:38  mlook
 * Removed header values for Respiratronics.
 *
 * Revision 1.3  2008/03/20 10:36:12  mlook
 * *** empty log message ***
 *
 * Revision 1.2  2008/01/21 14:35:50  mlook
 * Restored correct baud rate.
 *
 * Revision 1.1  2008/01/21 10:15:05  mlook
 * Initial checkin
 *
 * Revision 1.1  2007/11/02 12:32:53  mlook
 * Adding new application notes
 *
 *
 *
 *\LAST MODIFIED BY    $Author: mlook $
 *                     $Modtime: $
 *
 ****************************************************************************
 *
 * This software is owned by Jennic and/or its supplier and is protected
 * under applicable copyright laws. All rights are reserved. We grant You,
 * and any third parties, a license to use this software solely and
 * exclusively on Jennic products. You, and any third parties must reproduce
 * the copyright and warranty notice and any other legend of ownership on each
 * copy or partial copy of the software.
 *
 * THIS SOFTWARE IS PROVIDED "AS IS". JENNIC MAKES NO WARRANTIES, WHETHER
 * EXPRESS, IMPLIED OR STATUTORY, INCLUDING, BUT NOT LIMITED TO, IMPLIED
 * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE,
 * ACCURACY OR LACK OF NEGLIGENCE. JENNIC SHALL NOT, IN ANY CIRCUMSTANCES,
 * BE LIABLE FOR ANY DAMAGES, INCLUDING, BUT NOT LIMITED TO, SPECIAL,
 * INCIDENTAL OR CONSEQUENTIAL DAMAGES FOR ANY REASON WHATSOEVER.
 *
 * Copyright Jennic Ltd 2005, 2006, 2007. All rights reserved
 *
 ****************************************************************************/


#ifndef  UART_H_INCLUDED
#define  UART_H_INCLUDED

#if defined __cplusplus
extern "C" {
#endif

/****************************************************************************/
/***        Include Files                                                 ***/
/****************************************************************************/
#include <jendefs.h>
#include <JPI.h>

/****************************************************************************/
/***        Macro Definitions                                             ***/
/****************************************************************************/
/* Define which of the two available hardware UARTs and what baud rate to use */
#define UART                    E_JPI_UART_0		/**< UART to use */
#define UART_BAUD_RATE          115200				/**< Baud rate */
#define UART_AUTOFLOW			FALSE				/**< Define hardware flow control type.
                                                      *  FALSE app controls RTS/CTS, TRUE UART controls RTS/CTS */

#if UART == E_JPI_UART_0
	#define UART_DEVICE         E_JPI_DEVICE_UART0	/**< UART device */
#else
	#define UART_DEVICE         E_JPI_DEVICE_UART1 	/**< UART device */
#endif

/****************************************************************************/
/***        Type Definitions                                              ***/
/****************************************************************************/

/****************************************************************************/
/***        Exported Functions                                            ***/
/****************************************************************************/
PUBLIC void     vUart_Init(void);
PUBLIC void     vUart_StartTx(void);
PUBLIC void     vUart_RxCharIsr(uint8 u8RxChar);
PUBLIC void     vUart_TxCharIsr(void);
PUBLIC void   	vUart_SetTxEnable(bool_t);
PUBLIC bool_t   bUart_GetTxEnable(void);
PUBLIC void   	vUart_SetRxEnable(bool_t);
PUBLIC bool_t   bUart_GetRxEnable(void);

/****************************************************************************/
/***        Exported Variables                                            ***/
/****************************************************************************/

#if defined __cplusplus
}
#endif

#endif  /* UART_H_INCLUDED */

/****************************************************************************/
/***        END OF FILE                                                   ***/
/****************************************************************************/


⌨️ 快捷键说明

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