Skip to content

Commit 0913cec

Browse files
authored
Merge pull request #471 from arduino/martab1994-patch-5
Update breakout-jlink-setup.md
2 parents e7b1085 + be284f6 commit 0913cec

File tree

1 file changed

+11
-11
lines changed

1 file changed

+11
-11
lines changed

content/hardware/04.pro/carriers/portenta-breakout/tutorials/breakout-jlink-setup/breakout-jlink-setup.md

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ This tutorial will show you how to debug an Arduino sketch using the Portenta H7
2727
## Instructions
2828
### 1. Setting up with the Arduino IDE
2929

30-
First, if you haven't already, install the [Arduino IDE](https://www.arduino.cc/en/software) and connect your Portenta H7. When uploading a sketch to your Arduino board with the Arduino IDE, it will build an .ELF file of the sketch. We will need this file to debug in Ozone in the next step. To easily find the file path to the .ELF file, we can enable the show verbose output option in the Arduino IDE. To do this, open up the preferences under **File > Preferences** in the Arduino IDE.
30+
First, if you haven't done it yet, install the [Arduino IDE](https://www.arduino.cc/en/software) and connect your Portenta H7. When uploading a sketch to your Arduino board with the Arduino IDE, it will build an .ELF file of the sketch. We will need this file to debug in Ozone in the next steps. To easily find the file path of the .ELF file, we can enable the show verbose output option in the Arduino IDE. To do this, open up the preferences under **File > Preferences** in the Arduino IDE.
3131

3232
![Preferences in Arduino IDE](assets/breakout_jlink_ard_ide_pref.png)
3333

@@ -37,7 +37,7 @@ When you have the preferences window open, look for the **Show verbose output du
3737

3838
Now we are ready to upload the script that we want to debug. If you don't have a sketch to test, you can use the example sketch found in the **Conclusion** section of this tutorial.
3939

40-
When we upload the sketch with the Arduino IDE, we need to know where the .ELF file will be saved. Build your project in the Arduino IDE, and highlight the output directory, it could look for example like `C:\Users\profile\AppData\Local\Temp\arduino_build_815037`. Note down the path for easier access in the next step.
40+
When we upload the sketch with the Arduino IDE, we need to know where the .ELF file will be saved. Build your project in the Arduino IDE and highlight the output directory; it should look for example like `C:\Users\profile\AppData\Local\Temp\arduino_build_815037`. Note down the path for easier access in the next step.
4141

4242
![The .elf file path in Arduino IDE](assets/breakout_jlink_elf_path.png)
4343

@@ -49,41 +49,41 @@ First, connect the Portenta H7 to the Breakout. To begin using the J-link device
4949

5050
### 3. Using the Setup with Segger Ozone
5151

52-
Download and install [Segger's Ozone debugger](https://www.segger.com/downloads/J-link/#Ozone). If you are on windows, make sure to also download the [J-Link Software and Documentation Pack for Windows.](https://www.segger.com/products/debug-probes/j-link/tools/j-link-gdb-server/about-j-link-gdb-server/)
52+
Download and install [Segger's Ozone debugger](https://www.segger.com/downloads/J-link/#Ozone). If you are on Windows, make sure to also download the [J-Link Software and Documentation Pack for Windows.](https://www.segger.com/products/debug-probes/j-link/tools/j-link-gdb-server/about-j-link-gdb-server/)
5353

54-
When starting Ozone, make sure to enter the correct CPU into the settings box. The Portenta H7 uses the **STM32H747XI**, you can then chose between the M4 and M7 core on the Portenta.
54+
When starting Ozone, make sure to enter the correct CPU into the settings box. The Portenta H7 uses the **STM32H747XI**; you can then choose between the M4 and M7 core on the Portenta.
5555

5656
![Segger Ozone J-Link cpu settings](assets/breakout_jlink_ozone_cpu.png)
5757

58-
Continue to the next step. Here we need to change the **Target Interface** to **SWD**. The Portenta H7 does not support JTAG. Then select your J-link device in the list of emulators and head to the next page.
58+
Continue to the next step. Here you need to change the **Target Interface** to **SWD**. The Portenta H7 does not support JTAG. Then select your J-link device in the list of emulators and head to the next page.
5959

6060
![Segger Ozone J-Link connection settings](assets/breakout_jlink_connection_setting.png)
6161

62-
Now you get to the window that asks you to select the program to be debugged, this is where you load the project's .ELF file. With the temporary output path that we noted before. Navigate to the correct directory, and select the .ELF file.
62+
Now you get to the window that asks you to select the program to be debugged, this is where you load the project's .ELF file with the temporary output path that we noted before. Navigate to the correct directory, and select the .ELF file.
6363

6464
![Temporary .ELF file location](assets/breakout_jlink_ozone_elf_file.png)
6565

66-
In the 'optional settings' dialog, set both options 'Initial PC' and 'Initial Stack Pointer' to 'Do not set' as it would skip the Arduino bootloader otherwise which may prevent the sketch from running correctly.
66+
In the 'optional settings' dialog, set both options 'Initial PC' and 'Initial Stack Pointer' to 'Do not set' as it would skip the Arduino bootloader, otherwise this may prevent the sketch from running correctly.
6767

6868
![Segger Ozone J-Link connection optional settings](assets/breakout_jlink_optional_settings.png)
6969

70-
When the setup is finished Ozone will open the file containing the main function. You will note that this is not the .ino sketch you wrote since this is an abstraction layer generated by the IDE. To open our .ino sketch we need to go to **Find > Find source file** in the top toolbar.
70+
When the setup is finished, Ozone will open the file containing the main function. You will note that this is not the .ino sketch you wrote since this is an abstraction layer generated by the IDE. To open our .ino sketch we need to go to **Find > Find source file** in the top toolbar.
7171

7272
![Find source file in Ozone](assets/breakout_jlink_ozone_find_tab.png)
7373

74-
In the little window that appears, type ".ino". You should now be able to see the file, select the file and it will open it in Ozone.
74+
In the little window that appears, type ".ino". You should now be able to see the file, select the file and open it in Ozone.
7575

7676
![Find source file window](assets/breakout_jlink_ozone_find_window.png)
7777

78-
Now you are ready to start debugging. Simply go to **Debug > Download & Reset Program** to start debugging your sketch, you can add breakpoints , inspect variables, halt the execution and more.
78+
Now you are ready to start debugging. Simply go to **Debug > Download & Reset Program** to start debugging your sketch: you can add breakpoints , inspect variables, halt the execution and more.
7979

8080
![Start debugging in Ozone](assets/breakout_jlink_ozone_start_debugging.png)
8181

8282
For more information about the features present in the Ozone debugger, please go [here.](https://www.segger.com/products/development-tools/ozone-j-link-debugger/technology/application-debugging/)
8383

8484
## Conclusion
8585

86-
In this tutorial, you learned how to connect your Portenta H7 and Breakout board to a J-link device and use it with the Ozone debugger. We also went through how to create a file with Arduino IDE that can be debugged in Ozone. And finally how to use the Ozone debugger to debug an Arduino sketch.
86+
In this tutorial, you learned how to connect your Portenta H7 and Breakout board to a J-link device and use it with the Ozone debugger. We also went through how to create a file with Arduino IDE that can be debugged in Ozone. And eventually how to use the Ozone debugger to debug an Arduino sketch.
8787

8888
### Example Sketch
8989

0 commit comments

Comments
 (0)