|
libc8
CHIP-8 utility library
|
#include "debug.h"#include "../chip8.h"#include "../decode.h"#include "../font.h"#include "util.h"#include <ctype.h>#include <stdio.h>#include <stdlib.h>#include <string.h>Functions | |
| int | c8_debug_repl (C8 *c8) |
| Debug command line loop. | |
| int | c8_has_breakpoint (C8 *c8, uint16_t pc) |
| Check if breakpoint exists at address pc. | |
Variables | |
| const char * | c8_args [] |
| const char * | c8_cmds [] |
Stuff related to debug mode.
| int c8_debug_repl | ( | C8 * | c8 | ) |
Debug command line loop.
This function parses user commands from stdin and prints the result until one of the following conditions is met:
C8_DEBUG_CONTINUE)C8_DEBUG_QUIT)C8_DEBUG_STEP)| c8 | the current CHIP-8 state |
C8_DEBUG_CONTINUE, C8_DEBUG_STEP, or C8_DEBUG_QUIT | int c8_has_breakpoint | ( | C8 * | c8, |
| uint16_t | pc | ||
| ) |
Check if breakpoint exists at address pc.
This function checks if there is a breakpoint set at the specified program counter (pc) address in the C8 structure. It returns 1 if a breakpoint exists at that address, and 0 if no breakpoint is set.
| c8 | C8 to check breakpoints of |
| pc | address to check for breakpoint at |
| const char* c8_args[] |
These are string values of all possible argument, ordered to match the C8_Argument enumerator.
| const char* c8_cmds[] |
These are string values of all possible commands, ordered to match the C8_Command enumerator.