O'Reilly logo

Embedded Software Development with eCos™ by Anthony J. Massa

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

7.2. Asserts and Tracing

eCos supports two mechanisms to aid in debugging—asserts and tracing. An assert is a piece of code that checks, at run time, whether a condition is expected. If the condition is not expected, an error message can be output and the application is halted. Assertions can determine if there is a bug in the code and isolate the problem immediately, rather than having the application fail later during execution.

Tracing allows the output of text messages at various points in the application's execution. This output enables you to follow the execution flow of a program or check a particular status when certain events occur.

The eCos assert support is complementary to the ISO C standard assert functionality contained in the ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required