Part 1
요약·해설
독립 flash 조건, 5개 build/debug block, master·remote exact log를 보존합니다.
OpenAMP
Sysbuild required
Master odd · Remote even
Part 2
접을 수 있는 영어 원문 전체
영어 원문 전체 펼치기
E81266D2F42B8A32F9FC92CC9157647C5F34626C61C978E52375F86C21AA4019
.. zephyr:code-sample:: openamp
:name: OpenAMP
:relevant-api: ipm_interface
Send messages between two cores using OpenAMP.
Overview
********
This application demonstrates how to use OpenAMP with Zephyr. It is designed to
demonstrate how to integrate OpenAMP with Zephyr both from a build perspective
and code. Note that the remote and primary core images can be flashed
independently, but sysbuild must be used in order to build the images.
Building the application for lpcxpresso54114_m4
***********************************************
.. zephyr-app-commands::
:zephyr-app: samples/subsys/ipc/openamp
:board: lpcxpresso54114/lpc54114/m4
:goals: debug
:west-args: --sysbuild
Building the application for lpcxpresso55s69/lpc55s69/cpu0
**********************************************************
.. zephyr-app-commands::
:zephyr-app: samples/subsys/ipc/openamp
:board: lpcxpresso55s69/lpc55s69/cpu0
:goals: debug
:west-args: --sysbuild
Building the application for mps2/an521/cpu0
********************************************
.. zephyr-app-commands::
:zephyr-app: samples/subsys/ipc/openamp
:board: mps2/an521/cpu0
:goals: debug
:west-args: --sysbuild
Building the application for v2m_musca_b1/musca_b1
**************************************************
.. zephyr-app-commands::
:zephyr-app: samples/subsys/ipc/openamp
:board: v2m_musca_b1/musca_b1
:goals: debug
:west-args: --sysbuild
Building the application for mimxrt1170_evk_cm7
***********************************************
.. zephyr-app-commands::
:zephyr-app: samples/subsys/ipc/openamp
:board: mimxrt1170_evk_cm7
:goals: debug
:west-args: --sysbuild
Open a serial terminal (minicom, putty, etc.) and connect the board with the
following settings:
- Speed: 115200
- Data: 8 bits
- Parity: None
- Stop bits: 1
Reset the board and the following message will appear on the corresponding
serial port, one is master another is remote:
.. code-block:: console
**** Booting Zephyr OS build zephyr-v1.14.0-2064-g888fc98fddaa ****
Starting application thread!
OpenAMP[master] demo started
Master core received a message: 1
Master core received a message: 3
Master core received a message: 5
...
Master core received a message: 99
OpenAMP demo ended.
.. code-block:: console
**** Booting Zephyr OS build zephyr-v1.14.0-2064-g888fc98fddaa ****
Starting application thread!
OpenAMP[remote] demo started
Remote core received a message: 0
Remote core received a message: 2
Remote core received a message: 4
...
Remote core received a message: 98
OpenAMP demo ended.
Part 3
한국어 전문 번역
개요
Zephyr에서 OpenAMP를 사용해 두 core 사이에 message를 보내는 application입니다. Remote core image와 primary core image는 서로 독립적으로 flash할 수 있지만, 두 image를 build할 때는 반드시 sysbuild를 사용해야 합니다.
lpcxpresso54114/lpc54114/m4용 빌드
# From the root of the zephyr repository
west build -b lpcxpresso54114/lpc54114/m4 --sysbuild samples/subsys/ipc/openamp
west debug
lpcxpresso55s69/lpc55s69/cpu0용 빌드
# From the root of the zephyr repository
west build -b lpcxpresso55s69/lpc55s69/cpu0 --sysbuild samples/subsys/ipc/openamp
west debug
mps2/an521/cpu0용 빌드
# From the root of the zephyr repository
west build -b mps2/an521/cpu0 --sysbuild samples/subsys/ipc/openamp
west debug
v2m_musca_b1/musca_b1용 빌드
# From the root of the zephyr repository
west build -b v2m_musca_b1/musca_b1 --sysbuild samples/subsys/ipc/openamp
west debug
mimxrt1170_evk_cm7용 빌드
# From the root of the zephyr repository
west build -b mimxrt1170_evk_cm7 --sysbuild samples/subsys/ipc/openamp
west debug
각 target은 --sysbuild로 build하고 west debug를 실행합니다. Serial terminal은 115200 baud, 8 data bits, parity None, 1 stop bit로 설정합니다.
Reset 뒤 master와 remote의 serial port에 log가 각각 나타납니다. Master core는 remote가 보낸 1부터 99까지의 홀수 message를 받고, remote core는 master가 보낸 0부터 98까지의 짝수 message를 받습니다.
**** Booting Zephyr OS build zephyr-v1.14.0-2064-g888fc98fddaa ****
Starting application thread!
OpenAMP[master] demo started
Master core received a message: 1
Master core received a message: 3
Master core received a message: 5
...
Master core received a message: 99
OpenAMP demo ended.
**** Booting Zephyr OS build zephyr-v1.14.0-2064-g888fc98fddaa ****
Starting application thread!
OpenAMP[remote] demo started
Remote core received a message: 0
Remote core received a message: 2
Remote core received a message: 4
...
Remote core received a message: 98
OpenAMP demo ended.
Source
출처
영어 원문에는 문단, 문서 지시문, 표, 코드, 코드 심벌, 경로를 그대로 보존했습니다.