X-Git-Url: http://gitweb.hugovil.com/?a=blobdiff_plain;f=src%2Fcommon%2Fmemory.h;h=07cf5b3f4abbbd6ee13e9ea61d9ad4be9736bf5b;hb=8bfc53036ae2e040287a92c8a9e8f84571a19080;hp=dbfd043f08d50d8f40e695d3c731b125ee3a8ce5;hpb=3c838204cd78bcf106fdd65476180659ab629fcb;p=emu8051.git diff --git a/src/common/memory.h b/src/common/memory.h index dbfd043..07cf5b3 100644 --- a/src/common/memory.h +++ b/src/common/memory.h @@ -38,7 +38,12 @@ void memory_init(void); int -memory_check_address(enum mem_id_t id, unsigned long address, int display_error); +memory_check_address(enum mem_id_t id, unsigned long address, + int display_error); + +void +memory_convert_bit_address(uint8_t bit_address, uint8_t *byte_address, + uint8_t *bit_number); u_int8_t * memory_getbuf(enum mem_id_t id, unsigned long address); @@ -49,6 +54,15 @@ memory_clear(enum mem_id_t id); void memory_write8(enum mem_id_t id, unsigned long address, u_int8_t value); +void +memory_write_direct(unsigned int address, unsigned char value); + +void +memory_write_indirect(unsigned int address, unsigned char value); + +void +memory_write_bit(uint8_t bit_address, uint8_t value); + void memory_sfr_write8(unsigned long address, u_int8_t value); @@ -58,6 +72,15 @@ memory_sfr_write_dptr(u_int16_t value); u_int8_t memory_read8(enum mem_id_t id, unsigned long address); +unsigned char +memory_read_direct(unsigned int address); + +unsigned char +memory_read_indirect(unsigned int address); + +unsigned char +memory_read_bit(uint8_t bit_address); + u_int8_t memory_sfr_read8(unsigned long address);