update version to v2.1.1

This commit is contained in:
Artery-MCU 2022-11-22 18:39:27 +08:00
parent 861b32d397
commit 622456829b
4145 changed files with 33960 additions and 40208 deletions

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437.h
* @version v2.1.0
* @date 2022-08-16
* @brief at32f435_437 header file
**************************************************************************
* Copyright notice & Disclaimer
@ -81,6 +79,42 @@ extern "C" {
#define AT32F437xx
#endif
#if defined (AT32F435ZCT7) || defined (AT32F435ZGT7) || defined (AT32F435ZMT7)
#define AT32F435Zx
#endif
#if defined (AT32F435VCT7) || defined (AT32F435VGT7) || defined (AT32F435VMT7)
#define AT32F435Vx
#endif
#if defined (AT32F435RCT7) || defined (AT32F435RGT7) || defined (AT32F435RMT7)
#define AT32F435Rx
#endif
#if defined (AT32F435CCU7) || defined (AT32F435CGU7) || defined (AT32F435CMU7) || \
defined (AT32F435CCT7) || defined (AT32F435CGT7) || defined (AT32F435CMT7)
#define AT32F435Cx
#endif
#if defined (AT32F437ZCT7) || defined (AT32F437ZGT7) || defined (AT32F437ZMT7)
#define AT32F437Zx
#endif
#if defined (AT32F437VCT7) || defined (AT32F437VGT7) || defined (AT32F437VMT7)
#define AT32F437Vx
#endif
#if defined (AT32F437RCT7) || defined (AT32F437RGT7) || defined (AT32F437RMT7)
#define AT32F437Rx
#endif
#ifndef USE_STDPERIPH_DRIVER
/**
* @brief comment the line below if you will not use the peripherals drivers.
@ -100,7 +134,7 @@ extern "C" {
*/
#define __AT32F435_437_LIBRARY_VERSION_MAJOR (0x02) /*!< [31:24] major version */
#define __AT32F435_437_LIBRARY_VERSION_MIDDLE (0x01) /*!< [23:16] middle version */
#define __AT32F435_437_LIBRARY_VERSION_MINOR (0x00) /*!< [15:8] minor version */
#define __AT32F435_437_LIBRARY_VERSION_MINOR (0x01) /*!< [15:8] minor version */
#define __AT32F435_437_LIBRARY_VERSION_RC (0x00) /*!< [7:0] release candidate */
#define __AT32F435_437_LIBRARY_VERSION ((__AT32F435_437_LIBRARY_VERSION_MAJOR << 24) | \
(__AT32F435_437_LIBRARY_VERSION_MIDDLE << 16) | \

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_conf.h
* @version v2.1.0
* @date 2022-08-16
* @brief at32f435_437 config header file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
******************************************************************************
* @file startup_at32f435_437.s
* @version v2.1.0
* @date 2022-08-16
* @brief at32f435_437 devices vector table for gcc toolchain.
* this module performs:
* - set the initial sp

View File

@ -1,7 +1,5 @@
;**************************************************************************
;* @file startup_at32f435_437.s
;* @version v2.1.0
;* @date 2022-08-16
;* @brief at32f435_437 startup file for IAR Systems
;**************************************************************************
;

View File

@ -1,7 +1,5 @@
;**************************************************************************
;* @file startup_at32f435_437.s
;* @version v2.1.0
;* @date 2022-08-16
;* @brief at32f435_437 startup file for keil
;* <<< Use Configuration Wizard in Context Menu >>>
;**************************************************************************

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file system_at32f435_437.c
* @version v2.1.0
* @date 2022-08-16
* @brief contains all the functions for cmsis cortex-m4 system source file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file system_at32f435_437.h
* @version v2.1.0
* @date 2022-08-16
* @brief cmsis cortex-m4 system header file.
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,8 @@
/******************************************************************************
* @file arm_sorting.h
* @version v2.1.0
* @date 2022-08-16
* @brief Private header file for CMSIS DSP Library
* @version V1.7.0
* @date 2019
******************************************************************************/
/*
* Copyright (c) 2010-2019 Arm Limited or its affiliates. All rights reserved.

View File

@ -1,8 +1,8 @@
/******************************************************************************
* @file arm_vec_fft.h
* @version v2.1.0
* @date 2022-08-16
* @brief Private header file for CMSIS DSP Library
* @version V1.7.0
* @date 07. January 2020
******************************************************************************/
/*
* Copyright (c) 2010-2020 Arm Limited or its affiliates. All rights reserved.

View File

@ -1,8 +1,8 @@
/******************************************************************************
* @file arm_vec_filtering.h
* @version v2.1.0
* @date 2022-08-16
* @brief Private header file for CMSIS DSP Library
* @version V1.7.0
* @date 30. October 2019
******************************************************************************/
/*
* Copyright (c) 2010-2019 Arm Limited or its affiliates. All rights reserved.

View File

@ -1,8 +1,8 @@
/******************************************************************************
* @file arm_math.h
* @version v2.1.0
* @date 2022-08-16
* @brief Public header file for CMSIS DSP Library
* @version V1.7.0
* @date 18. March 2019
******************************************************************************/
/*
* Copyright (c) 2010-2019 Arm Limited or its affiliates. All rights reserved.

View File

@ -1,8 +1,8 @@
/******************************************************************************
* @file arm_vec_math.h
* @version v2.1.0
* @date 2022-08-16
* @brief Public header file for CMSIS DSP Library
* @version V1.7.0
* @date 15. October 2019
******************************************************************************/
/*
* Copyright (c) 2010-2019 Arm Limited or its affiliates. All rights reserved.

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_acc.h
* @version v2.1.0
* @date 2022-08-16
* @brief at32f435_437 acc header file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_adc.h
* @version v2.1.0
* @date 2022-08-16
* @brief at32f435_437 adc header file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_can.h
* @version v2.1.0
* @date 2022-08-16
* @brief at32f435_437 can header file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_crc.h
* @version v2.1.0
* @date 2022-08-16
* @brief at32f435_437 crc header file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_crm.h
* @version v2.1.0
* @date 2022-08-16
* @brief at32f435_437 crm header file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_dac.h
* @version v2.1.0
* @date 2022-08-16
* @brief at32f435_437 dac header file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_mcudbg.h
* @version v2.1.0
* @date 2022-08-16
* @brief at32f435_437 mcudbg header file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_def.h
* @version v2.1.0
* @date 2022-08-16
* @brief at32f435_437 macros header file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_dma.h
* @version v2.1.0
* @date 2022-08-16
* @brief at32f435_437 dma header file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_dvp.h
* @version v2.1.0
* @date 2022-08-16
* @brief at32f435_437 dvp header file
**************************************************************************
* Copyright notice & Disclaimer
@ -301,7 +299,7 @@ typedef struct
__IO uint32_t pcds : 1; /* [18] */
__IO uint32_t lcdc : 1; /* [19] */
__IO uint32_t lcds : 1; /* [20] */
__IO uint32_t : 11;/* [31:21] */
__IO uint32_t reserved3 : 11;/* [31:21] */
} ctrl_bit;
};

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_edma.h
* @version v2.1.0
* @date 2022-08-16
* @brief at32f435_437 edma header file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_emac.h
* @version v2.1.0
* @date 2022-08-16
* @brief at32f435_437 eth header file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_ertc.h
* @version v2.1.0
* @date 2022-08-16
* @brief at32f435_437 ertc header file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_exint.h
* @version v2.1.0
* @date 2022-08-16
* @brief at32f435_437 exint header file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_flash.h
* @version v2.1.0
* @date 2022-08-16
* @brief at32f435_437 flash header file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_gpio.h
* @version v2.1.0
* @date 2022-08-16
* @brief at32f435_437 gpio header file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_i2c.h
* @version v2.1.0
* @date 2022-08-16
* @brief at32f435_437 i2c header file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_misc.h
* @version v2.1.0
* @date 2022-08-16
* @brief at32f435_437 misc header file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_pwc.h
* @version v2.1.0
* @date 2022-08-16
* @brief at32f435_437 pwr header file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_qspi.h
* @version v2.1.0
* @date 2022-08-16
* @brief at32f435_437 qspi header file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_scfg.h
* @version v2.1.0
* @date 2022-08-16
* @brief at32f435_437 system config header file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_sdio.h
* @version v2.1.0
* @date 2022-08-16
* @brief at32f435_437 sdio header file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_spi.h
* @version v2.1.0
* @date 2022-08-16
* @brief at32f435_437 spi header file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_tmr.h
* @version v2.1.0
* @date 2022-08-16
* @brief at32f435_437 tmr header file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_usart.h
* @version v2.1.0
* @date 2022-08-16
* @brief at32f435_437 usart header file
**************************************************************************
* Copyright notice & Disclaimer
@ -352,7 +350,10 @@ typedef struct
#define UART5 ((usart_type *) UART5_BASE)
#define USART6 ((usart_type *) USART6_BASE)
#define UART7 ((usart_type *) UART7_BASE)
#if defined (AT32F435Zx) || defined (AT32F435Vx) || defined (AT32F435Rx) || \
defined (AT32F437Zx) || defined (AT32F437Vx) || defined (AT32F437Rx)
#define UART8 ((usart_type *) UART8_BASE)
#endif
/** @defgroup USART_exported_functions
* @{

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_usb.h
* @version v2.1.0
* @date 2022-08-16
* @brief at32f435_437 usb header file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_wdt.h
* @version v2.1.0
* @date 2022-08-16
* @brief at32f435_437 wdt header file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_wwdt.h
* @version v2.1.0
* @date 2022-08-16
* @brief at32f435_437 wwdt header file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_xmc.h
* @version v2.1.0
* @date 2022-08-16
* @brief at32f435_437 xmc header file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_acc.c
* @version v2.1.0
* @date 2022-08-16
* @brief contains all the functions for the acc firmware library
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_adc.c
* @version v2.1.0
* @date 2022-08-16
* @brief contains all the functions for the adc firmware library
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_can.c
* @version v2.1.0
* @date 2022-08-16
* @brief contains all the functions for the can firmware library
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_crc.c
* @version v2.1.0
* @date 2022-08-16
* @brief contains all the functions for the crc firmware library
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_crm.c
* @version v2.1.0
* @date 2022-08-16
* @brief contains all the functions for the crm firmware library
**************************************************************************
* Copyright notice & Disclaimer
@ -470,6 +468,7 @@ void crm_ahb_div_set(crm_ahb_div_type value)
/**
* @brief set crm apb1 division
* @note the maximum frequency of APB1/APB2 clock is 144 MHz
* @param value
* this parameter can be one of the following values:
* - CRM_APB1_DIV_1
@ -486,6 +485,7 @@ void crm_apb1_div_set(crm_apb1_div_type value)
/**
* @brief set crm apb2 division
* @note the maximum frequency of APB1/APB2 clock is 144 MHz
* @param value
* this parameter can be one of the following values:
* - CRM_APB2_DIV_1
@ -625,7 +625,7 @@ void crm_clkout_to_tmr10_enable(confirm_state new_state)
* pll_ms
*
* pll_rcs_freq * pll_ns
* 500mhz <= -------------------------------- <= 1000mhz
* 500mhz <= -------------------------------- <= 1200mhz
* pll_ms
* @param clock_source
* this parameter can be one of the following values:
@ -647,6 +647,10 @@ void crm_pll_config(crm_pll_clock_source_type clock_source, uint16_t pll_ns, \
uint16_t pll_ms, crm_pll_fr_type pll_fr)
{
/* config pll clock source */
if(clock_source == CRM_PLL_SOURCE_HICK)
{
CRM->misc1_bit.hickdiv = CRM_HICK48_NODIV;
}
CRM->pllcfg_bit.pllrcs = clock_source;
/* config pll multiplication factor */
@ -890,7 +894,7 @@ void crm_interrupt_enable(uint32_t crm_int, confirm_state new_state)
* pll_ms
*
* pll_rcs_freq * pll_ns
* 500mhz <= -------------------------------- <= 1000mhz
* 500mhz <= -------------------------------- <= 1200mhz
* pll_ms
* @param pll_rcs
* this parameter can be one of the following values:
@ -905,7 +909,7 @@ void crm_interrupt_enable(uint32_t crm_int, confirm_state new_state)
error_status crm_pll_parameter_calculate(crm_pll_clock_source_type pll_rcs, uint32_t target_sclk_freq, \
uint16_t *ret_ms, uint16_t *ret_ns, uint16_t *ret_fr)
{
uint32_t pll_rcs_freq = 0, ns = 0, ms = 0, fr = 0;
int32_t pll_rcs_freq = 0, ns = 0, ms = 0, fr = 0;
uint32_t ms_min = 0, ms_max = 0, error_min = 0xFFFFFFFF;
uint32_t result = 0, absolute_value = 0;
@ -934,13 +938,13 @@ error_status crm_pll_parameter_calculate(crm_pll_clock_source_type pll_rcs, uint
/* polling pll parameters */
for(ms = ms_min; ms <= ms_max; ms ++)
{
for(fr = 0; fr <= 5; fr ++)
for(fr = 5; fr >= 0; fr --)
{
for(ns = 31; ns <= 500; ns ++)
{
result = (pll_rcs_freq * ns) / (ms);
/* check vco frequency range, accuracy with khz */
if((result < 500000U) || (result > 1000000U))
if((result < 500000U) || (result > 1200000U))
{
continue;
}

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_dac.c
* @version v2.1.0
* @date 2022-08-16
* @brief contains all the functions for the dac firmware library
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_mcudbg.c
* @version v2.1.0
* @date 2022-08-16
* @brief contains all the functions for the mcudbg firmware library
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_dma.c
* @version v2.1.0
* @date 2022-08-16
* @brief contains all the functions for the dma firmware library
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_dvp.c
* @version v2.1.0
* @date 2022-08-16
* @brief contains all the functions for the dvp firmware library
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_edma.c
* @version v2.1.0
* @date 2022-08-16
* @brief contains all the functions for the edma firmware library
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_emac.c
* @version v2.1.0
* @date 2022-08-16
* @brief contains all the functions for the emac firmware library
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_ertc.c
* @version v2.1.0
* @date 2022-08-16
* @brief contains all the functions for the ertc firmware library
**************************************************************************
* Copyright notice & Disclaimer
@ -98,15 +96,9 @@ error_status ertc_wait_update(void)
{
uint32_t timeout = ERTC_TIMEOUT * 2;
/* disable write protection */
ertc_write_protect_disable();
/* clear updf flag */
ERTC->sts = ~(ERTC_UPDF_FLAG | 0x00000080) | (ERTC->sts_bit.imen << 7);
/* enable write protection */
ertc_write_protect_enable();
while(ERTC->sts_bit.updf == 0)
{
if(timeout == 0)
@ -164,9 +156,6 @@ error_status ertc_init_mode_enter(void)
{
uint32_t timeout = ERTC_TIMEOUT * 2;
/* disable write protection */
ertc_write_protect_disable();
if(ERTC->sts_bit.imf == 0)
{
/* enter init mode */

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_exint.c
* @version v2.1.0
* @date 2022-08-16
* @brief contains all the functions for the exint firmware library
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_flash.c
* @version v2.1.0
* @date 2022-08-16
* @brief contains all the functions for the flash firmware library
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_gpio.c
* @version v2.1.0
* @date 2022-08-16
* @brief contains all the functions for the gpio firmware library
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_i2c.c
* @version v2.1.0
* @date 2022-08-16
* @brief contains all the functions for the i2c firmware library
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_misc.c
* @version v2.1.0
* @date 2022-08-16
* @brief contains all the functions for the misc firmware library
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_pwc.c
* @version v2.1.0
* @date 2022-08-16
* @brief contains all the functions for the pwc firmware library
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_qspi.c
* @version v2.1.0
* @date 2022-08-16
* @brief contain all the functions for qspi firmware library
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_scfg.c
* @version v2.1.0
* @date 2022-08-16
* @brief contains all the functions for the system config firmware library
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_sdio.c
* @version v2.1.0
* @date 2022-08-16
* @brief contains all the functions for the sdio firmware library
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_spi.c
* @version v2.1.0
* @date 2022-08-16
* @brief contains all the functions for the spi firmware library
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_tmr.c
* @version v2.1.0
* @date 2022-08-16
* @brief contains all the functions for the tmr firmware library
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_usart.c
* @version v2.1.0
* @date 2022-08-16
* @brief contains all the functions for the usart firmware library
**************************************************************************
* Copyright notice & Disclaimer
@ -86,11 +84,14 @@ void usart_reset(usart_type* usart_x)
crm_periph_reset(CRM_UART7_PERIPH_RESET, TRUE);
crm_periph_reset(CRM_UART7_PERIPH_RESET, FALSE);
}
#if defined (AT32F435Zx) || defined (AT32F435Vx) || defined (AT32F435Rx) || \
defined (AT32F437Zx) || defined (AT32F437Vx) || defined (AT32F437Rx)
else if(usart_x == UART8)
{
crm_periph_reset(CRM_UART8_PERIPH_RESET, TRUE);
crm_periph_reset(CRM_UART8_PERIPH_RESET, FALSE);
}
#endif
}
/**

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_usb.c
* @version v2.1.0
* @date 2022-08-16
* @brief contains all the functions for the usb firmware library
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_wdt.c
* @version v2.1.0
* @date 2022-08-16
* @brief contains all the functions for the wdt firmware library
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_wwdt.c
* @version v2.1.0
* @date 2022-08-16
* @brief contains all the functions for the wwdt firmware library
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file at32f435_437_xmc.c
* @version v2.1.0
* @date 2022-08-16
* @brief contains all the functions for the xmc firmware library
**************************************************************************
* Copyright notice & Disclaimer
@ -226,7 +224,7 @@ void xmc_nor_sram_enable(xmc_nor_sram_subbank_type xmc_subbank, confirm_state ne
*/
void xmc_ext_timing_config(xmc_nor_sram_subbank_type xmc_sub_bank, uint16_t w2w_timing, uint16_t r2r_timing)
{
XMC_BANK1->ext_bit[xmc_sub_bank].buslatr2r = r2r_timing<<8;
XMC_BANK1->ext_bit[xmc_sub_bank].buslatr2r = r2r_timing;
XMC_BANK1->ext_bit[xmc_sub_bank].buslatw2w = w2w_timing;
}

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file i2c_application.c
* @version v2.1.0
* @date 2022-08-16
* @brief the driver library of the i2c peripheral
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file i2c_application.h
* @version v2.1.0
* @date 2022-08-16
* @brief i2c application libray header file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file usb_core.h
* @version v2.1.0
* @date 2022-08-16
* @brief usb core header file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file usb_std.h
* @version v2.1.0
* @date 2022-08-16
* @brief usb standard header file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file usbd_core.h
* @version v2.1.0
* @date 2022-08-16
* @brief usb device core header file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file usbd_int.h
* @version v2.1.0
* @date 2022-08-16
* @brief usb interrupt header file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file usb_sdr.h
* @version v2.1.0
* @date 2022-08-16
* @brief usb header file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file usbh_core.h
* @version v2.1.0
* @date 2022-08-16
* @brief usb host core header file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file usbh_ctrl.h
* @version v2.1.0
* @date 2022-08-16
* @brief usb header file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file usbh_int.h
* @version v2.1.0
* @date 2022-08-16
* @brief usb header file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file usb_core.c
* @version v2.1.0
* @date 2022-08-16
* @brief usb driver
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file usbd_core.c
* @version v2.1.0
* @date 2022-08-16
* @brief usb device driver
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file usbd_int.c
* @version v2.1.0
* @date 2022-08-16
* @brief usb interrupt request
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file usbd_sdr.c
* @version v2.1.0
* @date 2022-08-16
* @brief usb standard device request
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file usbh_core.c
* @version v2.1.0
* @date 2022-08-16
* @brief usb host driver
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file usbh_ctrl.c
* @version v2.1.0
* @date 2022-08-16
* @brief usb host control request
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file usbh_int.c
* @version v2.1.0
* @date 2022-08-16
* @brief usb host interrupt request
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file audio_class.c
* @version v2.1.0
* @date 2022-08-16
* @brief usb audio class type
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file audio_class.h
* @version v2.1.0
* @date 2022-08-16
* @brief usb audio class file
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file audio_conf.h
* @version v2.1.0
* @date 2022-08-16
* @brief usb audio config
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file audio_desc.c
* @version v2.1.0
* @date 2022-08-16
* @brief usb audio device descriptor
**************************************************************************
* Copyright notice & Disclaimer
@ -170,9 +168,13 @@ ALIGNED_HEAD static uint8_t g_usbd_configuration[USBD_AUDIO_CONFIG_DESC_SIZE] AL
AUDIO_AC_FEATURE_UNIT, /* bDescriptorSubtype: feature unit type*/
AUDIO_MIC_FEATURE_UNIT_ID, /* bUnitID: id of this feature unit */
AUDIO_MIC_INPUT_TERMINAL_ID, /* bSourceID: from input terminal */
0x01, /* bControlSize: 1 byte */
0x01, /* bmaControls0: mute */
0x02, /* bmaControls1: volume */
0x02, /* bControlSize: 2 byte */
0x03, /* bmaControls0: mute & volume*/
0x00,
0x00, /* bmaControls1 */
0x00,
0x00, /* bmaControls2 */
0x00,
0x00, /* iFeature: unused */
AUDIO_OUTPUT_TERMINAL_SIZE, /* bLength: descriptor size */
@ -211,9 +213,13 @@ ALIGNED_HEAD static uint8_t g_usbd_configuration[USBD_AUDIO_CONFIG_DESC_SIZE] AL
AUDIO_AC_FEATURE_UNIT, /* bDescriptorSubtype: feature unit type*/
AUDIO_SPK_FEATURE_UNIT_ID, /* bUnitID: id of this feature unit */
AUDIO_SPK_INPUT_TERMINAL_ID, /* bSourceID: from input terminal */
0x01, /* bControlSize: 1 byte */
0x01, /* bmaControls0: mute*/
0x02, /* bmaControls1: volume */
0x02, /* bControlSize: 2 byte */
0x03, /* bmaControls0: mute & volume*/
0x00,
0x00, /* bmaControls1: 0x0000 */
0x00,
0x00, /* bmaControls2: 0x0000 */
0x00,
0x00, /* iFeature: unused */
AUDIO_OUTPUT_TERMINAL_SIZE, /* bLength: descriptor size */

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file audio_desc.h
* @version v2.1.0
* @date 2022-08-16
* @brief usb audio descriptor header file
**************************************************************************
* Copyright notice & Disclaimer
@ -151,7 +149,7 @@ extern "C" {
* @brief audio interface config
*/
#define AUDIO_INTERFACE_NUM (AUDIO_SUPPORT_SPK + AUDIO_SUPPORT_MIC)
#define AUDIO_INTERFACE_LEN ((0x08 + AUDIO_INTERFACE_NUM) + AUDIO_INTERFACE_NUM * 0x1E)
#define AUDIO_INTERFACE_LEN ((0x08 + AUDIO_INTERFACE_NUM) + AUDIO_INTERFACE_NUM * 0x22)
#define AUDIO_MIC_INTERFACE 0x01
#define AUDIO_SPK_INTERFACE 0x02
@ -160,7 +158,7 @@ extern "C" {
*/
#define AUDIO_INPUT_TERMINAL_SIZE 0x0C
#define AUDIO_OUTPUT_TERMINAL_SIZE 0x09
#define AUDIO_FEATURE_UNIT_SIZE 0x09
#define AUDIO_FEATURE_UNIT_SIZE 0x0D
/**
* @brief audio terminal id define

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file audio_conf.h
* @version v2.1.0
* @date 2022-08-16
* @brief usb audio config
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file audio_class.c
* @version v2.1.0
* @date 2022-08-16
* @brief usb audio class type
**************************************************************************
* Copyright notice & Disclaimer

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file audio_class.h
* @version v2.1.0
* @date 2022-08-16
* @brief usb audio class file
**************************************************************************
* Copyright notice & Disclaimer
@ -140,10 +138,10 @@ typedef struct
uint32_t hid_protocol;
uint32_t hid_set_idle;
uint32_t alt_setting;
uint8_t hid_state;
uint8_t hid_set_report[64];
uint8_t g_rxhid_buff[USBD_AUHID_OUT_MAXPACKET_SIZE];
uint8_t g_txhid_buff[USBD_AUHID_IN_MAXPACKET_SIZE];
uint8_t hid_state;
}usb_audio_hid_type;

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file audio_desc.c
* @version v2.1.0
* @date 2022-08-16
* @brief usb audio device descriptor
**************************************************************************
* Copyright notice & Disclaimer
@ -158,7 +156,7 @@ ALIGNED_HEAD static uint8_t g_usbd_configuration[USBD_AUHID_CONFIG_DESC_SIZE] AL
AUDIO_MIC_INPUT_TERMINAL_ID, /* bTerminalID: id of this input terminal*/
LBYTE(AUDIO_INPUT_TERMINAL_MICROPHONE),
HBYTE(AUDIO_INPUT_TERMINAL_MICROPHONE),/* wTerminalType: terminal is microphone */
AUDIO_MIC_OUTPUT_TERMINAL_ID, /* bAssocTerminal: no association */
0x00, /* bAssocTerminal: no association */
AUDIO_MIC_CHR, /* bNrChannels: two channel */
#if (AUDIO_MIC_CHR == 2)
0x03, /* wChannelConfig: left front and right front */
@ -175,9 +173,13 @@ ALIGNED_HEAD static uint8_t g_usbd_configuration[USBD_AUHID_CONFIG_DESC_SIZE] AL
AUDIO_AC_FEATURE_UNIT, /* bDescriptorSubtype: feature unit type*/
AUDIO_MIC_FEATURE_UNIT_ID, /* bUnitID: id of this feature unit */
AUDIO_MIC_INPUT_TERMINAL_ID, /* bSourceID: from input terminal */
0x01, /* bControlSize: 1 byte */
0x01, /* bmaControls0: mute */
0x02, /* bmaControls1: volume */
0x02, /* bControlSize: 2 byte */
0x03, /* bmaControls0: mute & volume*/
0x00,
0x00, /* bmaControls1 */
0x00,
0x00, /* bmaControls2 */
0x00,
0x00, /* iFeature: unused */
AUDIO_OUTPUT_TERMINAL_SIZE, /* bLength: descriptor size */
@ -186,7 +188,7 @@ ALIGNED_HEAD static uint8_t g_usbd_configuration[USBD_AUHID_CONFIG_DESC_SIZE] AL
AUDIO_MIC_OUTPUT_TERMINAL_ID, /* bTerminalID: id of this output terminal*/
LBYTE(AUDIO_TERMINAL_TYPE_STREAMING),
HBYTE(AUDIO_TERMINAL_TYPE_STREAMING), /* wTerminalType: usb streaming */
AUDIO_MIC_INPUT_TERMINAL_ID, /* bAssocTerminal: unused */
0x00, /* bAssocTerminal: unused */
AUDIO_MIC_FEATURE_UNIT_ID, /* bSourceID: from feature unit terminal */
0x00, /* iTerminal: unused */
#endif
@ -199,7 +201,7 @@ ALIGNED_HEAD static uint8_t g_usbd_configuration[USBD_AUHID_CONFIG_DESC_SIZE] AL
AUDIO_SPK_INPUT_TERMINAL_ID, /* bTerminalID: id of this input terminal*/
LBYTE(AUDIO_TERMINAL_TYPE_STREAMING), /* wTerminalType: usb streaming */
HBYTE(AUDIO_TERMINAL_TYPE_STREAMING), /* wTerminalType: usb streaming */
AUDIO_SPK_OUTPUT_TERMINAL_ID, /* bAssocTerminal: no association */
0x00, /* bAssocTerminal: no association */
AUDIO_SPK_CHR, /* bNrChannels: two channel */
#if (AUDIO_SPK_CHR == 2)
0x03, /* wChannelConfig: left front and right front */
@ -216,9 +218,13 @@ ALIGNED_HEAD static uint8_t g_usbd_configuration[USBD_AUHID_CONFIG_DESC_SIZE] AL
AUDIO_AC_FEATURE_UNIT, /* bDescriptorSubtype: feature unit type*/
AUDIO_SPK_FEATURE_UNIT_ID, /* bUnitID: id of this feature unit */
AUDIO_SPK_INPUT_TERMINAL_ID, /* bSourceID: from input terminal */
0x01, /* bControlSize: 1 byte */
0x01, /* bmaControls0: mute*/
0x02, /* bmaControls1: volume */
0x02, /* bControlSize: 2 byte */
0x03, /* bmaControls0: mute & volume*/
0x00,
0x00, /* bmaControls1: 0x0000 */
0x00,
0x00, /* bmaControls2: 0x0000 */
0x00,
0x00, /* iFeature: unused */
AUDIO_OUTPUT_TERMINAL_SIZE, /* bLength: descriptor size */
@ -227,7 +233,7 @@ ALIGNED_HEAD static uint8_t g_usbd_configuration[USBD_AUHID_CONFIG_DESC_SIZE] AL
AUDIO_SPK_OUTPUT_TERMINAL_ID, /* bTerminalID: id of this output terminal*/
LBYTE(AUDIO_OUTPUT_TERMINAL_SPEAKER), /* wTerminalType: usb speaker */
HBYTE(AUDIO_OUTPUT_TERMINAL_SPEAKER), /* wTerminalType: usb speaker */
AUDIO_SPK_INPUT_TERMINAL_ID, /* bAssocTerminal: unused */
0x00, /* bAssocTerminal: unused */
AUDIO_SPK_FEATURE_UNIT_ID, /* bSourceID: from feature unit terminal */
0x00, /* iTerminal: unused */
#endif

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file audio_desc.h
* @version v2.1.0
* @date 2022-08-16
* @brief usb audio descriptor header file
**************************************************************************
* Copyright notice & Disclaimer
@ -150,7 +148,7 @@ extern "C" {
* @brief audio interface config
*/
#define AUDIO_INTERFACE_NUM (AUDIO_SUPPORT_SPK + AUDIO_SUPPORT_MIC)
#define AUDIO_INTERFACE_LEN ((0x08 + AUDIO_INTERFACE_NUM) + AUDIO_INTERFACE_NUM * 0x1E)
#define AUDIO_INTERFACE_LEN ((0x08 + AUDIO_INTERFACE_NUM) + AUDIO_INTERFACE_NUM * 0x22)
#define AUDIO_MIC_INTERFACE 0x01
#define AUDIO_SPK_INTERFACE 0x02
@ -159,7 +157,7 @@ extern "C" {
*/
#define AUDIO_INPUT_TERMINAL_SIZE 0x0C
#define AUDIO_OUTPUT_TERMINAL_SIZE 0x09
#define AUDIO_FEATURE_UNIT_SIZE 0x09
#define AUDIO_FEATURE_UNIT_SIZE 0x0D
/**
* @brief audio terminal id define

View File

@ -1,8 +1,6 @@
/**
**************************************************************************
* @file cdc_class.c
* @version v2.1.0
* @date 2022-08-16
* @brief usb cdc class type
**************************************************************************
* Copyright notice & Disclaimer

Some files were not shown because too many files have changed in this diff Show More