You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: softperipheral/doc/sEMMC/semmc_nrf54H_series_porting_v0_1_0.rst
+34-34Lines changed: 34 additions & 34 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -40,12 +40,13 @@ This structure shows the relevant files and directories in the `sdk-nrfxlib`_ re
40
40
└── nrf_semmc.c
41
41
42
42
.. note::
43
-
The main interface for sEMMC is the :file:`nrf_semmc.h` file. It contains a list of supported and tested EMMC commands.
43
+
The main interface for sEMMC is in the :file:`nrf_semmc.h` file.
44
+
It contains a list of supported and tested EMMC commands.
44
45
45
46
Header files
46
47
============
47
48
48
-
For an sEMMC application to function correctly, it requires specific header files used by the driver code.
49
+
sEMMC application requires specific header files used by the driver code.
49
50
You must include paths to these files in the build environment's list of include paths.
50
51
The following list is a detailed breakdown of the necessary paths:
51
52
@@ -55,7 +56,7 @@ The following list is a detailed breakdown of the necessary paths:
55
56
* :file:`softperipheral/sEMMC/include` - sEMMC register interface and driver header
56
57
* :file:`softperipheral/sEMMC/include/nrf54h` - The sEMMC firmware for the Fast Lightweight Perpipheral Processor (FLPR)
57
58
58
-
To override the configuration enums in :file:`nrf_config_semmc.h`, you can use the ``zephyr_compile_definitions`` macro in your application:
59
+
To override the configuration enums in :file:`nrf_config_semmc.h`, use the ``zephyr_compile_definitions`` macro in your application:
59
60
60
61
.. code-block:: c
61
62
@@ -65,18 +66,16 @@ To override the configuration enums in :file:`nrf_config_semmc.h`, you can use t
65
66
Compiling source files
66
67
======================
67
68
68
-
For an sEMMC application to function properly, you must compile the driver implementation from the source file :file:`nrf_semmc.c`.
69
+
For a sEMMC application to function properly, you must compile the driver implementation from the source file :file:`nrf_semmc.c`.
69
70
70
71
Application core and FLPR configuration
71
72
***************************************
72
73
73
74
You must adjust the settings for the nRF54H Series SoC to run at highest base clock frequency.
74
75
75
-
To work with any of the following settings, ensure you have completed the following:
76
-
77
-
* You have allocated memory for the data pointers used by the sEMMC driver.
78
-
The memory is independent from the one outlined in the :ref:`semmc_nrf54H_series_porting_guide_ram_configuration` subsection.
79
-
It is designated to function as shared memory for communication purposes, rather than containing the sEMMC executable code.
76
+
To work with any of the following settings, ensure you have allocated memory for the data pointers used by the sEMMC driver.
77
+
The memory is independent from the one outlined in the :ref:`semmc_nrf54H_series_porting_guide_ram_configuration` subsection.
78
+
It is designated to function as shared memory for communication purposes, rather than containing the sEMMC executable code.
80
79
81
80
Security configuration
82
81
======================
@@ -144,21 +143,22 @@ The following options are available, assuming that the FLPR core has access to t
144
143
Configuring pins
145
144
================
146
145
147
-
In some cases you might have to modify the sEMMC driver configuration.
148
-
For example, when changing pin drive strength to guarantee signal integrity for a new PCB design.
146
+
In some cases, you might have to modify the sEMMC driver configuration.
147
+
For example, you might need to change the pin drive strength to guarantee signal integrity for a new PCB design.
149
148
You must address these cases on the sEMMC application code.
150
149
151
150
.. note::
152
151
When using a custom PCB with the nRF54H20 device you might need to match the output impedance on the port you are using.
153
-
Refer to `this page <https://docs.nordicsemi.com/bundle/ncs-latest/page/nrf/app_dev/device_guides/nrf54h/ug_nrf54h20_custom_pcb.html>`__ for configuring your application for this use case.
152
+
Refer to the :ref:`ug_nrf54h20_custom_pcb` page for details.
154
153
155
154
GPIO multiplexing must be handled by setting the correct ``CTRLSEL`` value in UICR.
156
155
157
-
Any conflicting peripherals and existing memory partitions on the same port as sEMMC must be disabled in the overlay depending on your needs.
158
-
A code snippet of a devicetree overlay to give FLPR access to the pins follows below. First in the snippet, the `pinctrl` block
159
-
does GPIO configuration, setting up the pins as described in :ref:`semmc_nrf54h_series_porting_guide_gpio_config`.
160
-
The `cpuflpr_vpr` block and the following block will do the memory partitioning of VPR and the RAM used by sEMMC.
156
+
Any conflicting peripherals and existing memory partitions on the same port as sEMMC must be disabled in the devicetree overlay, depending on your requirements.
157
+
See an example code snippet of a devicetree overlay that grants FLPR access to the necessary pins.
158
+
159
+
The first part of the snippet, the ``pinctrl`` block, configures the relevant GPIOs as described in the :ref:`semmc_nrf54h_series_porting_guide_gpio_config` section.
161
160
161
+
Next, the ``cpuflpr_vpr`` block and the subsequent block handle the allocation of the VPR memory region and the RAM used by sEMMC.
162
162
163
163
.. code-block:: dts
164
164
@@ -234,7 +234,7 @@ The `cpuflpr_vpr` block and the following block will do the memory partitioning
234
234
};
235
235
};
236
236
237
-
You will need the following lines in your application to apply the pin configuration from your sEMMC board DTS overlay, as well as to initialize the soft peripheral:
237
+
You will need the following lines in your application to apply the pin configuration from your sEMMC board DTS overlay, as well as to initialize the Soft Peripheral:
238
238
239
239
.. code-block:: c
240
240
@@ -258,11 +258,10 @@ RAM configuration
258
258
The sEMMC Soft Peripheral operates from RAM.
259
259
260
260
.. note::
261
-
Position Independent Code (PIC) is supported for sEMMC.
262
-
This allows an application to determine where to load the Soft Peripheral firmware.
261
+
sEMMC supports Position Independent Code (PIC), which allows an application to determine where to load the Soft Peripheral firmware.
263
262
264
263
Your build environment must reserve the required RAM and ensure that it is readable and writable by both the application core and the FLPR core.
265
-
This table details the memory region, which should be non-cacheable:
264
+
The following table details the memory region, which should be non-cacheable:
266
265
267
266
.. list-table:: RAM Configuration Table
268
267
:widths: auto
@@ -272,32 +271,31 @@ This table details the memory region, which should be non-cacheable:
272
271
- Address offset
273
272
- Size
274
273
* - sEMMC firmware
275
-
- `SP_FIRMWARE_ADDR`
274
+
- ``SP_FIRMWARE_ADDR``
276
275
- 0x3740
277
276
* - sEMMC execution RAM
278
-
- `SP_FIRMWARE_ADDR` + 0x3740
277
+
- ``SP_FIRMWARE_ADDR`` + 0x3740
279
278
- 0x600
280
279
* - sEMMC virtual register interface
281
-
- `SP_FIRMWARE_ADDR` + 0x3D40
280
+
- ``SP_FIRMWARE_ADDR`` + 0x3D40
282
281
- 0x200
283
282
* - Context saving
284
283
- 0x2f890000
285
284
- 0x200 (but the entire block should be retained)
286
285
287
-
The build environment described in the :ref:`semmc_nrf54h_series_porting_guide_code` section must comply with these requirements.
286
+
The build environment described in the :ref:`semmc_nrf54h_series_porting_guide_code` section, you must comply with these requirements.
288
287
This includes proper settings in linker scripts, device tree specifications (DTS), and resource allocation.
289
288
290
289
Ensure that ``SP_FIRMWARE_ADDR`` is set so that it does not overlap with the context saving address.
291
-
For nRF54H Series devices the firmware has been tested with values after the context saving address. This means that
292
-
``SP_FIRMWARE_ADDR`` is a higher value than the context saving address plus the context saving offset.
293
-
294
-
``SP_FIRMWARE_ADDR`` has been tested and is considered production-ready for value ``0x2f890200``.
290
+
For nRF54H Series devices, the firmware has been tested using values that follow the context saving address.
291
+
This means, that ``SP_FIRMWARE_ADDR`` should be set higher than the context saving address plus the context saving offset.
292
+
The value ``0x2f890200`` for ``SP_FIRMWARE_ADDR`` has been tested and is considered production-ready.
295
293
296
294
297
295
IRQ connection
298
296
**************
299
297
300
-
For sEMMC to communicate with the application core, the sEMMC IRQ handler must be registered.
298
+
For sEMMC to communicate with the application core, the sEMMC IRQ handler must be registered.
301
299
The following code line registers the IRQ handler to FLPR:
302
300
303
301
.. code-block:: c
@@ -310,10 +308,12 @@ The following code line registers the IRQ handler to FLPR:
310
308
Read responses
311
309
**************
312
310
313
-
sEMMC is not able to process read data and response at the same time, as mentioned in :ref:`semmc_limitations`. There are a couple of things that can be done to mitigate this.
311
+
sEMMC cannot process read data and response at the same time (see the :ref:`semmc_limitations`).
312
+
However, you can mitigate it in the following ways:
314
313
315
-
The preferred way to do reads is to first do the read as normal and process the response with :c:var:`nrf_semmc_config_t.process_response` set to `NRF_EMMC_RESPONSE_PROC_PROCESS`.
316
-
The response is returned in :c:var:`nrf_semmc_cmd_desc_t.err`. If the response is `NRF_SEMMC_SUCCESS` the read was successful. If any other response is returned, you would
317
-
need to do a second read and ignore the response with :c:var:`nrf_semmc_config_t.process_response` set to `NRF_EMMC_RESPONSE_PROC_IGNORE`.
314
+
* The recommended way is to perform the read operation with the :c:var:`nrf_semmc_config_t.process_response` variable set to ``NRF_EMMC_RESPONSE_PROC_PROCESS``.
315
+
The response is available in the :c:var:`nrf_semmc_cmd_desc_t.err` variable.
316
+
If the response is ``NRF_SEMMC_SUCCESS``, the read was successful.
317
+
If you receive a different response, retry the read operation, this time with the :c:var:`nrf_semmc_config_t.process_response` variable set to ``NRF_EMMC_RESPONSE_PROC_IGNORE``.
318
318
319
-
The other is doing the wanted read command first with :c:var:`nrf_semmc_config_t.process_response` set to `NRF_EMMC_RESPONSE_PROC_IGNORE` followed by a CMD13 to ensure the status is correct.
319
+
* Alternatively, you can perform the read operation with the :c:var:`nrf_semmc_config_t.process_response` variable set to ``NRF_EMMC_RESPONSE_PROC_IGNORE``, and then follow it with a CMD13 command to verify if the status is correct.
Copy file name to clipboardExpand all lines: softperipheral/doc/sQSPI/sqspi_nrf54H_series_porting_v1_2_0.rst
+21-24Lines changed: 21 additions & 24 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -73,11 +73,9 @@ Application core and FLPR configuration
73
73
74
74
You must adjust the settings for the nRF54H Series SoC to run at highest base clock frequency.
75
75
76
-
To work with any of the following settings, ensure you have completed the following:
77
-
78
-
* You have allocated memory for the data pointers used by the sQSPI driver.
79
-
The memory is independent from the one outlined in the :ref:`nrf54H_series_porting_guide_ram_configuration` subsection.
80
-
It is designated to function as shared memory for communication purposes, rather than containing the sQSPI executable code.
76
+
To work with any of the following settings, ensure you have allocated memory for the data pointers used by the sQSPI driver.
77
+
The memory is independent from the one outlined in the :ref:`nrf54H_series_porting_guide_ram_configuration` subsection.
78
+
It is designated to function as shared memory for communication purposes, rather than containing the sQSPI executable code.
81
79
82
80
Security configuration
83
81
======================
@@ -195,12 +193,12 @@ The following options are available, assuming that the FLPR core has access to t
195
193
Configuring pins
196
194
================
197
195
198
-
In some cases you might have to modify the sQSPI driver configuration.
199
-
For example, when changing pin drive strength to guarantee signal integrity for a new PCB design.
196
+
In some cases, you might have to modify the sQSPI driver configuration.
197
+
For example, you might need to change the pin drive strength to guarantee signal integrity for a new PCB design.
200
198
201
199
.. note::
202
200
When using a custom PCB with the nRF54H20 device you might need to match the output impedance on the port you are using.
203
-
Refer to `this page <https://docs.nordicsemi.com/bundle/ncs-latest/page/nrf/app_dev/device_guides/nrf54h/ug_nrf54h20_custom_pcb.html>`__ for configuring your application for a custom PCB.
201
+
Refer to the :ref:`ug_nrf54h20_custom_pcb` page for details.
204
202
205
203
You must address these cases on the sQSPI application code:
206
204
@@ -213,11 +211,12 @@ GPIO multiplexing must be handled by setting the correct ``CTRLSEL`` value in UI
213
211
214
212
Additionally, the sQSPI application requires FastPad bias configuration to run at high frequency on SCLK.
215
213
216
-
Any conflicting peripherals and existing memory partitions on the same port as sQSPI must be disabled in the overlay depending on your needs.
217
-
An example code snippet of a devicetree overlay to give FLPR access to the pins on port P7 follows below. First in the snippet, the `pinctrl` block
218
-
does GPIO configuration, setting up the pins as described in :ref:`sqspi_nrf54h_series_porting_guide_gpio_config`.
219
-
The `cpuflpr_vpr` block and the following block will do the memory partitioning of VPR and the RAM used by sQSPI.
214
+
Any conflicting peripherals and existing memory partitions on the same port as sQSPI must be disabled in the devicetree overlay, depending on your requirements.
215
+
See an example code snippet of a devicetree overlay that grants FLPR access to the **P7** port.
216
+
217
+
The first part of the snippet, the ``pinctrl`` block, configures the relevant GPIOs as described in the :ref:`sqspi_nrf54h_series_porting_guide_gpio_config` section.
220
218
219
+
Next, the ``cpuflpr_vpr`` block and the subsequent block handle the allocation of the VPR memory region and the RAM used by sQSPI.
221
220
222
221
.. code-block:: dts
223
222
@@ -297,7 +296,7 @@ The `cpuflpr_vpr` block and the following block will do the memory partitioning
297
296
};
298
297
299
298
300
-
You will need the following lines in your application to apply the pin configuration from your sQSPI board DTS overlay, as well as to initialize the soft peripheral:
299
+
You will need the following lines in your application to apply the pin configuration from your sQSPI board DTS overlay, as well as to initialize the Soft Peripheral:
301
300
302
301
.. code-block:: c
303
302
@@ -321,11 +320,10 @@ RAM configuration
321
320
The sQSPI Soft Peripheral operates from RAM.
322
321
323
322
.. note::
324
-
Starting from sQSPI 1.0.0, Position Independent Code (PIC) is supported.
325
-
This allows an application to determine where to load the Soft Peripheral firmware.
323
+
Starting from sQSPI 1.0.0, sQSPI supports Position Independent Code (PIC), which allows an application to determine where to load the Soft Peripheral firmware.
326
324
327
325
Your build environment must reserve the required RAM and ensure that it is readable and writable by both the application core and the FLPR core.
328
-
This table details the memory region, which should be non-cacheable:
326
+
The following table details the memory region, which should be non-cacheable:
329
327
330
328
.. list-table:: RAM Configuration Table
331
329
:widths: auto
@@ -335,26 +333,25 @@ This table details the memory region, which should be non-cacheable:
335
333
- Address offset
336
334
- Size
337
335
* - sQSPI firmware
338
-
- `SP_FIRMWARE_ADDR`
336
+
- ``SP_FIRMWARE_ADDR``
339
337
- 0x3740
340
338
* - sQSPI execution RAM
341
-
- `SP_FIRMWARE_ADDR` + 0x3740
339
+
- ``SP_FIRMWARE_ADDR`` + 0x3740
342
340
- 0x400
343
341
* - sQSPI virtual register interface
344
-
- `SP_FIRMWARE_ADDR` + 0x3B40
342
+
- ``SP_FIRMWARE_ADDR`` + 0x3B40
345
343
- 0x200
346
344
* - Context saving
347
345
- 0x2f890000
348
346
- 0x200 (but the entire block should be retained)
349
347
350
-
The build environment described in the :ref:`nrf54h_series_porting_guide_code` section must comply with these requirements.
348
+
The build environment described in the :ref:`nrf54h_series_porting_guide_code` section, you must comply with these requirements.
351
349
This includes proper settings in linker scripts, device tree specifications (DTS), and resource allocation.
352
350
353
351
Ensure that ``SP_FIRMWARE_ADDR`` is set so that it does not overlap with the context saving address.
354
-
For nRF54H Series devices the firmware has been tested with values after the context saving address. This means that
355
-
``SP_FIRMWARE_ADDR`` is a higher value than the context saving address plus the context saving offset.
356
-
357
-
``SP_FIRMWARE_ADDR`` has been tested and is considered production-ready for value ``0x2f890200``.
352
+
For nRF54H Series devices, the firmware has been tested using values that follow the context saving address.
353
+
This means, that ``SP_FIRMWARE_ADDR`` should be set higher than the context saving address plus the context saving offset.
354
+
The value ``0x2f890200`` for ``SP_FIRMWARE_ADDR`` has been tested and is considered production-ready.
0 commit comments