Skip to content

Commit 6a4c55d

Browse files
committed
Updated tutorial content
1 parent 1f8fe98 commit 6a4c55d

File tree

1 file changed

+9
-3
lines changed

1 file changed

+9
-3
lines changed

content/learn/02.microcontrollers/04.debugging/debugging.md

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -212,9 +212,13 @@ void myFunction() {
212212

213213
Now let us talk about **wireless communications**. Wireless communications are a key feature in developing new Internet of Things (IoT) devices with different requirements or specifications and for different purposes. Wireless communication is present on many embedded systems, and Arduino® hardware is no exception for this feature. The question now is: how do we debug wireless communications between devices?
214214

215-
A simple technique used to debug wireless communications between devices consists of using **acknowledge flags**. Acknowledge flags are used to verify successful communication between devices; this process is found on physical communication layers, such as I2C or SPI, providing the present status between these devices. It goes the same for wireless communication between devices. Due to different protocol types in wireless communication, acknowledged methods may differ; the easiest way to confirm that the data exchange was successful is to check the log on each end device. So why would we need to debug on a radio frequency spectrum that is working correctly? It is to verify that the transceiver configuration is correct, mainly its transmission power.
215+
A simple technique used to debug wireless communications between devices consists of using **acknowledge flags**. Acknowledge flags are used to verify successful communication between devices; this process is found on physical communication layers, such as I2C or SPI, providing the present status between these devices. This is a technique that is common for debugging external devices in bridge and aids to get a clear understanding of the device's behaviour when establishing physical layer of communication. Hardware tools mentioned earlier, which are multimeter, oscilloscope, and a logic analyzer, provides more in-depth details and adds more value to this debugging style. Hence, it grants much more refined device software overall.
216216

217-
There are several software to assist this process and one of them is GQRX supported on OSX and Linux. For the Windows operating system, AirSpy could be software of choice to assist for this type of task. The SDR via USB stick can be used as a low cost spectrum analyzer, using the user's computer as a hot for radio station. The devices to be debugged are powered on while SDR takes care of catching any present transmission on the air and display it on the screen.
217+
However, not everything is connected on a physical layer, but on an **abstract layer**. The abstract layer can be seen as an example of frequency spectrum playground. The layer where the device establishes communication via air, or in a wireless architecture. Regularly it would not require to somehow debug the data found in the air nor verify on top of the already certified wireless devices, due to complexity involved in this types devices. Because of different protocol types in wireless communication, acknowledge methods can be applied but may differ in its own rules; the easiest way to confirm the data exchange was successful is to check the log on each end device.
218+
219+
So why would we need to debug on a radio frequency spectrum that is working correctly? It is to verify that the transceiver configuration is correct, mainly its transmission power. Also depending on the preciseness and absolute zero fault requirement in the system with wireless capability, needs a tool that is able to provide this insight. This is where an advanced debugging method comes in by presenting Software Defined Radios.
220+
221+
It is an optional debugging method on a development process usually, but it ensures much more robust system design. There are several software to assist this process and one of them is GQRX supported on OSX and Linux. For the Windows operating system, AirSpy could be software of choice to assist for this type of task. The SDR via USB stick can be used as a low cost spectrum analyzer, using the user's computer as a hot for radio station. The devices to be debugged are powered on while SDR takes care of catching any present transmission on the air and display it on the screen.
218222

219223
Shown visual representation of the signal via SDR software can now be used to verify the transmission power outputted by the device and the amount of data that flew on the air. This will help to visualize the properties of the device's wireless communication configuration. It will be possible to verify the transmission and reception power, the amount of bytes transmitted, and the frequency on which it is supposed to be transmitting. A very handy tool to debug wireless communication states of the devices.
220224

@@ -448,7 +452,9 @@ Debugging is a necessary step for developing robust and reliable embedded system
448452
* **Localization**: this phase involves narrowing the range of possibilities until the bug can be isolated to a specific code segment in the embedded software.
449453
* **Correction**: this phase involves eradicating the bug from the software.
450454

451-
Knowing the potential causes of bugs allows us to adopt strategies that minimize their occurrence.
455+
Knowing the potential causes of bugs allows us to adopt strategies that minimize their occurrence. To aid this process, lots of different debugging technniques and external devices are present. Maybe some software designs does not require the usage of external debuggers for example, but when the software involves different levels of requirements and specially when it requires scalability, things change drastically for the development process. The debugging techniques and the external debuggers will support this development process, thus granting refined software. You will know how the device will behave in most cases with the software, its computational performance, and even achieve non-power hungry devices due to clean memory management.
456+
457+
The debugging may be an overlooked aspect of the development, but it is the most serious yet crucial tool that exists for the development. If you desire to develop a genuine device, the debugging process should always be implemented, to achieve its genuine performance.
452458

453459
## Further Reading and Resources
454460

0 commit comments

Comments
 (0)