testuart0.h

来自「这是一个基于nec78f8024的led驱动程序」· C头文件 代码 · 共 44 行

H
44
字号
/*
*******************************************************************************
**  COPYRIGHT (C) NEC Electronics Corporation 2008
**  NEC ELECTRONICS CONFIDENTIAL AND PROPRIETARY
**  All rights reserved by NEC Electronics Corporation.
**  Use of copyright notice does not evidence publication.
**
**  Filename :	UART0.h
**  Abstract :	This file implements the definition that relates to the UART0 communication 
**              not influenced by the setting in the GUI application. 
**
**  Device :	uPD78F8024
**
**  Compiler :	NEC/CC78K0
**
*******************************************************************************
*/
#ifndef	_MDUART0_
#define _MDUART0_

/* Mnemonic of register that relates to port used by UART0 communication */
#define	PORT_TXD0				P1.0
#define	PORT_MODE_TXD0			PM1.0
#define	PORT_RXD0				P1.1
#define	PORT_MODE_RXD0			PM1.1

/* mnemonic of register related to UART0 communication control */
#define	POWER0					ASIM0.7

#ifndef _MDUART6_
/* constant definition related to UART0 communication */
#define	SEND_DATA_LENGTH_BINARY	1
#define	SEND_DATA_LENGTH_ASCII	5
#define	UART_ERROR_CHECK_VALUE	0b00000111
#endif

/* function prototypes */
void UART0_init(void);
short  UART0_getValue( unsigned char  ucChannel );
void  calibrateBaudrate( unsigned char  uc1BitWidth );

#endif

⌨️ 快捷键说明

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