mirror of
https://github.com/andwati/mos-6502.git
synced 2026-10-18 03:02:51 +00:00
17 lines
297 B
C
17 lines
297 B
C
#ifndef MEMORY_H
|
|
#define MEMORY_H
|
|
|
|
#include <stdint.h>
|
|
|
|
#define MEM_SIZE 65536 // 64KB memory size
|
|
|
|
typedef struct
|
|
{
|
|
uint8_t data[MEM_SIZE];
|
|
} Memory;
|
|
|
|
uint8_t mem_read(Memory *mem, uint16_t addr);
|
|
void mem_write(Memory *mem, uint16_t addr, uint8_t value);
|
|
void mem_reset(Memory *mem);
|
|
|
|
#endif |