diff --git a/src/common/analysis.ts b/src/common/analysis.ts index 9355a8e3..09690c3e 100644 --- a/src/common/analysis.ts +++ b/src/common/analysis.ts @@ -134,6 +134,7 @@ abstract class CodeAnalyzer6502 implements CodeAnalyzer { } break; // TODO: only Apple2 (vapor lock) + /* case 0xad: if (lob == 0x61 && hib == 0xc0) { // LDA $C061 minclocks = 0; @@ -141,6 +142,7 @@ abstract class CodeAnalyzer6502 implements CodeAnalyzer { meta.minCycles = meta.maxCycles = 0; } break; + */ case 0x20: // JSR // TODO: handle bare RTS case minclocks += meta.minCycles; diff --git a/src/worker/workermain.ts b/src/worker/workermain.ts index 959a7687..a1840e82 100644 --- a/src/worker/workermain.ts +++ b/src/worker/workermain.ts @@ -243,14 +243,14 @@ var PLATFORM_PARAMS = { cfgfile: 'apple2.cfg', libargs: ['apple2.lib'], }, - 'atari8-800xl': { + 'atari8-800xl.disk': { arch: '6502', define: ['__ATARI__'], cfgfile: 'atari.cfg', libargs: ['atari.lib'], fastbasic_cfgfile: 'fastbasic-cart.cfg', }, - 'atari8-800xl.cart': { + 'atari8-800xl': { arch: '6502', define: ['__ATARI__'], cfgfile: 'atari-cart.cfg', @@ -1753,10 +1753,11 @@ function compileInlineASM(code:string, platform, options, errors, asmlines) { return code; } +import * as hdltypes from '../common/hdl/hdltypes'; +import * as vxmlparser from '../common/hdl/vxmlparser'; + function compileVerilator(step:BuildStep) { loadNative("verilator_bin"); - const hdltypes = require('../common/hdl/hdltypes'); - const vxmlparser = require('../common/hdl/vxmlparser'); var platform = step.platform || 'verilog'; var errors : WorkerError[] = []; gatherFiles(step); @@ -2789,12 +2790,13 @@ function compileFastBasic(step:BuildStep) { }; } +import * as basic_compiler from '../common/basic/compiler'; + function compileBASIC(step:BuildStep) { var jsonpath = step.path + ".json"; gatherFiles(step); if (staleFiles(step, [jsonpath])) { - const compiler = require('../common/basic/compiler'); - var parser = new compiler.BASICParser(); + var parser = new basic_compiler.BASICParser(); var code = getWorkFileAsString(step.path); try { var ast = parser.parseFile(code, step.path); diff --git a/test/cli/testplatforms.js b/test/cli/testplatforms.js index f48bacaf..ddb181e6 100644 --- a/test/cli/testplatforms.js +++ b/test/cli/testplatforms.js @@ -40,6 +40,7 @@ var _sms = require('gen/platform/sms.js'); var _c64 = require('gen/platform/c64.js'); var _vectrex = require('gen/platform/vectrex.js'); var _zx = require('gen/platform/zx.js'); +var _atari8 = require('gen/platform/atari8.js'); // @@ -360,4 +361,13 @@ describe('Platform Replay', () => { } }); }); + /* + it('Should run atari 800xl', async () => { + await testPlatform('atari8-800xl', 'siegegame.bin', 92, (platform, frameno) => { + if (frameno == 62) { + keycallback(Keys.VK_DOWN.c, Keys.VK_DOWN.c, 1); + } + }); + }); + */ }); diff --git a/test/roms/atari8-800xl/siegegame.bin b/test/roms/atari8-800xl/siegegame.bin new file mode 100644 index 00000000..45641334 Binary files /dev/null and b/test/roms/atari8-800xl/siegegame.bin differ