Formatted Debug Output (FDO) Copyright (c) 2005-2006, mike.dld Created: 2005-01-29, Changed: 2006-11-10 For questions and bug reports, mail to mike.dld@gmail.com Available format specifiers are: %s, %d, %u, %x (with partial width support) To be defined within your sources: __DEBUG__ equ 1 __DEBUG_LEVEL__ equ 5 Examples: DEBUGF 1,"%s - %d (%x)",eax,123,ch DEBUGF 1,"%d.%d.%d.%d",[ip+0]:1,[ip+1]:1,[ip+2]:1,[ip+3]:1 DEBUGF 1,<"function ",__FNAME__,": %s - %x - %u">,"text here",[var]:5,[esp+16] DEBUGF 1,"[%d][%d][%d][%d][%d]\n",al,ax,ebx,[eax],[eax]:1 DEBUGF 2,"[%u][%u][%u][%u][%u]\n",al,ax,ebx,[eax],[eax]:1 DEBUGF 3,"[%x][%x][%x][%x][%x]\n",al,ax,ebx,[eax],[eax]:1 DEBUGF 4,"[%s][%s][%s][%s][%s][%s][%s]\n","string":4,eax,eax:5,[ebx]:5,eax:ecx,eax:[ecx],eax:byte[ecx] Widths: for %s - any number, register, or in-memory variable for %d - 1, 2, 4 (only for in-memory arguments) for %u - 1, 2, 4 (only for in-memory arguments) for %x - 1 .. 8