Part 1
요약·해설
SLIP, Ethernet, SLIRP, FVP, native_sim, USB, multi-instance, IEEE 802.15.4 방식의 조건과 제약을 정리합니다.
Emulation
QEMU · FVP
Native
native_sim · USB
Multi-node
Instances · 802.15.4
Part 2
접을 수 있는 영어 원문 전체
영어 원문 전체 펼치기
원문 SHA-256
FFCDC59418282CE09188AE7CFC36B5F05480CE0DAD3C4920F3C0A27CE9C2716E
.. _networking_with_host:
Networking with the host system
###############################
.. toctree::
:maxdepth: 1
:hidden:
native_sim_setup.rst
qemu_eth_setup.rst
qemu_setup.rst
usbnet_setup.rst
qemu_user_setup.rst
networking_with_multiple_instances.rst
qemu_802154_setup.rst
armfvp_user_networking_setup.rst
While developing networking software, it is usually necessary to connect and
exchange data with the host system like a Linux desktop computer.
Depending on what board is used for development, the following options are
possible:
* QEMU using SLIP (Serial Line Internet Protocol).
* Here IP packets are exchanged between Zephyr and the host system via serial
port. This is the legacy way of transferring data. It is also quite slow so
use it only when necessary. See :ref:`networking_with_qemu` for details.
* QEMU using built-in Ethernet driver.
* Here IP packets are exchanged between Zephyr and the host system via QEMU's
built-in Ethernet driver. Not all QEMU boards support built-in Ethernet so
in some cases, you might need to use the SLIP method for host connectivity.
See :ref:`networking_with_eth_qemu` for details.
* QEMU using SLIRP (Qemu User Networking).
* QEMU User Networking is implemented using "slirp", which provides a full TCP/IP
stack within QEMU and uses that stack to implement a virtual NAT'd network. As
this support is built into QEMU, it can be used with any model and requires no
admin privileges on the host machine, unlike TAP. However, it has several
limitations including performance which makes it less valuable for practical
purposes. See :ref:`networking_with_user_qemu` for details.
* Arm FVP (User Mode Networking).
* User mode networking emulates a built-in IP router and DHCP server, and
routes TCP and UDP traffic between the guest and host. It uses the user mode
socket layer of the host to communicate with other hosts. This allows
the use of a significant number of IP network services without requiring
administrative privileges, or the installation of a separate driver on
the host on which the model is running. See :ref:`networking_with_armfvp`
for details.
* native_sim board.
* The Zephyr instance can be executed as a user space process in the host
system. This is the most convenient way to debug the Zephyr system as one
can attach host debugger directly to the running Zephyr instance. This
requires that there is an adaptation driver in Zephyr for interfacing
with the host system. Two possible network drivers can be used for this
purpose, a TAP virtual Ethernet driver and an offloaded sockets driver.
See :ref:`networking_with_native_sim` for details.
* USB device networking.
* Here, the Zephyr instance is run on a real board and the connectivity to
the host system is done via USB.
See :ref:`usb_device_networking_setup` for details.
* Connecting multiple Zephyr instances together.
* If you have multiple Zephyr instances, either QEMU or native_sim ones,
and want to create a connection between them, see
:ref:`networking_with_multiple_instances` for details.
* Simulating IEEE 802.15.4 network between two QEMUs.
* Here, two Zephyr instances are running and there is IEEE 802.15.4 link layer
run over an UART between them.
See :ref:`networking_with_ieee802154_qemu` for details.
Part 3
한국어 전문 번역
Host system과 Networking
Networking software를 개발할 때는 보통 Linux desktop computer 같은 host system과 연결해 data를 교환해야 합니다. Development board에 따라 다음 방법을 사용할 수 있습니다.
- SLIP를 사용하는 QEMU.
- Serial Line Internet Protocol로 Zephyr와 host system 사이에 IP packet을 교환합니다. 오래된 방식이며 상당히 느리므로 꼭 필요할 때만 사용합니다.
- Built-in Ethernet driver를 사용하는 QEMU.
- QEMU built-in Ethernet driver를 통해 IP packet을 교환합니다. 모든 QEMU board가 지원하지는 않으므로 일부 board에서는 SLIP가 필요합니다.
- SLIRP(QEMU User Networking)를 사용하는 QEMU.
- QEMU 내부의 full TCP/IP stack인 slirp로 virtual NAT network를 만듭니다. 모든 model에서 사용할 수 있고 TAP과 달리 host admin privilege가 필요하지 않지만 performance 등 여러 한계가 있습니다.
- Arm FVP User Mode Networking.
- Built-in IP router와 DHCP server를 emulate하고 guest와 host 사이의 TCP·UDP traffic을 route합니다. Host user-mode socket layer를 사용하므로 admin privilege나 별도 driver 설치 없이 많은 IP service를 사용할 수 있습니다.
- native_sim board.
- Zephyr instance를 host의 userspace process로 실행하고 host debugger를 직접 attach할 수 있습니다. Host 연동 adaptation driver가 필요하며 TAP virtual Ethernet driver 또는 offloaded socket driver를 사용할 수 있습니다.
- USB device networking.
- 실제 board에서 Zephyr instance를 실행하고 USB로 host system에 연결합니다.
- 여러 Zephyr instance 연결.
- QEMU 또는 native_sim instance 여러 개를 서로 연결할 수 있습니다.
- 두 QEMU 사이의 IEEE 802.15.4 network simulation.
- Zephyr instance 두 개를 실행하고 UART 위에서 IEEE 802.15.4 link layer를 구동합니다.
Source
출처
영어 원문에는 문단, 문서 지시문, 표, 코드, 코드 심벌, 경로를 그대로 보존했습니다.