nesemu/debugger/program_view.h

36 lines
783 B
C
Raw Normal View History

2024-01-11 16:02:53 -05:00
//
// Created by william on 10/01/24.
//
2024-01-14 21:59:13 -05:00
#ifndef NESEMULATOR_PROGRAM_VIEW_H
#define NESEMULATOR_PROGRAM_VIEW_H
2024-01-11 16:02:53 -05:00
#include <panel.h>
#include "../include/types.h"
#include "../cpu/decoding.h"
2024-01-14 21:59:13 -05:00
#include "cursor.h"
#include "window.h"
2024-09-01 15:54:41 -04:00
#include "components/linked_list.h"
2024-01-11 16:02:53 -05:00
#define PROGRAM_VIEW_HEIGHT 19
#define PROGRAM_VIEW_WIDTH 42
2024-01-16 15:46:22 -05:00
#define PROGRAM_VIEW_BASE_ADDR 0x0000
2024-01-11 16:02:53 -05:00
typedef struct debug_operand {
2024-01-14 21:59:13 -05:00
address addr;
2024-01-11 16:02:53 -05:00
byte op_code;
AddressingMode addr_mode;
2024-01-14 21:59:13 -05:00
word value;
2024-01-11 16:02:53 -05:00
} DebugOperand;
2024-01-16 15:46:22 -05:00
typedef struct program_view {
InteractWindow *window;
address *pc;
LinkedList operands;
2024-04-03 23:03:35 -04:00
LinkedListNode *first_operand_node;
LinkedListNode *last_operand_node;
2024-01-16 15:46:22 -05:00
} ProgramView;
2024-05-06 20:23:44 -04:00
void pv_init(InteractWindow *interact, int x, int y);
2024-01-11 16:02:53 -05:00
#endif //NESEMULATOR_PROGRAM_VIEW_H