@@ -47,8 +47,7 @@ Board features:
47
47
:height: 405px
48
48
:alt: PhyBOARD Pollux
49
49
50
- More information about the board can be found at the
51
- `PHYTEC website `_.
50
+ More information about the board can be found at the `PHYTEC website `_.
52
51
53
52
Supported Features
54
53
==================
@@ -78,10 +77,8 @@ The default configuration can be found in the defconfig file:
78
77
:zephyr_file: `boards/phytec/mimx8mp_phyboard_pollux/mimx8mp_phyboard_pollux_mimx8ml8_m7_defconfig `.
79
78
80
79
It's recommended to disable peripherals used by the M7-Core on the host running
81
- on the Linux host.
82
-
83
- Other hardware features are not currently supported with Zephyr on the
84
- M7-Core.
80
+ on the Linux host. Other hardware features are not currently supported with
81
+ Zephyr on the M7-Core.
85
82
86
83
Connections and IOs
87
84
===================
@@ -102,30 +99,23 @@ UART
102
99
+-----------------+----------+----------------------------+
103
100
104
101
.. note ::
105
- Please note, that the, to UART3 connected, Wifi/BLE Module isn't working with
106
- Zephyr yet. UART3 can also be used through pin 31(RX) and 33(TX) of the
107
- X6 Connector.
102
+ The WiFi/BLE Module connected to UART3 isn't working with Zephyr yet. UART3
103
+ can also be used through pin 31(RX) and 33(TX) of connector X6.
108
104
109
105
GPIO
110
106
----
111
107
112
108
The pinmuxing for the GPIOs is the standard pinmuxing of the mimx8mp devicetree
113
- created by NXP. You can find it here:
114
-
115
- :zephyr_file: `dts/arm/nxp/nxp_imx8ml_m7.dtsi `.
116
-
117
- The Pinout of the PhyBOARD Polis can be found here:
118
-
119
- `PHYTEC website `_
109
+ created by NXP and can be found at
110
+ :zephyr_file: `dts/arm/nxp/nxp_imx8ml_m7.dtsi `. The Pinout of the PhyBOARD Polis
111
+ can be found at the `PHYTEC website `_.
120
112
121
113
Programming and Debugging
122
114
*************************
123
115
124
116
The i.MX8MP does not have a separate flash for the M7-Core. Because of this
125
117
the A53-Core has to load the program for the M7-Core to the right memory
126
118
address, set the PC and start the processor.
127
- This can only by done with u-boot at the moment. We are working on our BSP to
128
- enable remoteproc support.
129
119
130
120
The M7 can use up to 3 different RAMs (currently, only two configurations are
131
121
supported: ITCM and DDR). These are the memory mapping for A53 and M7:
@@ -151,20 +141,17 @@ At compilation time you have to choose which memory region will be used. This
151
141
configuration is done in the devicetree and the defconfig / the config of your
152
142
program.
153
143
154
- **By default Zephyr will use the TCM memory region. ** You can configure it like
155
- this for the DDR region:
156
-
157
- In the devicetree overwrite the following nodes like this:
144
+ **By default Zephyr will use the TCM memory region. ** You can configure it
145
+ to use the DDR region. In the devicetree overwrite you can select both options.
158
146
159
147
.. code-block :: DTS
160
148
161
149
chosen {
162
150
/* TCM */
163
151
zephyr,flash = &itcm;
164
- zephyr,sram = &dtcm;
152
+ zephyr,sram = &dtcm;
165
153
};
166
154
167
- change it to
168
155
169
156
.. code-block :: DTS
170
157
@@ -175,93 +162,93 @@ change it to
175
162
};
176
163
177
164
178
- In your prj.conf overwrite the configuration like this for the **DDR ** memory
179
- region:
165
+ And in the prj.conf the configuration to the **DDR ** memory region:
180
166
181
167
.. code-block :: cfg
182
168
183
169
CONFIG_CODE_DDR =y
184
170
CONFIG_CODE_ITCM =n
185
171
172
+ Connecting to the Serial Console
173
+ ================================
186
174
187
- Starting the M7-Core via U-Boot
188
- ===============================
189
-
190
- Load the compiled zephyr.bin to memory address 0x4800000.
191
- This should output something like this:
175
+ A serial console for both the application CPU and the Cortex M7 coprocessor are
176
+ available via the onboard dual USB-to-UART converter. If you use Linux, create a
177
+ udev rule (as ``root ``) to fix a permission issue when not using root for
178
+ flashing.
192
179
193
180
.. code-block :: console
194
181
195
- u-boot=> tftp 0x48000000 192.168.3.10:zephyr.bin
196
- Using ethernet@30be0000 device
197
- TFTP from server 192.168.3.10; our IP address is 192.168.3.11
198
- Filename 'zephyr.bin'.
199
- Load address: 0x48000000
200
- Loading: ##
201
- 2 KiB/s
202
- done
203
- Bytes transferred = 27240 (6a68 hex)
182
+ # echo 'ATTR{idProduct}=="0a70", ATTR{idVendor}=="10c4", MODE="0666", GROUP="plugdev"' > /etc/udev/rules.d/50-usb-uart.rules
204
183
205
- Because it's not possible to load directly to the TCM memory area you have to
206
- copy the binaries. The last argument given is the size of the file in bytes,
207
- you can copy it from the output of the last command.
184
+ Reload the rules and replug the device.
208
185
209
186
.. code-block :: console
210
187
211
- u-boot=> cp.b 0x48000000 0x7e0000 27240
188
+ $ sudo udevadm control --reload-rules
212
189
213
- And finaly starting the M7-Core at the right memory address:
190
+ Finally, unplug and plug the board again for the rules to take effect.
191
+
192
+ Connect to the console via your favorite terminal program. For example:
214
193
215
194
.. code-block :: console
216
195
217
- u-boot=> bootaux 0x7e0000
218
- ## Starting auxiliary core stack = 0x20003A58, pc = 0x1FFE1905...
196
+ $ minicom -D /dev/ttyUSB1 -b 115200
219
197
220
- Debugging
221
- =========
198
+ Flashing and Debugging via JTAG
199
+ ===============================
222
200
223
- The PhyBOARD Polis can be debugged using a JTAG Debugger.
224
- The easiest way to do that is to use a SEGGER JLink Debugger and Phytec's
225
- ``PEB-EVAL-01 `` Shield, which can be directly connected to the JLink.
226
- You can find the JLink Software package here: `JLink Software `_
201
+ The PhyBOARD-Pollux can be debugged using a JTAG or SWD debug adapter. A Segger
202
+ JLink can be connected to the compatible JTAG connector on Phytec's
203
+ ``PEB-EVAL-01 `` shield.
227
204
228
205
.. figure :: img/PEB-EVAL-01.jpg
229
206
:alt: PEB-EVAL-01
230
207
:width: 350
231
208
232
209
PEB-EVAL-01
233
210
234
- To debug efficiently you have to use multiple terminals:
235
-
236
- After connecting everything and building with west use this command while in
237
- the directory of the program you build earlier to start a debug server:
211
+ Before flashing or debugging via a JTAG debug adapter,
212
+ the M7 core has to be switched on:
238
213
239
214
.. code-block :: console
240
215
241
- host$ west debugserver
216
+ u-boot=> bootaux 0x7e0000
242
217
243
- West automatically connects via the JLink to the Target and keeps open a
244
- debug server.
218
+ Here is an example for the :ref: `hello_world ` application:
245
219
246
- Use another terminal, start gdb, connect to target and load Zephyr on the
247
- target:
220
+ .. zephyr-app-commands ::
221
+ :zephyr-app: samples/hello_world
222
+ :board: mimx8mp_phyboard_pollux/mimx8ml8/m7
223
+ :goals: flash
224
+
225
+ The console should now show the output of the application:
248
226
249
227
.. code-block :: console
250
228
251
- host$ gdb-multiarch build/zephyr/zephyr.elf -tui
252
- (gdb) targ rem :2331
253
- Remote debugging using :2331
254
- 0x1ffe0008 in _vector_table ()
255
- (gdb) mon halt
256
- (gdb) mon reset
257
- (gdb) c
258
- Continuing.
229
+ *** Booting Zephyr OS build v3.7.0 ***
230
+ Hello World! mimx8mp_phyboard_pollux/mimx8ml8/m7
231
+
232
+ Starting a debug session is similar to flashing:
259
233
260
- The program can be debugged using standard gdb techniques.
234
+ .. zephyr-app-commands ::
235
+ :zephyr-app: samples/hello_world
236
+ :board: mimx8mp_phyboard_pollux/mimx8ml8/m7
237
+ :goals: debug
238
+
239
+ Starting the M7-Core from U-Boot and Linux
240
+ ==========================================
241
+
242
+ Loading binaries and starting the M7-Core is supported from Linux via remoteproc
243
+ or from U-boot by directly copying the firmware binary. Please check the
244
+ `phyCORE-i.MX 8M Plus BSP Manual `_ for more information.
261
245
262
246
References
263
247
==========
264
248
249
+ - `i.MX 8M Plus Applications Processor Reference Manual `_
250
+ - `phyCORE-i.MX 8M Plus BSP Manual `_
251
+
265
252
.. _PHYTEC website :
266
253
https://www.phytec.de/produkte/single-board-computer/phyboard-pollux/
267
254
@@ -270,3 +257,6 @@ References
270
257
271
258
.. _JLink Software :
272
259
https://www.segger.com/downloads/jlink/
260
+
261
+ .. _phyCORE-i.MX 8M Plus BSP Manual :
262
+ https://phytec.github.io/doc-bsp-yocto/bsp/imx8/imx8mp/imx8mp.html
0 commit comments