The SGADE Documentation

the SGADE The Socrates Gameboy Advance Development Engine

The SGADE is a development library for the Nintendo Gameboy Advance. It's free for all uses and is distributed without guarantees. For more information visit the SGADE page.


Main Page   Modules   Data Structures   File List   Data Fields   Globals   Related Pages  

SoDebug.h File Reference

#include "SoSystem.h"
#include <stdarg.h>

Go to the source code of this file.

Defines

#define SO_DEBUG
 Undefine this (comment it) if you are going to do a release build;.

#define SO_ASSERT(a_Assertion, a_Message)
 Define that controls what system the debugprint should use. Assertion macro.

#define SO_DEBUG_PRINT(a_String)
 Prints debug messages;.

#define SO_DEBUG_PRINT_INT_VALUE(a_Var)
 prints integer value

#define SO_DEBUG_PRINT_CHAR_VALUE(a_Var)
 prints character value

#define SO_DEBUG_PRINT_STRING_VALUE(a_Var)
 prints string value

#define SO_COMPILE_TIME_ASSERT(a_Assertion, a_Message)
 generates a breakpoint (BATGBA only) Compile-time assertion.

#define SO_DEPRECATED_FUNCTION(a_FunctionName, a_Message)
 Deprecated function declaration macro.


Functions

char * dstrcpy (u8 *strdst, const u8 *strsrc)
 debug helper: copy string

char * dstrcpynum (u8 *strdst, s32 value, int base)
 debug helper: copy number to string

u16 dstrlen (const u8 *str)
 debug helper: string length

u16 dstrnlen (const u8 *str, u16 count)
 debug helper: string length

char * ditoa (s32 num, char *buf, int len, int base)
 debug helper: convert integer to string

int dsprintf (char *buf, const char *fmt,...)
 sprintf function to support debugging

int dvsprintf (char *buf, const char *fmt, va_list args)
 vsprintf function to support debugging

void SoDebugPrintIntValue (const char *a_Name, s32 a_Value, int base)
 debug helper: print 'watch' for a number

void SoDebugAssert (bool a_Assertion, char *a_Message, char *a_Expression, char *a_File, u32 a_Line)
 Called by the SO_ASSERT macro in debug builds.

void SoDebugPrintf (const char *a_Format,...)
 Print formatted output;.

void SoDebugPrint (const char *a_Message)
 This prints a debug message depending on the running environment;.

void SoDebugPrintCharValue (const char *a_Name, char a_cValue)
 debug helper: print 'watch' for a character

void SoDebugPrintStringValue (const char *a_Name, const char *a_szValue)
 debug helper: print 'watch' for a string

void SoDebugDumpWordBuffer (const char *a_szDescription, u16 *a_pBuffer, u16 a_iCount)
 debug helper: print a 'watch' for a binary block


Variables

char s_DebugBuffer [256]
 Temporary buffer for debug print output.


Detailed Description

Copyright (C) 2002 by the SGADE authors For conditions of distribution and use, see copyright notice in SoLicense.txt

Author:
Matt Hattem, Jaap Suter, Mark T. Price, Erik Rounds, Gabriele Scibilia
Date:
July 1, 2003
See the SoDebug module for more information.


Copyright 2002 by the SGADE authors. See SoLicense.h or Visit the SGADE page for more information.