File tree Expand file tree Collapse file tree 4 files changed +61
-0
lines changed
snippets/usbip-native-sim Expand file tree Collapse file tree 4 files changed +61
-0
lines changed Original file line number Diff line number Diff line change 1+ .. _snippet-usbip-native-sim :
2+
3+ USB/IP on Native Simulator Snippet (usbip-native-sim)
4+ #####################################################
5+
6+ .. code-block :: console
7+
8+ west build -S usbip-native-sim [...]
9+
10+ Overview
11+ ********
12+
13+ This snippet allows to configure USB device samples with USB/IP support on a
14+ native simulator. When building samples with this snippet, you need to provide
15+ samples DTC overlays using the EXTRA_DTC_OVERLAY_FILE argument.
16+
17+ This snippet is experimental, the behavior may change without notice.
Original file line number Diff line number Diff line change 1+ name : usbip-native-sim
2+ append :
3+ EXTRA_CONF_FILE : usbip-native-sim.conf
4+ EXTRA_DTC_OVERLAY_FILE : usbip-native-sim.overlay
Original file line number Diff line number Diff line change 1+ CONFIG_NETWORKING=y
2+ CONFIG_NET_IPV4=y
3+ CONFIG_NET_TCP=y
4+ CONFIG_NET_SOCKETS=y
5+
6+ # Network address config
7+ CONFIG_NET_CONFIG_SETTINGS=y
8+ CONFIG_NET_CONFIG_NEED_IPV4=y
9+ CONFIG_NET_CONFIG_MY_IPV4_ADDR="192.0.2.1"
10+ CONFIG_NET_CONFIG_PEER_IPV4_ADDR="192.0.2.2"
11+
12+ CONFIG_NET_LOG=y
13+
14+ CONFIG_USB_HOST_STACK=y
15+ CONFIG_USBH_LOG_LEVEL_WRN=y
16+ CONFIG_UHC_DRIVER_LOG_LEVEL_WRN=y
17+ CONFIG_USBIP=y
18+ CONFIG_USBIP_LOG_LEVEL_WRN=y
19+ CONFIG_SYS_CLOCK_TICKS_PER_SEC=1000000
20+ CONFIG_UHC_BUF_COUNT=32
21+ CONFIG_UHC_XFER_COUNT=32
Original file line number Diff line number Diff line change 1+ /*
2+ * Copyright (c) 2025 Nordic Semiconductor ASA
3+ *
4+ * SPDX-License-Identifier: Apache-2.0
5+ */
6+
7+ /delete-node/ &zephyr_udc0;
8+
9+ / {
10+ zephyr_uhc0: uhc_vrt0 {
11+ compatible = "zephyr,uhc-virtual";
12+
13+ zephyr_udc0: udc_vrt0 {
14+ compatible = "zephyr,udc-virtual";
15+ num-bidir-endpoints = <8>;
16+ maximum-speed = "high-speed";
17+ };
18+ };
19+ };
You can’t perform that action at this time.
0 commit comments