From e9084acf8cb9e839ce65d3b3d6b41c70af40836d Mon Sep 17 00:00:00 2001 From: Will Scullin Date: Sat, 5 Aug 2023 18:33:29 -0700 Subject: [PATCH] Convert symbols to Typescript --- js/symbols.js | 11 ----------- js/symbols.ts | 24 ++++++++++++++++++++++++ 2 files changed, 24 insertions(+), 11 deletions(-) delete mode 100644 js/symbols.js create mode 100644 js/symbols.ts diff --git a/js/symbols.js b/js/symbols.js deleted file mode 100644 index 059b8d8..0000000 --- a/js/symbols.js +++ /dev/null @@ -1,11 +0,0 @@ -export var SYMBOLS = { - 0xD010: 'KBD', - 0xD011: 'KBDCR', - 0xD012: 'DSP', - 0xD013: 'DSPCR', - - 0xFF1F: 'GETLINE', - 0xFFEF: 'ECHO', - 0xFFDC: 'PRBYTE', - 0xFFE5: 'PRHEX' -}; diff --git a/js/symbols.ts b/js/symbols.ts new file mode 100644 index 0000000..bcdbe6b --- /dev/null +++ b/js/symbols.ts @@ -0,0 +1,24 @@ +/* Copyright 2010-2023 Will Scullin + * + * Permission to use, copy, modify, distribute, and sell this software and its + * documentation for any purpose is hereby granted without fee, provided that + * the above copyright notice appear in all copies and that both that + * copyright notice and this permission notice appear in supporting + * documentation. No representations are made about the suitability of this + * software for any purpose. It is provided "as is" without express or + * implied warranty. + */ + +import type { address } from "./types"; + +export const SYMBOLS: Record = { + 0xd010: "KBD", + 0xd011: "KBDCR", + 0xd012: "DSP", + 0xd013: "DSPCR", + + 0xff1f: "GETLINE", + 0xffef: "ECHO", + 0xffdc: "PRBYTE", + 0xffe5: "PRHEX", +};