1 /**
2   ******************************************************************************
3   * @file    rtl8721d_loguart.h
4   * @author
5   * @version V1.0.0
6   * @date    2016-05-17
7   * @brief   This file contains all the functions prototypes for UART LOG firmware
8   *          library.
9   ******************************************************************************
10   * @attention
11   *
12   * This module is a confidential and proprietary property of RealTek and
13   * possession or use of this module requires written permission of RealTek.
14   *
15   * Copyright(c) 2015, Realtek Semiconductor Corporation. All rights reserved.
16   ******************************************************************************
17   */
18 
19 #ifndef _8710B_DIAG_H_
20 #define _8710B_DIAG_H_
21 
22 /** @addtogroup AmebaD_Platform
23   * @{
24   */
25 
26 /** @defgroup DIAG
27   * @brief DIAG driver modules
28   * @{
29   */
30 
31 /** @addtogroup DIAG
32   * @verbatim
33   *****************************************************************************************
34   * Introduction
35   *****************************************************************************************
36   *		-Control API for LOGUART.
37   *		-These API is used by system, user should not use these API if not needed.
38   *		-LOGUART is UART2.
39   *
40   *****************************************************************************************
41   * pinmux
42   *****************************************************************************************
43   *		-S0: GPIOA_16/17: QFN48, QFN68, QFN48-MCM.
44   *		-S1: GPIOA_29/30: QFN32.
45   *		-EFUSE 0x19[6]: 0: S1 PA29 & PA30, 1: S0 PA16 & PA17.
46   *
47   *****************************************************************************************
48   * @endverbatim
49   */
50 
51 /* Exported constants --------------------------------------------------------*/
52 
53 /** @defgroup DIAG_Exported_Constants DIAG Exported Constants
54   * @{
55   */
56 
57 /**
58   * @}
59   */
60 
61 /* Exported functions --------------------------------------------------------*/
62 /** @defgroup DIAG_Exported_Functions DIAG Exported Functions
63   * @{
64   */
65 _LONG_CALL_ void LOGUART_DiagInit(BOOL InitConsol);
66 
67 _LONG_CALL_ void LOGUART_PutChar(u8 c);
68 _LONG_CALL_ u8 LOGUART_GetChar(BOOL    PullMode);
69 _LONG_CALL_ u8 LOGUART_Readable(void);
70 _LONG_CALL_ u32 LOGUART_GetIMR(void);
71 _LONG_CALL_ void LOGUART_SetIMR (u32 SetValue);
72 _LONG_CALL_ void LOGUART_WaitBusy(void);
73 
74 _LONG_CALL_ void LOGUART_SetBaud_FromFlash(void);
75 
76 #define DiagPutChar		LOGUART_PutChar
77 #define DiagGetChar		LOGUART_GetChar
78 /**
79   * @}
80   */
81 
82 
83 /**
84   * @}
85   */
86 
87 /**
88   * @}
89   */
90 
91 /* Other definations --------------------------------------------------------*/
92 
93 #endif //_8710B_DIAG_H_
94 /******************* (C) COPYRIGHT 2016 Realtek Semiconductor *****END OF FILE****/
95