• 大小: 13.71MB
    文件类型: .rar
    金币: 1
    下载: 0 次
    发布日期: 2023-06-29
  • 语言: 其他
  • 标签:

资源简介

包含CMSIS-DAP的硬件电路图和PCB(AD15)以及软件源码。 新版Keil打开工作可能会出现部分头文件找不到,请先安装Keil5的旧版支持包。

资源截图

代码片段和文件信息

/*
 * Copyright (c) 2013-2017 ARM Limited. All rights reserved.
 *
 * SPDX-License-Identifier: Apache-2.0
 *
 * Licensed under the Apache License Version 2.0 (the License); you may
 * not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 * www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing software
 * distributed under the License is distributed on an AS IS BASIS WITHOUT
 * WARRANTIES OR CONDITIONS OF ANY KIND either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 *
 * ----------------------------------------------------------------------
 *
 * $Date:        1. December 2017
 * $Revision:    V2.0.0
 *
 * Project:      CMSIS-DAP Source
 * title:        DAP.c CMSIS-DAP Commands
 *
 *---------------------------------------------------------------------------*/

#include 
#include “DAP_config.h“
#include “DAP.h“


#if (DAP_PACKET_SIZE < 64U)
#error “Minimum Packet Size is 64!“
#endif
#if (DAP_PACKET_SIZE > 32768U)
#error “Maximum Packet Size is 32768!“
#endif
#if (DAP_PACKET_COUNT < 1U)
#error “Minimum Packet Count is 1!“
#endif
#if (DAP_PACKET_COUNT > 255U)
#error “Maximum Packet Count is 255!“
#endif


// Clock Macros

#define MAX_SWJ_CLOCK(delay_cycles) \
  ((CPU_CLOCK/2U) / (IO_PORT_WRITE_CYCLES + delay_cycles))

#define CLOCK_DELAY(swj_clock) \
 (((CPU_CLOCK/2U) / swj_clock) - IO_PORT_WRITE_CYCLES)


         DAP_Data_t DAP_Data;           // DAP Data
volatile uint8_t    DAP_TransferAbort;  // Transfer Abort Flag

#ifdef DAP_VENDOR
const char DAP_Vendor [] = DAP_VENDOR;
#endif

#ifdef DAP_PRODUCT
const char DAP_Product[] = DAP_PRODUCT;
#endif

#ifdef DAP_SER_NUM
const char DAP_SerNum [] = DAP_SER_NUM;
#endif

static const char DAP_FW_Ver [] = DAP_FW_VER;

#if TARGET_DEVICE_FIXED
static const char TargetDeviceVendor [] = TARGET_DEVICE_VENDOR;
static const char TargetDeviceName   [] = TARGET_DEVICE_NAME;
#endif

// Get DAP Information
//   id:      info identifier
//   info:    pointer to info data
//   return:  number of bytes in info data
static uint8_t DAP_Info(uint8_t id uint8_t *info) {
  uint8_t length = 0U;

  switch (id) {
    case DAP_ID_VENDOR:
#ifdef DAP_VENDOR
memcpy(info DAP_Vendor sizeof(DAP_Vendor));
length = sizeof(DAP_Vendor);
#endif
      break;
    case DAP_ID_PRODUCT:
#ifdef DAP_PRODUCT
memcpy(info DAP_Product sizeof(DAP_Product));
length = sizeof(DAP_Product);
#endif
      break;
    case DAP_ID_SER_NUM:
#ifdef DAP_SER_NUM
memcpy(info DAP_SerNum sizeof(DAP_SerNum));
length = sizeof(DAP_SerNum);
#endif
      break;
    case DAP_ID_FW_VER:
      length = (uint8_t)sizeof(DAP_FW_Ver);
      memcpy(info DAP_FW_Ver length);
      break;
    case DAP_ID_DEVICE_VENDOR:
#if TARGET_DEVICE_FIXED
      length = (uint8_t)sizeof(TargetDeviceVendor);
      memcpy(info TargetDeviceVendor length);
#endif
      break;
    case D

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----

     文件    9712640  2020-05-21 16:09  CMSIS-DAP\HDK\CMSIS-DAP-V2.0\cmsis-dap-pcb.PcbDoc

     文件     308246  2020-05-26 13:08  CMSIS-DAP\HDK\CMSIS-DAP-V2.0\cmsis-dap-sch.pdf

     文件     242176  2020-05-21 23:12  CMSIS-DAP\HDK\CMSIS-DAP-V2.0\cmsis-dap-sch.SchDoc

     文件      38140  2020-05-21 23:36  CMSIS-DAP\HDK\CMSIS-DAP-V2.0\Project.PrjPcb

     文件        149  2020-05-21 11:25  CMSIS-DAP\HDK\版本问题记录.txt

     文件         66  2019-06-09 15:49  CMSIS-DAP\SDK\STM32F103C8T6_CMSIS-DAP_SWO-master\.gitattributes

     文件        430  2019-06-09 15:49  CMSIS-DAP\SDK\STM32F103C8T6_CMSIS-DAP_SWO-master\.gitignore

     文件     302598  2020-05-26 13:14  CMSIS-DAP\SDK\STM32F103C8T6_CMSIS-DAP_SWO-master\build\dap.crf

     文件       1336  2020-05-26 13:14  CMSIS-DAP\SDK\STM32F103C8T6_CMSIS-DAP_SWO-master\build\dap.d

     文件     366844  2020-05-26 13:14  CMSIS-DAP\SDK\STM32F103C8T6_CMSIS-DAP_SWO-master\build\dap.o

     文件     270734  2020-05-21 10:39  CMSIS-DAP\SDK\STM32F103C8T6_CMSIS-DAP_SWO-master\build\dma_stm32f10x.crf

     文件       1343  2020-05-21 10:39  CMSIS-DAP\SDK\STM32F103C8T6_CMSIS-DAP_SWO-master\build\dma_stm32f10x.d

     文件     320144  2020-05-21 10:39  CMSIS-DAP\SDK\STM32F103C8T6_CMSIS-DAP_SWO-master\build\dma_stm32f10x.o

     文件     900164  2020-05-26 13:14  CMSIS-DAP\SDK\STM32F103C8T6_CMSIS-DAP_SWO-master\build\F103-DAP-SWO-CDC-BLUEPILL.axf

     文件       1247  2020-05-26 13:14  CMSIS-DAP\SDK\STM32F103C8T6_CMSIS-DAP_SWO-master\build\F103-DAP-SWO-CDC-BLUEPILL.build_log.htm

     文件      90591  2020-05-26 13:14  CMSIS-DAP\SDK\STM32F103C8T6_CMSIS-DAP_SWO-master\build\F103-DAP-SWO-CDC-BLUEPILL.hex

     文件     155976  2020-05-26 13:14  CMSIS-DAP\SDK\STM32F103C8T6_CMSIS-DAP_SWO-master\build\F103-DAP-SWO-CDC-BLUEPILL.htm

     文件        879  2020-05-26 13:14  CMSIS-DAP\SDK\STM32F103C8T6_CMSIS-DAP_SWO-master\build\F103-DAP-SWO-CDC-BLUEPILL.lnp

     文件     232963  2020-05-26 13:14  CMSIS-DAP\SDK\STM32F103C8T6_CMSIS-DAP_SWO-master\build\F103-DAP-SWO-CDC-BLUEPILL.map

     文件     272299  2020-05-21 10:39  CMSIS-DAP\SDK\STM32F103C8T6_CMSIS-DAP_SWO-master\build\gpio_stm32f10x.crf

     文件       1363  2020-05-21 10:39  CMSIS-DAP\SDK\STM32F103C8T6_CMSIS-DAP_SWO-master\build\gpio_stm32f10x.d

     文件     300596  2020-05-21 10:39  CMSIS-DAP\SDK\STM32F103C8T6_CMSIS-DAP_SWO-master\build\gpio_stm32f10x.o

     文件     295526  2020-05-26 13:14  CMSIS-DAP\SDK\STM32F103C8T6_CMSIS-DAP_SWO-master\build\jtag_dp.crf

     文件       1368  2020-05-26 13:14  CMSIS-DAP\SDK\STM32F103C8T6_CMSIS-DAP_SWO-master\build\jtag_dp.d

     文件     336384  2020-05-26 13:14  CMSIS-DAP\SDK\STM32F103C8T6_CMSIS-DAP_SWO-master\build\jtag_dp.o

     文件     278636  2020-05-26 13:14  CMSIS-DAP\SDK\STM32F103C8T6_CMSIS-DAP_SWO-master\build\led.crf

     文件       1196  2020-05-26 13:14  CMSIS-DAP\SDK\STM32F103C8T6_CMSIS-DAP_SWO-master\build\led.d

     文件     314568  2020-05-26 13:14  CMSIS-DAP\SDK\STM32F103C8T6_CMSIS-DAP_SWO-master\build\led.o

     文件     386025  2020-05-26 13:14  CMSIS-DAP\SDK\STM32F103C8T6_CMSIS-DAP_SWO-master\build\main.crf

     文件       3129  2020-05-26 13:14  CMSIS-DAP\SDK\STM32F103C8T6_CMSIS-DAP_SWO-master\build\main.d

............此处省略183个文件信息

评论

共有 条评论

相关资源