• 大小: 49.3M
    文件类型: .zip
    金币: 1
    下载: 0 次
    发布日期: 2023-06-17
  • 语言: 其他
  • 标签: 其他  

资源简介

Demol_Code_IAR.zip

资源截图

代码片段和文件信息

/*
 * Copyright (c) 2016 Freescale Semiconductor Inc.
 * Copyright 2016-2017 NXP
 * All rights reserved.
 *
 * THIS SOFTWARE IS PROVIDED BY NXP “AS IS“ AND ANY EXPRESSED 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 NXP OR ITS 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.
 */
/*!
 * @file adc_driver.c
 *
 * @page misra_violations MISRA-C:2012 violations
 *
 * @section [global]
 * Violates MISRA 2012 Advisory Rule 11.4 Conversion between a pointer and integer type.
 * The cast is required to initialize a pointer with an unsigned long define representing an address.
 *
 * @section [global]
 * Violates MISRA 2012 Required Rule 11.6 Cast from unsigned int to pointer.
 * The cast is required to initialize a pointer with an unsigned long define representing an address.
 *
 * @section [global]
 * Violates MISRA 2012 Advisory Rule 8.7 External could be made static.
 * Function is defined for usage by application code.
 *
 */

#include 
#include “adc_driver.h“
#include “adc_hw_access.h“

/*******************************************************************************
 * Variables
 ******************************************************************************/

/* Table of base addresses for ADC instances. */
static ADC_Type * const s_adcbase[ADC_INSTANCE_COUNT] = ADC_base_PTRS;

/*FUNCTION**********************************************************************
 *
 * Function Name : ADC_DRV_InitConverterStruct
 * Description   : This function initializes the members of the adc_converter_config_t
 * structure to default values (Reference Manual resets). This function should be called
 * on a structure before using it to configure the converter (ADC_DRV_ConfigConverter) otherwise all members
 * must be written (initialized) by the caller. This function insures that all members are written
 * with safe values so the user can modify only the desired members.
 *
 * Implements : ADC_DRV_InitConverterStruct_Activity
 *END**************************************************************************/
void ADC_DRV_InitConverterStruct(adc_converter_config_t * const config)
{
    DEV_ASSERT(config != NULL);

    config->clockDivide    = ADC_CLK_DIVIDE_1;
    config->sampleTime     = (uint8_t)ADC_DEFAULT_SAMPLE_TIME;
    config->resolution     = ADC_RESOLUTION_8BIT;
    config->inputClock     = ADC_CLK_ALT_1;
    config->tr

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----
     目录           0  2019-03-06 14:24  Debug\
     目录           0  2019-03-26 16:40  Debug\Exe\
     文件     1417884  2019-03-26 16:40  Debug\Exe\SKY32BCM-LOWLEVEL-24.out
     文件      436260  2018-10-09 11:40  Debug\Exe\SKY32BCM-LOWLEVEL-24.out.r21
     文件      570340  2018-10-09 11:40  Debug\Exe\SKY32BCM-LOWLEVEL-24.out.r22
     文件       42764  2019-03-26 16:36  Debug\Exe\SKY32BCM-LOWLEVEL-24.sim
     文件      233296  2018-10-09 11:41  Debug\Exe\SKY32BCM-LOWLEVEL-24V_9_27.s19
     文件      117500  2019-03-26 16:40  Debug\Exe\SKY32BCM-LOWLEVEL-24V_9_27.srec
     目录           0  2019-03-26 16:40  Debug\List\
     文件      119117  2019-03-26 16:40  Debug\List\SKY32BCM-LOWLEVEL-24.map
     文件       44834  2018-10-09 11:40  Debug\List\SKY32BCM-LOWLEVEL-24.map.mine
     文件       29253  2018-10-09 11:40  Debug\List\SKY32BCM-LOWLEVEL-24.map.r21
     文件       32013  2018-10-09 11:40  Debug\List\SKY32BCM-LOWLEVEL-24.map.r22
     目录           0  2019-03-26 16:40  Debug\Obj\
     文件       21907  2018-10-09 11:40  Debug\Obj\AES.pbi.xcl
     文件       34978  2018-11-04 10:46  Debug\Obj\AES_Lib.o
     文件       21579  2018-11-04 10:50  Debug\Obj\AES_Lib.pbi.xcl
     文件       20640  2019-03-25 15:51  Debug\Obj\Adc_dri.o
     文件     1551652  2019-03-25 15:53  Debug\Obj\Adc_dri.pbi
     文件       18615  2019-03-25 15:53  Debug\Obj\Adc_dri.pbi.xcl
     文件       52282  2019-03-25 15:51  Debug\Obj\Adc_hal.o
     文件     1561129  2019-03-25 15:53  Debug\Obj\Adc_hal.pbi
     文件       18615  2019-03-25 15:53  Debug\Obj\Adc_hal.pbi.xcl
     文件       18640  2019-03-25 15:53  Debug\Obj\Boot_Intf_External.pbi.xcl
     文件        5537  2019-03-18 11:42  Debug\Obj\Boot_config.o
     文件         953  2019-03-18 11:23  Debug\Obj\Boot_config.pbi
     文件       18633  2019-03-18 11:23  Debug\Obj\Boot_config.pbi.xcl
     文件       55632  2019-03-26 16:35  Debug\Obj\Boot_handle.o
     文件     1660907  2019-03-26 16:29  Debug\Obj\Boot_handle.pbi
     文件       18633  2019-03-26 16:29  Debug\Obj\Boot_handle.pbi.xcl
     文件       26345  2019-03-25 15:51  Debug\Obj\Boot_intf_external.o
............此处省略910个文件信息

评论

共有 条评论