• Home
  • History
  • Annotate
Name Date Size #Lines LOC

..--

boards/04-Jan-2025-5950

remote/04-Jan-2025-190143

src/04-Jan-2025-12182

CMakeLists.txtD04-Jan-2025774 2418

Kconfig.sysbuildD04-Jan-2025330 129

README.rstD04-Jan-20254.3 KiB154115

prj.confD04-Jan-2025193 98

sample.yamlD04-Jan-2025331 1615

sysbuild.cmakeD04-Jan-2025402 1613

README.rst

1.. zephyr:code-sample:: rpmsg-service
2   :name: RPMsg service
3   :relevant-api: rpmsg_service_api
4
5   Send messages between cores using RPMsg service.
6
7Overview
8********
9
10RPMsg Service is an abstraction created over OpenAMP that makes initialization
11and endpoints creation process easier.
12This application demonstrates how to use RPMsg Service in Zephyr. It is designed
13to demonstrate how to integrate RPMsg Service with Zephyr both from a build
14perspective and code. Note that the remote and primary image core images can be
15flashed independently, but sysbuild must be used in order to flash them in one
16step.
17
18Building the application for nrf5340dk/nrf5340/cpuapp
19*****************************************************
20
21.. zephyr-app-commands::
22   :zephyr-app: samples/subsys/ipc/rpmsg_service
23   :board: nrf5340dk/nrf5340/cpuapp
24   :goals: debug
25
26Building the application for mps2/an521/cpu0
27********************************************
28
29.. zephyr-app-commands::
30   :zephyr-app: samples/subsys/ipc/rpmsg_service
31   :board: mps2/an521/cpu0
32   :goals: debug
33
34Building the application for v2m_musca_b1/musca_b1
35**************************************************
36
37.. zephyr-app-commands::
38   :zephyr-app: samples/subsys/ipc/rpmsg_service
39   :board: v2m_musca_b1/musca_b1
40   :goals: debug
41
42Open a serial terminal (minicom, putty, etc.) and connect the board with the
43following settings:
44
45- Speed: 115200
46- Data: 8 bits
47- Parity: None
48- Stop bits: 1
49
50Reset the board and the following message will appear on the corresponding
51serial port, one is master another is remote:
52
53.. code-block:: console
54
55   **** Booting Zephyr OS build zephyr-v1.14.0-2064-g888fc98fddaa ****
56   Starting application thread!
57
58   RPMsg Service [master] demo started
59   Master core received a message: 1
60   Master core received a message: 3
61   Master core received a message: 5
62   ...
63   Master core received a message: 99
64   RPMsg Service demo ended.
65
66
67.. code-block:: console
68
69   **** Booting Zephyr OS build zephyr-v1.14.0-2064-g888fc98fddaa ****
70   Starting application thread!
71
72   RPMsg Service [remote] demo started
73   Remote core received a message: 0
74   Remote core received a message: 2
75   Remote core received a message: 4
76   ...
77   Remote core received a message: 98
78   RPMsg Service demo ended.
79
80Building the application for bl5340_dvk/nrf5340/cpuapp
81******************************************************
82
83.. zephyr-app-commands::
84   :zephyr-app: samples/subsys/ipc/rpmsg_service
85   :board: bl5340_dvk/nrf5340/cpuapp
86   :goals: debug
87
88.. zephyr-app-commands::
89   :zephyr-app: samples/subsys/ipc/rpmsg_service
90   :board: bl5340_dvk/nrf5340/cpunet
91   :goals: debug
92
93Open a serial terminal (for example Minicom or PuTTY) and connect to the board
94with the following settings on both serial ports:
95
96- Speed: 115200
97- Data: 8 bits
98- Parity: None
99- Stop bits: 1
100
101When you reset the development kit after having flashed both the application
102and network core images, the following messages (one for master and one for
103remote) will appear on the corresponding serial ports:
104
105.. code-block:: console
106
107   *** Booting Zephyr OS build v2.7.0-rc1-103-ge19875c88916  ***
108   Starting application thread!
109
110   RPMsg Service [master] demo started
111   Master core received a message: 1
112   Master core received a message: 3
113   Master core received a message: 5
114   ...
115   Master core received a message: 99
116   RPMsg Service demo ended.
117
118
119.. code-block:: console
120
121   *** Booting Zephyr OS build v2.7.0-rc1-103-ge19875c88916  ***
122   Starting application thread!
123
124   RPMsg Service [remote] demo started
125   Remote core received a message: 0
126   Remote core received a message: 2
127   Remote core received a message: 4
128   ...
129   Remote core received a message: 98
130   RPMsg Service demo ended.
131
132Building the application for stm32h747i_disco/stm32h7xx
133*******************************************************
134
135.. zephyr-app-commands::
136   :zephyr-app: samples/subsys/ipc/rpmsg_service
137   :board: stm32h747i_disco/stm32h7xx/m7
138   :goals: debug
139
140The serial output should now look like this:
141
142.. code-block:: console
143
144    *** Booting Zephyr OS build 15736b7415be ***
145    Starting application thread!
146
147    RPMsg Service [master] demo started
148    Master core received a message: 1
149    Master core received a message: 3
150    Master core received a message: 5
151    ...
152    Master core received a message: 99
153    RPMsg Service demo ended.
154