Fix BASIC
Fix cycle waiting Fix warnings
This commit is contained in:
1 parent
8101cc3f62
commit
a5e30a7b28
14 files changed
+114
-61
No files matched your search
+28
@@ -0,0 +1,28 @@
|
||||
#define DIAG_STRINGIFY_(x) #x
|
||||
#define DIAG_STRINGIFY(x) DIAG_STRINGIFY_(x)
|
||||
|
||||
#define DIAG_DO_PRAGMA(x) _Pragma(DIAG_STRINGIFY(x))
|
||||
|
||||
#if defined(__clang__)
|
||||
|
||||
#define DIAG_PUSH() DIAG_DO_PRAGMA(clang diagnostic push)
|
||||
|
||||
#define DIAG_POP() DIAG_DO_PRAGMA(clang diagnostic pop)
|
||||
|
||||
#define DIAG_IGNORE(w) DIAG_DO_PRAGMA(clang diagnostic ignored w)
|
||||
|
||||
#elif defined(__GNUC__)
|
||||
|
||||
#define DIAG_PUSH() DIAG_DO_PRAGMA(GCC diagnostic push)
|
||||
|
||||
#define DIAG_POP() DIAG_DO_PRAGMA(GCC diagnostic pop)
|
||||
|
||||
#define DIAG_IGNORE(w) DIAG_DO_PRAGMA(GCC diagnostic ignored w)
|
||||
|
||||
#else
|
||||
|
||||
#define DIAG_PUSH()
|
||||
#define DIAG_POP()
|
||||
#define DIAG_IGNORE(w)
|
||||
|
||||
#endif
|
||||
@@ -3,7 +3,7 @@
|
||||
|
||||
#include <stdint.h>
|
||||
|
||||
#define IO_SIZE (1 * 1024) // 1KiB
|
||||
#define IO_SIZE (1 * 1024) // 1KiB
|
||||
#define IO_BASE (47 * 1024) // 47KiB RAM, hard coded, 0xBC00
|
||||
|
||||
#define SCREEN_ADDRESS 0
|
||||
|
||||
+2
-2
@@ -1,12 +1,12 @@
|
||||
#ifndef MEMORY_MAP_H
|
||||
#define MEMORY_MAP_H
|
||||
|
||||
#include <stdint.h>
|
||||
|
||||
#include "io.h"
|
||||
#include "ram.h"
|
||||
#include "rom.h"
|
||||
|
||||
#include <stdint.h>
|
||||
|
||||
uint8_t readMemory(uint16_t address, uint8_t *ram, uint8_t *rom);
|
||||
void writeMemory(uint16_t address, uint8_t value, uint8_t *ram);
|
||||
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
#ifndef RAM_H
|
||||
#define RAM_H
|
||||
|
||||
#include "stdint.h"
|
||||
#include <stdint.h>
|
||||
|
||||
#define RAM_SIZE (64 * 1024) // 55KiB
|
||||
#define RAM_BASE (0x00) // 0
|
||||
#define RAM_SIZE (64 * 1024) // 64KiB, read/write to IO is ignored, ROM can be banked
|
||||
#define RAM_BASE (0x00) // 0
|
||||
|
||||
int createRAM(uint8_t **ram);
|
||||
void destroyRAM(uint8_t *ram);
|
||||
|
||||
Reference in new issue
Block a user