File tree Expand file tree Collapse file tree 8 files changed +280
-346
lines changed Expand file tree Collapse file tree 8 files changed +280
-346
lines changed Original file line number Diff line number Diff line change @@ -5,5 +5,6 @@ cmake_minimum_required(VERSION 3.20.0)
5
5
find_package (Zephyr REQUIRED HINTS $ENV{ZEPHYR_BASE} )
6
6
project (dap )
7
7
8
+ include (${ZEPHYR_BASE} /samples/subsys/usb/common/common.cmake )
8
9
FILE (GLOB app_sources src/*.c )
9
10
target_sources (app PRIVATE ${app_sources} )
Original file line number Diff line number Diff line change
1
+ # Copyright (c) 2023 Nordic Semiconductor ASA
2
+ # SPDX-License-Identifier: Apache-2.0
3
+
4
+ # Source common USB sample options used to initialize new experimental USB
5
+ # device stack. The scope of these options is limited to USB samples in project
6
+ # tree, you cannot use them in your own application.
7
+ source "samples/subsys/usb/common/Kconfig.sample_usbd"
8
+
9
+ source "Kconfig.zephyr"
Original file line number Diff line number Diff line change 7
7
********
8
8
9
9
This sample app demonstrates use of a SWDP interface driver and CMSIS DAP
10
- controller through USB Bulk interface .
10
+ controller through DAP USB backend .
11
11
12
12
Requirements
13
13
************
@@ -21,8 +21,6 @@ e.g. if the SWD connections are multiplexed.
21
21
Building and Running
22
22
********************
23
23
24
- In order for our debug adapter to be recognized by pyOCD we need to change
25
- Zephyr's VID/PID to IDs known to pyOCD, this is up to the user.
26
24
The following commands build and flash DAP sample.
27
25
28
26
.. zephyr-app-commands ::
Original file line number Diff line number Diff line change
1
+ CONFIG_USB_DEVICE_STACK_NEXT=y
2
+ CONFIG_SAMPLE_USBD_PRODUCT="Zephyr CMSIS-DAP"
3
+ CONFIG_SAMPLE_USBD_PID=0x0204
4
+ CONFIG_SAMPLE_USBD_20_EXTENSION_DESC=y
5
+
1
6
CONFIG_STDOUT_CONSOLE=y
2
- CONFIG_USB_DEVICE_STACK=y
3
- CONFIG_USB_DEVICE_BOS=y
4
7
CONFIG_SERIAL=y
5
- CONFIG_USB_DEVICE_PRODUCT="Zephyr CMSIS-DAP"
6
- CONFIG_USB_DEVICE_PID=0x0204
7
8
CONFIG_UART_INTERRUPT_DRIVEN=y
8
9
CONFIG_UART_LINE_CTRL=y
9
- CONFIG_USB_DEVICE_INITIALIZE_AT_BOOT=n
10
10
11
11
CONFIG_LOG=y
12
+ CONFIG_LOG_DEFAULT_LEVEL=2
12
13
13
- CONFIG_USB_DRIVER_LOG_LEVEL_INF=y
14
- CONFIG_USB_DEVICE_LOG_LEVEL_INF=y
15
14
CONFIG_DAP_LOG_LEVEL_INF=y
16
15
CONFIG_DP_DRIVER_LOG_LEVEL_INF=y
17
16
CONFIG_DAP=y
17
+ CONFIG_DAP_BACKEND_USB=y
18
18
CONFIG_GPIO=y
19
- CONFIG_NET_BUF=y
Original file line number Diff line number Diff line change 5
5
build_only : true
6
6
depends_on :
7
7
- arduino_gpio
8
- - usb_device
8
+ - usbd
9
9
platform_allow :
10
10
- nrf52840dk/nrf52840
11
11
- frdm_k64f
You can’t perform that action at this time.
0 commit comments