Classes | Macros | Typedefs | Enumerations | Functions
gr55xx_hal_cgc.h File Reference

Header file containing functions prototypes of CGC HAL library. More...

`#include "gr55xx_ll_cgc.h"`
`#include "gr55xx_hal_def.h"`
Include dependency graph for gr55xx_hal_cgc.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

## Classes
struct | _cgc_init
| CGC init structure definition. More...

## Macros
#define | CGC_WFI_SECU_HCLK ((uint32_t)0x00000001U)
| Hclk for all security blocks. More...
#define | CGC_WFI_SIM_HCLK ((uint32_t)0x00000002U)
| Hclk for sim card interface More...
#define | CGC_WFI_HTB_HCLK ((uint32_t)0x00000004U)
| Hclk for hopping table More...
#define | CGC_WFI_PWM_HCLK ((uint32_t)0x00000008U)
| Hclk for PWM More...
#define | CGC_WFI_ROM_HCLK ((uint32_t)0x00000010U)
| Hclk for ROM More...
#define | CGC_WFI_SNSADC_HCLK ((uint32_t)0x00000020U)
| Hclk for sense ADC More...
#define | CGC_WFI_GPIO_HCLK ((uint32_t)0x00000040U)
| Hclk for GPIOs More...
#define | CGC_WFI_DMA_HCLK ((uint32_t)0x00000080U)
| Hclk for DMA engine More...
#define | CGC_WFI_BLE_BRG_HCLK ((uint32_t)0x00000100U)
| Hclk for BLE MCU bridge More...
#define | CGC_WFI_APB_SUB_HCLK ((uint32_t)0x00000200U)
| Hclk for APB subsystem More...
#define | CGC_WFI_SERIAL_HCLK ((uint32_t)0x00000400U)
| Hclk for serial blocks More...
#define | CGC_WFI_I2S_S_HCLK ((uint32_t)0x00000800U)
| Hclk for I2S slave More...
#define | CGC_WFI_AON_MCUSUB_HCLK ((uint32_t)0x00001000U)
| Hclk for Always-on register More...
#define | CGC_WFI_XF_XQSPI_HCLK ((uint32_t)0x00002000U)
| Hclk for cache top More...
#define | CGC_WFI_SRAM_HCLK ((uint32_t)0x00004000U)
| Hclk for SRAMs More...
#define | CGC_WFI_SECU_DIV4_PCLK ((uint32_t)0x00008000U)
| Div4 clk for security blocks. More...
#define | CGC_WFI_XQSPI_DIV4_PCLK ((uint32_t)0x00020000U)
| Div4 clk for xf qspi More...
#define | CGC_WFI_ALL_CLK ((uint32_t)0x0002FFFFU)
| All clocks More...
#define | CGC_FRC_SECU_HCLK ((uint32_t)0x00000001U)
| Hclk for all security blocks. More...
#define | CGC_FRC_SIM_HCLK ((uint32_t)0x00000002U)
| Hclk for sim card interface More...
#define | CGC_FRC_HTB_HCLK ((uint32_t)0x00000004U)
| Hclk for hopping table More...
#define | CGC_FRC_PWM_HCLK ((uint32_t)0x00000008U)
| Hclk for PWM More...
#define | CGC_FRC_ROM_HCLK ((uint32_t)0x00000010U)
| Hclk for ROM More...
#define | CGC_FRC_SNSADC_HCLK ((uint32_t)0x00000020U)
| Hclk for sense ADC More...
#define | CGC_FRC_GPIO_HCLK ((uint32_t)0x00000040U)
| Hclk for GPIOs More...
#define | CGC_FRC_DMA_HCLK ((uint32_t)0x00000080U)
| Hclk for DMA engine More...
#define | CGC_FRC_BLE_BRG_HCLK ((uint32_t)0x00000100U)
| Hclk for BLE MCU bridge More...
#define | CGC_FRC_APB_SUB_HCLK ((uint32_t)0x00000200U)
| Hclk for APB subsystem More...
#define | CGC_FRC_SERIAL_HCLK ((uint32_t)0x00000400U)
| Hclk for serial blocks More...
#define | CGC_FRC_I2S_S_HCLK ((uint32_t)0x00000800U)
| Hclk for I2S slave More...
#define | CGC_FRC_AON_MCUSUB_HCLK ((uint32_t)0x00001000U)
| Hclk for Always-on register More...
#define | CGC_FRC_XF_XQSPI_HCLK ((uint32_t)0x00002000U)
| Hclk for cache top More...
#define | CGC_FRC_SRAM_HCLK ((uint32_t)0x00004000U)
| Hclk for SRAMs More...
#define | CGC_FRC_UART0_HCLK ((uint32_t)0x00008000U)
| Hclk for uart0 More...
#define | CGC_FRC_UART1_HCLK ((uint32_t)0x00010000U)
| Hclk for uart1 More...
#define | CGC_FRC_I2C0_HCLK ((uint32_t)0x00020000U)
| Hclk for i2c0 More...
#define | CGC_FRC_I2C1_HCLK ((uint32_t)0x00040000U)
| Hclk for i2c1 More...
#define | CGC_FRC_SPIM_HCLK ((uint32_t)0x00080000U)
| Hclk for spim More...
#define | CGC_FRC_SPIS_HCLK ((uint32_t)0x00100000U)
| Hclk for spis More...
#define | CGC_FRC_QSPI0_HCLK ((uint32_t)0x00200000U)
| Hclk for qspi0 More...
#define | CGC_FRC_QSPI1_HCLK ((uint32_t)0x00400000U)
| Hclk for qspi1 More...
#define | CGC_FRC_I2S_HCLK ((uint32_t)0x00800000U)
| Hclk for i2s More...
#define | CGC_FRC_SECU_DIV4_PCLK ((uint32_t)0x01000000U)
| Div4 clk for security blocks. More...
#define | CGC_FRC_XQSPI_DIV4_PCLK ((uint32_t)0x04000000U)
| Div4 clk for xf qspi More...
#define | CGC_FRC_ALL_CLK ((uint32_t)0x05FFFFFFU)
| All clocks More...
#define | CGC_DEFAULT_CONFIG

## Typedefs
typedef struct _cgc_init | cgc_init_t
| CGC init structure definition. More...

## Enumerations
enum | cgc_clk_state_t { CGC_CLK_ON = 0U, CGC_CLK_OFF = 1U }
| CGC Bit Open and Bit Close Enumerations. More...

## Functions
void | hal_cgc_init (cgc_init_t *p_cgc_init)
| Initialize the CGC registers according to the specified parameters in the cgc_init_t. More...
void | hal_cgc_deinit (void)
| De-initialize the CGC registers to their default reset values. More...
void | hal_cgc_config_wfi_clk (uint32_t blocks, cgc_clk_state_t clk_state)
| Configure the clock state for a specified block during WFI. More...
cgc_clk_state_t | hal_cgc_get_wfi_clk (uint32_t block)
| Get the clock state for a specified block during WFI. More...
void | hal_cgc_config_force_clk (uint32_t blocks, cgc_clk_state_t clk_state)
| Forced to Configure the clock state for a specified block. More...
cgc_clk_state_t | hal_cgc_get_force_clk (uint32_t block)
| Get the clock status of the currently specified block. More...

## Detailed Description

Header file containing functions prototypes of CGC HAL library.

Author
  BLE Driver Team

Attention

  ##### Copyright (c) 2019 GOODIX

All rights reserved.

Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. Neither the name of GOODIX nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL COPYRIGHT HOLDERS AND CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

Definition in file gr55xx_hal_cgc.h.