8000 Update remaining sections · manishcoder2212/docs-content@13f1646 · GitHub
[go: up one dir, main page]

Skip to content

Commit 13f1646

Browse files
authored
Update remaining sections
1 parent ba93a84 commit 13f1646

File tree

1 file changed

+36
-36
lines changed
  • content/hardware/04.pro/boards/portenta-h7/tutorials/lauterbach-debugger

1 file changed

+36
-36
lines changed

content/hardware/04.pro/boards/portenta-h7/tutorials/lauterbach-debugger/content.md

Lines changed: 36 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -49,13 +49,13 @@ In this tutorial, you will learn how to upload an application that contains an M
4949

5050
In the next steps, the **double-tilde (~~)** is used as a placeholder for the directory where you unzipped the TRACE32 software.
5151

52-
### 1. Downloading the TRACE32 Debugger
52+
### Downloading the TRACE32 Debugger
5353

5454
In order to download the TRACE32 debugger, open the [Lauterbach download page](https://www.lauterbach.com/download_demo.html) in your browser. Download the zip file named **Debugger for GDB target (Arduino Pro)**.
5555

5656
Extract the zip file to a directory of your choice. On Windows systems, please avoid C:\T32, because this is the default installation directory for the full TRACE32 distribution.
5757

58-
### 2. Registration and License Key
58+
### Registration and License Key
5959

6060
Without a valid license, the TRACE32 debugger only works for a few minutes in demo mode. To avoid this limitation, Lauterbach may generate a **free license** based on the serial number of your board. The license will be valid for one year and can easily be renewed for free after this expiration using the same procedure.
6161

@@ -65,9 +65,9 @@ In order to obtain a new license, you need to first get the serial number of you
6565

6666
![Your board's serial number can be displayed in the Arduino IDE using the "Get Board Info" command](assets/por_ard_trace32_board_info.png)
6767

68-
***For Portenta H7 and Nicla Vision only: if you only see a 16-character (64-bit) long serial number, then you need to update your Arduino IDE and your boards' core from the boards manager in the IDE. Details on how to do so can be found on the Arduino website. In addition, make sure your board has the [latest bootloader](https://docs.arduino.cc/tutorials/portenta-h7/updating-the-bootloader) installed.***
68+
***For Portenta H7 and Nicla Vision only: if you only see a 16-character (64-bit) long serial number, then you need to update your Arduino IDE and your boards' core from the Boards Manager in the IDE. Details on how to do so can be found on the Arduino website. In addition, make sure your board has the [latest bootloader](https://docs.arduino.cc/tutorials/portenta-h7/updating-the-bootloader) installed.***
6969

70-
- Use the TRACE32 debugger. Check section "3. Start the TRACE32 Debugger" to learn how to get started. Click the menu item "Board S/N and License State". Your board's serial number will be printed in the AREA window and a dialog LICENSE.state will be opened.
70+
- Use the TRACE32 debugger. Check the section "Starting the TRACE32 Debugger" to learn how to get started. Click the menu item "Board S/N and License State". Your board's serial number will be printed in the AREA window and a dialog LICENSE.state will be opened.
7171

7272
![Click the menu item "Detect Board S/N" to display the serial number](assets/por_ard_trace32_board_sn.png)
7373

@@ -90,7 +90,7 @@ When you receive the email containing your license key, follow the instructions
9090
- Restart TRACE32 after adding the license key.
9191

9292

93-
### 3. Starting the TRACE32 Debugger
93+
### Starting the TRACE32 Debugger
9494

9595
To use the debugger, launch the appropriate executable for your host operating system. The executables can be found in the corresponding sub-directory for your operating system:
9696

@@ -116,55 +116,57 @@ On Linux systems, you will need to edit the `system-settings.cmm` file to manual
116116

117117
***The manual port setting is also useful for Windows systems when you connect multiple boards simultaneously and you would like to select a specific board to be used by TRACE32 for debugging. The automatic port selection is disabled when a &GDBPORT definition is found in `system-settings.cmm`.***
118118

119-
### 4. Running Your First Demo
119+
### Running Your First Demo
120120

121-
A number of pre-built demo programs are available in the tool. They can be accessed from the "Arduino Projects" menu. The following instructions relate to the T32ThreadDebug example. However, the other examples follow a similar pattern.
121+
A number of pre-built demo programs are available in the tool. They can be accessed from the "Arduino Projects" menu. The following instructions relate to the T32ThreadDebug example. However, other examples follow a similar pattern.
122122

123123
The demo directory already includes the symbolic file (.elf) for debugging and the binary file (.bin) for Flash programming.
124124

125125
![.elf files contain debug symbols which are required for debugging. .bin files can run directly on the board's hardware](assets/por_ard_trace32_files.svg)
126126

127-
### ELF File Selection
127+
#### ELF File Selection
128128

129-
Select "T32ThreadDebug" from the "Portenta H7 Demos" menu and you will be presented with a dialog called "Elf File Selection". This is where the TRACE32 initial environment can be configured.
129+
Select "T32ThreadDebug" from the "Portenta H7 Projects" menu and you will be presented with a dialog called "Elf File Selection". This is where the TRACE32 initial environment can be configured.
130130

131131
![Elf File Selection](assets/por_ard_trace32_elf_file_selection.png)
132132

133-
In this dialog, you can select which variant of the Arduino IDE you would like to use to source ELF files or if you want to use the current directory. To follow this tutorial please select "current dir".
133+
In this dialog, you can select which variant of the Arduino IDE you would like to use to source ELF files or if you want to use the current directory. To follow this tutorial, please select "current dir".
134134

135-
The list to the right of the "Options" selection should then become populated with a number of available ELF files for downloading and debugging. Select the one you want with a double click. In this case, select "T32ThreadDebug.ino.elf". This will also show file attributes such as date, time and size. To select an ELF file from a custom directory, click the "File" button underneath the "User's choice" field and browse for the desired ELF file. You can opt for changing the behavior of this script the next time it is executed.
135+
The list on the right of the "Options" selection should then become populated with a number of available ELF files ready for downloading and debugging. Select the one you are interested into with a double click. In this tutorial, "T32ThreadDebug.ino.elf" has been selected. This will also show file attributes such as date, time and size.
136136

137-
If the application has already been programmed to Flash, for instance via the Arduino IDE or a previous TRACE32 session, select "Load debug symbols (program is already in Flash)" to prevent an unnecessary erase and write cycle of the on-chip Flash memory.
137+
To select an ELF file from a custom directory, click the "File" button underneath the "User's choice" field and browse for the desired ELF file. You can decide to change the behavior of this script the next time it is executed.
138+
139+
If the application has already been programmed on the Flash, for instance via the Arduino IDE or a previous TRACE32 session, select "Load debug symbols (program is already in Flash)" to prevent an unnecessary erase and write cycle of the on-chip Flash memory.
138140

139141
If the application has changed or does not match the contents of the Flash, then select "Flash program and load debug symbols".
140142

141143
Click the "OK" button to confirm all of your choices and start the session.
142144

143-
### Debugging Session
145+
#### Debugging Session
144146

145-
If the Flash is being programmed, TRACE32 will prompt you to double-click the reset button on the board to enable the bootloader mode. The built-in green LED of the board fades in and out when in bootloader mode. Click the "OK" button to proceed. Diagnostic messages will be displayed in the TRACE32 AREA window whilst the erasing and programming take place.
147+
If the Flash is being programmed, TRACE32 will prompt you to double-click the reset button on the board to enable the bootloader mode. The built-in green LED of the board will fade in and out when the board will be in bootloader mode. Click the "OK" button to proceed. Diagnostic messages will be displayed in the TRACE32 AREA window whilst the erasing and programming take place.
146148

147-
The script will then attach to the board and cause TRACE32 to open some debug windows. When everything is ready, you should see the Program Counter halted at the entry to the setup() function. You may now use the arrow buttons in the toolbar to step through the code and inspect the variables, registers, call stack etc.
149+
The script will then be uploaded to the board and cause TRACE32 to open some debug windows. When everything is ready, you should see the Program Counter halted at the beginning of the setup() function. You may now use the arrow buttons in the toolbar to step through the code and inspect the variables, registers, call stack etc.
148150

149151
![TRACE32 debug session on Portenta H7 - T32ThreadDebug demo application](assets/por_ard_trace32_main_screen.png)
150152

151153
In case of errors, please check the physical connection to the board, check if your host PC has detected the board's serial port and if this is the port configured in TRACE32. Reset the board and retry.
152154

153-
Take a look at the readme.txt file inside the demo directory for further information about the demo.
155+
Take a look at the `readme.txt` file inside the demo directory for further information about the demo.
154156

155157
### Compile and Debug Other Projects
156158

157-
The provided demos or another project of your choice can be edited, compiled and flashed with the Arduino IDE. You can open for example the T32ThreadDebug.ino file with Arduino IDE, build and flash it. Flashing is also possible with TRACE32.
159+
The provided demos or any other project of your choice can be edited, compiled, and flashed with the Arduino IDE. You can open for example the `T32ThreadDebug.ino` file in the Arduino IDE, build and flash it. Flashing is also possible with TRACE32 tool.
158160

159-
***IMPORTANT: If you choose to program the Flash from within the Arduino IDE, do not close the IDE after programming; leave it open. This is very important because, if you close the IDE, it cleans up the temporary build directory which includes the ELF file.***
161+
***IMPORTANT: If you choose to program the Flash within the Arduino IDE, do not close the IDE after programming; leave it open. This is very important because, if you close the IDE, it cleans up the temporary build directory which includes the ELF file.***
160162

161-
The demo directory contains a startup script which will copy the ELF file and the binary file in the current working directory. After the startup script is run, you can safely close the Arduino IDE if you don't need it anymore.
163+
The demo directory contains a startup script that will copy the ELF file and the binary file in the current working directory. After the startup script is run, you can safely close the Arduino IDE if you do not need it anymore.
162164

163165
When you are done with flashing your application to the board, you can switch back to TRACE32. Select the type of Arduino IDE. If an ELF file is found, double-click to select it, then select "Load debug symbols (program is already in flash)" and click "OK".
164166

165-
### Startup Script
167+
### Custom Startup Script
166168

167-
You may also create a custom startup script for your own application. A minimal startup script is shown below. Copy it into a text file and save it with a file extension ".cmm". To execute it call the menu command "File-->Run Script..." from the TRACE32 GUI.
169+
You may also create a custom startup script for your own application. A minimal startup script is shown below. Copy it into a text file and save it with a file extension ".cmm". To execute it, call the menu command "File-->Run Script..." from the TRACE32 GUI.
168170

169171
```cpp
170172
SYStem.Down
@@ -184,13 +186,13 @@ List.auto
184186
ENDDO
185187
```
186188

187-
You can also copy the script start.cmm from the T32ThreadDebug demo directory to your working directory. For an application using the Serial Monitor, it is necessary to copy both start.cmm and term.cmm from the T32ThreadDebugPrint demo directory.
189+
You can also copy the script `start.cmm` from the T32ThreadDebug demo directory to your working directory. For an application using the Serial Monitor, it is necessary to copy both `start.cmm` and `term.cmm` from the T32ThreadDebugPrint demo directory.
188190

189-
For each demo the corresponding start.cmm script comes with a predefined window layout. For your own layout, manually open and arrange the windows as you prefer, then save this window layout using the "Store Windows..." command in the Window menu. Save the file as win.cmm. It will be automatically found and used the next time you start a debugging session.
191+
For each demo the corresponding `start.cmm` script comes with a predefined window layout. For your own layout, manually open and arrange the windows as you prefer, then save this window layout using the "Store Windows..." command in the Window menu. Save the file as `win.cmm`. It will be automatically found and used the next time you start a debugging session.
190192

191193
## Conclusion
192194

193-
In this tutorial you learned how to acquire a free version of the TRACE32 GDB Front End debugger, fully licensed for Portenta H7 or Nicla Vision for one year. You learned how to start the debugger and debug some ready-to-run demos. Furthermore, you learned how to debug an application compiled with the classic Arduino IDE.
195+
In this tutorial, you learned how to acquire a free version of the TRACE32 GDB Front End debugger, fully licensed for your Arduino board for one year. You learned how to start the debugger and debug some ready-to-run demos. Furthermore, you learned how to debug an application compiled with the classic Arduino IDE.
194196

195197
### Next Steps
196198
Lauterbach also provides hardware-based debug & trace tools. To learn more about them please visit:
@@ -201,15 +203,15 @@ Lauterbach also provides hardware-based debug & trace tools. To learn more about
201203

202204
## Troubleshooting
203205

204-
### Portenta’s Serial Number Is Not 24 Digits Long
206+
### Portenta’s or Nicla's Serial Number Is Not 24 Digits Long
205207

206208
- Update Arduino IDE to the latest version available
207209
- Update **Arduino mbed-enabled Boards** core from Arduino IDE menu: **Tools > Board > Boards Manager**
208-
- [Update the Portenta's bootloader using the instructions](https://docs.arduino.cc/tutorials/portenta-h7/updating-the-bootloader).
210+
- Update the board's bootloader using the instructions available [here](https://docs.arduino.cc/tutorials/portenta-h7/updating-the-bootloader).
209211

210212
### Error Message in AREA View: 'No More Arguments Expected'
211213

212-
- This may be caused by unsupported characters in your Windows user name. Make sure your user name neither contains any spaces nor special characters.
214+
- This may be caused by unsupported characters in your Windows user name. Make sure your user name contains neither any spaces nor special characters.
213215

214216
### Debugger Connection Issues
215217

@@ -220,30 +222,28 @@ In case the debugger encounters any issues while connecting to the Portenta, try
220222

221223
### Flashing Issues
222224

223-
- Before flashing the board from the Arduino IDE, please disconnect the TRACE32 debugger by typing the command: “SYStem.Down” on the command line interface. Alternatively, open the menu: “CPU-> System Settings…” and press the radio button “Down” in the “Mode” section.
225+
- Before flashing your board with the Arduino IDE, please disconnect the TRACE32 debugger by typing the command: “SYStem.Down” on the command line interface. Alternatively, open the menu: “CPU-> System Settings…” and press the radio button “Down” in the “Mode” section.
224226

225227
### Debugger Hanging Issues
226228

227-
- The TRACE32 GDB front-end debugger is a run-mode debugger: At a breakpoint, only the user threads are stopped. The kernel and all other system threads continue to run. It may happen that the debugger hangs if a breakpoint is set in critical system areas. In this case, reset the board, remove all breakpoints and connect again to the target (SYStem.Mode Attach command).
229+
- The TRACE32 GDB front-end debugger is a run-mode debugger: At a breakpoint, only the user threads are stopped. The kernel and all other system threads continue to run. It may happen that the debugger hangs if a breakpoint is set in critical system areas. In this case, reset the board, remove all breakpoints, and connect again to the target (SYStem.Mode Attach command).
228230

229231
### Issues While Starting TRACE32 on Linux
230232

231233
- The TRACE32 executable for Linux requires the Qt libraries. Please verify that one of the following versions of Qt is installed:
232-
- Qt4 >= 4.6.2 (Linux 32 bit or 64 bit)
233-
- or Qt5 >= 5.9 (Linux 64 bit)
234+
- Qt4 >= 4.6.2 (Linux 32-bit or 64-bit)
235+
- or Qt5 >= 5.9 (Linux 64-bit)
234236

235237
On Ubuntu Linux, for example, you can install the Qt5 libraries using apt-get: `sudo apt-get install qt5-default`
236238

237239
### Issues With the GDB Serial Port on Host Linux
238240

239-
The user running the TRACE32 executable on Linux must have the permission to access serial devices. For example, in Ubuntu a temporary permission can be set as follows:
241+
The user running the TRACE32 executable on Linux must have permission to access serial devices. For example, in Ubuntu, a temporary permission can be set as follows:
240242

241243
`sudo chown :username /dev/devicename`
242244

243-
You can also set a permanent permission adding the user to the "dialout" group. For example, in Ubuntu:
245+
You can also set permanent permission by adding the user to the "dialout" group. For example, in Ubuntu:
244246

245247
`sudo adduser username dialout`
246248

247-
Alternatively you can run the TRACE32 executable with root permissions.
248-
249-
**Reviewed by:** Maurizio Menegotto, Richard Copeman [2023-08-02]
249+
Alternatively, you can run the TRACE32 executable with root permissions.

0 commit comments

Comments
 (0)
0