ac6502 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +261 -0
- package/dist/components/CPU.js +1170 -0
- package/dist/components/CPU.js.map +1 -0
- package/dist/components/Cart.js +23 -0
- package/dist/components/Cart.js.map +1 -0
- package/dist/components/IO/Empty.js +19 -0
- package/dist/components/IO/Empty.js.map +1 -0
- package/dist/components/IO/GPIOAttachments/GPIOAttachment.js +71 -0
- package/dist/components/IO/GPIOAttachments/GPIOAttachment.js.map +1 -0
- package/dist/components/IO/GPIOAttachments/GPIOJoystickAttachment.js +90 -0
- package/dist/components/IO/GPIOAttachments/GPIOJoystickAttachment.js.map +1 -0
- package/dist/components/IO/GPIOAttachments/GPIOKeyboardEncoderAttachment.js +489 -0
- package/dist/components/IO/GPIOAttachments/GPIOKeyboardEncoderAttachment.js.map +1 -0
- package/dist/components/IO/GPIOAttachments/GPIOKeyboardMatrixAttachment.js +274 -0
- package/dist/components/IO/GPIOAttachments/GPIOKeyboardMatrixAttachment.js.map +1 -0
- package/dist/components/IO/GPIOCard.js +597 -0
- package/dist/components/IO/GPIOCard.js.map +1 -0
- package/dist/components/IO/InputBoard.js +19 -0
- package/dist/components/IO/InputBoard.js.map +1 -0
- package/dist/components/IO/LCDCard.js +19 -0
- package/dist/components/IO/LCDCard.js.map +1 -0
- package/dist/components/IO/RAMCard.js +63 -0
- package/dist/components/IO/RAMCard.js.map +1 -0
- package/dist/components/IO/RTCCard.js +483 -0
- package/dist/components/IO/RTCCard.js.map +1 -0
- package/dist/components/IO/SerialCard.js +282 -0
- package/dist/components/IO/SerialCard.js.map +1 -0
- package/dist/components/IO/SoundCard.js +620 -0
- package/dist/components/IO/SoundCard.js.map +1 -0
- package/dist/components/IO/StorageCard.js +428 -0
- package/dist/components/IO/StorageCard.js.map +1 -0
- package/dist/components/IO/VGACard.js +9 -0
- package/dist/components/IO/VGACard.js.map +1 -0
- package/dist/components/IO/VideoCard.js +623 -0
- package/dist/components/IO/VideoCard.js.map +1 -0
- package/dist/components/IO.js +3 -0
- package/dist/components/IO.js.map +1 -0
- package/dist/components/Machine.js +310 -0
- package/dist/components/Machine.js.map +1 -0
- package/dist/components/RAM.js +24 -0
- package/dist/components/RAM.js.map +1 -0
- package/dist/components/ROM.js +23 -0
- package/dist/components/ROM.js.map +1 -0
- package/dist/index.js +441 -0
- package/dist/index.js.map +1 -0
- package/dist/tests/CPU.test.js +1626 -0
- package/dist/tests/CPU.test.js.map +1 -0
- package/dist/tests/Cart.test.js +119 -0
- package/dist/tests/Cart.test.js.map +1 -0
- package/dist/tests/IO/GPIOAttachments/GPIOAttachment.test.js +339 -0
- package/dist/tests/IO/GPIOAttachments/GPIOAttachment.test.js.map +1 -0
- package/dist/tests/IO/GPIOAttachments/GPIOJoystickAttachment.test.js +126 -0
- package/dist/tests/IO/GPIOAttachments/GPIOJoystickAttachment.test.js.map +1 -0
- package/dist/tests/IO/GPIOAttachments/GPIOKeyboardEncoderAttachment.test.js +779 -0
- package/dist/tests/IO/GPIOAttachments/GPIOKeyboardEncoderAttachment.test.js.map +1 -0
- package/dist/tests/IO/GPIOAttachments/GPIOKeyboardMatrixAttachment.test.js +355 -0
- package/dist/tests/IO/GPIOAttachments/GPIOKeyboardMatrixAttachment.test.js.map +1 -0
- package/dist/tests/IO/GPIOCard.test.js +503 -0
- package/dist/tests/IO/GPIOCard.test.js.map +1 -0
- package/dist/tests/IO/RAMCard.test.js +229 -0
- package/dist/tests/IO/RAMCard.test.js.map +1 -0
- package/dist/tests/IO/RTCCard.test.js +177 -0
- package/dist/tests/IO/RTCCard.test.js.map +1 -0
- package/dist/tests/IO/SerialCard.test.js +423 -0
- package/dist/tests/IO/SerialCard.test.js.map +1 -0
- package/dist/tests/IO/SoundCard.test.js +528 -0
- package/dist/tests/IO/SoundCard.test.js.map +1 -0
- package/dist/tests/IO/StorageCard.test.js +647 -0
- package/dist/tests/IO/StorageCard.test.js.map +1 -0
- package/dist/tests/IO/VideoCard.test.js +549 -0
- package/dist/tests/IO/VideoCard.test.js.map +1 -0
- package/dist/tests/Machine.test.js +383 -0
- package/dist/tests/Machine.test.js.map +1 -0
- package/dist/tests/RAM.test.js +160 -0
- package/dist/tests/RAM.test.js.map +1 -0
- package/dist/tests/ROM.test.js +123 -0
- package/dist/tests/ROM.test.js.map +1 -0
- package/jest.config.cjs +9 -0
- package/package.json +43 -0
- package/src/components/CPU.ts +1371 -0
- package/src/components/Cart.ts +20 -0
- package/src/components/IO/GPIOAttachments/GPIOAttachment.ts +189 -0
- package/src/components/IO/GPIOAttachments/GPIOJoystickAttachment.ts +99 -0
- package/src/components/IO/GPIOAttachments/GPIOKeyboardEncoderAttachment.ts +465 -0
- package/src/components/IO/GPIOAttachments/GPIOKeyboardMatrixAttachment.ts +287 -0
- package/src/components/IO/GPIOCard.ts +677 -0
- package/src/components/IO/RAMCard.ts +68 -0
- package/src/components/IO/RTCCard.ts +518 -0
- package/src/components/IO/SerialCard.ts +335 -0
- package/src/components/IO/SoundCard.ts +711 -0
- package/src/components/IO/StorageCard.ts +473 -0
- package/src/components/IO/VideoCard.ts +730 -0
- package/src/components/IO.ts +11 -0
- package/src/components/Machine.ts +364 -0
- package/src/components/RAM.ts +23 -0
- package/src/components/ROM.ts +19 -0
- package/src/index.ts +474 -0
- package/src/tests/CPU.test.ts +2045 -0
- package/src/tests/Cart.test.ts +149 -0
- package/src/tests/IO/GPIOAttachments/GPIOAttachment.test.ts +413 -0
- package/src/tests/IO/GPIOAttachments/GPIOJoystickAttachment.test.ts +147 -0
- package/src/tests/IO/GPIOAttachments/GPIOKeyboardEncoderAttachment.test.ts +961 -0
- package/src/tests/IO/GPIOAttachments/GPIOKeyboardMatrixAttachment.test.ts +449 -0
- package/src/tests/IO/GPIOCard.test.ts +644 -0
- package/src/tests/IO/RAMCard.test.ts +284 -0
- package/src/tests/IO/RTCCard.test.ts +222 -0
- package/src/tests/IO/SerialCard.test.ts +530 -0
- package/src/tests/IO/SoundCard.test.ts +659 -0
- package/src/tests/IO/StorageCard.test.ts +787 -0
- package/src/tests/IO/VideoCard.test.ts +668 -0
- package/src/tests/Machine.test.ts +437 -0
- package/src/tests/RAM.test.ts +196 -0
- package/src/tests/ROM.test.ts +154 -0
- package/tsconfig.json +12 -0
|
@@ -0,0 +1,428 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
+
});
|
|
10
|
+
};
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.StorageCard = void 0;
|
|
13
|
+
const promises_1 = require("fs/promises");
|
|
14
|
+
const fs_1 = require("fs");
|
|
15
|
+
/**
|
|
16
|
+
* StorageCard - Emulates a Compact Flash card in 8-bit IDE mode
|
|
17
|
+
*
|
|
18
|
+
* Emulates a 128MB CF card with ATA-style register interface.
|
|
19
|
+
* Uses LBA (Logical Block Addressing) for sector access.
|
|
20
|
+
*
|
|
21
|
+
* Register Map (address & 0x07):
|
|
22
|
+
* $00: Data Register (read/write)
|
|
23
|
+
* $01: Error Register (read) / Feature Register (write)
|
|
24
|
+
* $02: Sector Count Register (read/write)
|
|
25
|
+
* $03: LBA0 Register (read/write) - bits 0-7 of LBA
|
|
26
|
+
* $04: LBA1 Register (read/write) - bits 8-15 of LBA
|
|
27
|
+
* $05: LBA2 Register (read/write) - bits 16-23 of LBA
|
|
28
|
+
* $06: LBA3 Register (read/write) - bits 24-27 of LBA + mode bits
|
|
29
|
+
* $07: Status Register (read) / Command Register (write)
|
|
30
|
+
*
|
|
31
|
+
* Supported Commands:
|
|
32
|
+
* 0x20, 0x21: Read Sector(s)
|
|
33
|
+
* 0x30, 0x31: Write Sector(s)
|
|
34
|
+
* 0xC0: Erase Sector
|
|
35
|
+
* 0xEC: Identify Drive
|
|
36
|
+
* 0xEF: Set Features (accepted but not implemented)
|
|
37
|
+
*/
|
|
38
|
+
class StorageCard {
|
|
39
|
+
constructor() {
|
|
40
|
+
// Data buffer (512 bytes)
|
|
41
|
+
this.buffer = Buffer.alloc(StorageCard.SECTOR_SIZE);
|
|
42
|
+
this.bufferIndex = 0;
|
|
43
|
+
this.commandDataSize = StorageCard.SECTOR_SIZE;
|
|
44
|
+
this.sectorOffset = 0;
|
|
45
|
+
// Registers
|
|
46
|
+
this.error = 0x00;
|
|
47
|
+
this.feature = 0x00;
|
|
48
|
+
this.sectorCount = 0x00;
|
|
49
|
+
this.lba0 = 0x00;
|
|
50
|
+
this.lba1 = 0x00;
|
|
51
|
+
this.lba2 = 0x00;
|
|
52
|
+
this.lba3 = 0xE0;
|
|
53
|
+
this.status = 0x00;
|
|
54
|
+
this.command = 0x00;
|
|
55
|
+
// State flags
|
|
56
|
+
this.isIdentifying = false;
|
|
57
|
+
this.isTransferring = false;
|
|
58
|
+
this.raiseIRQ = () => { };
|
|
59
|
+
this.raiseNMI = () => { };
|
|
60
|
+
// Initialize storage and identity buffers
|
|
61
|
+
this.storage = Buffer.alloc(StorageCard.STORAGE_SIZE, 0x00);
|
|
62
|
+
this.identity = Buffer.alloc(StorageCard.SECTOR_SIZE);
|
|
63
|
+
this.generateIdentity();
|
|
64
|
+
this.reset(true);
|
|
65
|
+
}
|
|
66
|
+
read(address) {
|
|
67
|
+
switch (address & 0x0007) {
|
|
68
|
+
case 0x00: // Data Register
|
|
69
|
+
return this.readBuffer();
|
|
70
|
+
case 0x01: // Error Register
|
|
71
|
+
return this.error;
|
|
72
|
+
case 0x02: // Sector Count Register
|
|
73
|
+
return this.sectorCount;
|
|
74
|
+
case 0x03: // LBA0 Register
|
|
75
|
+
return this.lba0;
|
|
76
|
+
case 0x04: // LBA1 Register
|
|
77
|
+
return this.lba1;
|
|
78
|
+
case 0x05: // LBA2 Register
|
|
79
|
+
return this.lba2;
|
|
80
|
+
case 0x06: // LBA3 Register
|
|
81
|
+
return this.lba3;
|
|
82
|
+
case 0x07: // Status Register
|
|
83
|
+
return this.status;
|
|
84
|
+
default:
|
|
85
|
+
return 0x00;
|
|
86
|
+
}
|
|
87
|
+
}
|
|
88
|
+
write(address, data) {
|
|
89
|
+
switch (address & 0x0007) {
|
|
90
|
+
case 0x00: // Data Register
|
|
91
|
+
this.writeBuffer(data);
|
|
92
|
+
break;
|
|
93
|
+
case 0x01: // Feature Register
|
|
94
|
+
this.feature = data;
|
|
95
|
+
break;
|
|
96
|
+
case 0x02: // Sector Count Register
|
|
97
|
+
this.sectorCount = data;
|
|
98
|
+
break;
|
|
99
|
+
case 0x03: // LBA0 Register
|
|
100
|
+
this.lba0 = data;
|
|
101
|
+
break;
|
|
102
|
+
case 0x04: // LBA1 Register
|
|
103
|
+
this.lba1 = data;
|
|
104
|
+
break;
|
|
105
|
+
case 0x05: // LBA2 Register
|
|
106
|
+
this.lba2 = data;
|
|
107
|
+
break;
|
|
108
|
+
case 0x06: // LBA3 Register
|
|
109
|
+
this.lba3 = (data & 0x0F) | 0xE0;
|
|
110
|
+
break;
|
|
111
|
+
case 0x07: // Command Register
|
|
112
|
+
this.command = data;
|
|
113
|
+
this.executeCommand();
|
|
114
|
+
break;
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
tick(frequency) {
|
|
118
|
+
// No timing behavior needed for this implementation
|
|
119
|
+
}
|
|
120
|
+
reset(coldStart) {
|
|
121
|
+
this.bufferIndex = 0x0000;
|
|
122
|
+
this.commandDataSize = StorageCard.SECTOR_SIZE;
|
|
123
|
+
this.sectorOffset = 0;
|
|
124
|
+
this.error = 0x00;
|
|
125
|
+
this.feature = 0x00;
|
|
126
|
+
this.sectorCount = 0x00;
|
|
127
|
+
this.lba0 = 0x00;
|
|
128
|
+
this.lba1 = 0x00;
|
|
129
|
+
this.lba2 = 0x00;
|
|
130
|
+
this.lba3 = 0xE0;
|
|
131
|
+
this.status = 0x00 | StorageCard.STATUS_RDY;
|
|
132
|
+
this.command = 0x00;
|
|
133
|
+
this.isIdentifying = false;
|
|
134
|
+
this.isTransferring = false;
|
|
135
|
+
this.buffer.fill(0x00);
|
|
136
|
+
}
|
|
137
|
+
//
|
|
138
|
+
// Private methods
|
|
139
|
+
//
|
|
140
|
+
executeCommand() {
|
|
141
|
+
// New command so clear errors and flags
|
|
142
|
+
this.status &= ~StorageCard.STATUS_ERR;
|
|
143
|
+
this.status &= ~StorageCard.STATUS_DRQ;
|
|
144
|
+
this.error = 0x00;
|
|
145
|
+
this.commandDataSize = StorageCard.SECTOR_SIZE * this.sectorCount;
|
|
146
|
+
this.bufferIndex = 0;
|
|
147
|
+
this.sectorOffset = 0;
|
|
148
|
+
// Check if already executing a command
|
|
149
|
+
if (this.isTransferring || this.isIdentifying) {
|
|
150
|
+
this.status |= StorageCard.STATUS_ERR;
|
|
151
|
+
this.error |= StorageCard.ERR_ABRT;
|
|
152
|
+
return;
|
|
153
|
+
}
|
|
154
|
+
switch (this.command) {
|
|
155
|
+
case 0xC0: { // Erase sector
|
|
156
|
+
if (!this.sectorValid()) {
|
|
157
|
+
this.status |= StorageCard.STATUS_ERR;
|
|
158
|
+
this.error |= StorageCard.ERR_ABRT | StorageCard.ERR_IDNF;
|
|
159
|
+
}
|
|
160
|
+
else {
|
|
161
|
+
const offset = this.sectorIndex() * StorageCard.SECTOR_SIZE;
|
|
162
|
+
this.storage.fill(0x00, offset, offset + StorageCard.SECTOR_SIZE);
|
|
163
|
+
}
|
|
164
|
+
break;
|
|
165
|
+
}
|
|
166
|
+
case 0xEC: { // Identify drive
|
|
167
|
+
this.identity.copy(this.buffer, 0, 0, StorageCard.SECTOR_SIZE);
|
|
168
|
+
this.commandDataSize = StorageCard.SECTOR_SIZE;
|
|
169
|
+
this.status |= StorageCard.STATUS_DRQ;
|
|
170
|
+
this.isIdentifying = true;
|
|
171
|
+
break;
|
|
172
|
+
}
|
|
173
|
+
case 0x20: // Read sector
|
|
174
|
+
case 0x21:
|
|
175
|
+
if (!this.sectorValid()) {
|
|
176
|
+
this.status |= StorageCard.STATUS_ERR;
|
|
177
|
+
this.error |= StorageCard.ERR_ABRT | StorageCard.ERR_IDNF;
|
|
178
|
+
}
|
|
179
|
+
else {
|
|
180
|
+
// Load first sector into buffer
|
|
181
|
+
const offset = this.sectorIndex() * StorageCard.SECTOR_SIZE;
|
|
182
|
+
this.storage.copy(this.buffer, 0, offset, offset + StorageCard.SECTOR_SIZE);
|
|
183
|
+
this.status |= StorageCard.STATUS_DRQ;
|
|
184
|
+
this.isTransferring = true;
|
|
185
|
+
}
|
|
186
|
+
break;
|
|
187
|
+
case 0xEF: // Set features
|
|
188
|
+
// We don't support setting features but accept them without error
|
|
189
|
+
break;
|
|
190
|
+
case 0x30: // Write sector
|
|
191
|
+
case 0x31:
|
|
192
|
+
if (!this.sectorValid()) {
|
|
193
|
+
this.status |= StorageCard.STATUS_ERR;
|
|
194
|
+
this.error |= StorageCard.ERR_ABRT | StorageCard.ERR_IDNF;
|
|
195
|
+
}
|
|
196
|
+
else {
|
|
197
|
+
this.status |= StorageCard.STATUS_DRQ;
|
|
198
|
+
this.isTransferring = true;
|
|
199
|
+
}
|
|
200
|
+
break;
|
|
201
|
+
default:
|
|
202
|
+
// Unsupported command
|
|
203
|
+
this.status |= StorageCard.STATUS_ERR;
|
|
204
|
+
this.error |= StorageCard.ERR_ABRT;
|
|
205
|
+
break;
|
|
206
|
+
}
|
|
207
|
+
}
|
|
208
|
+
readBuffer() {
|
|
209
|
+
if (this.isIdentifying) {
|
|
210
|
+
const data = this.buffer[this.bufferIndex];
|
|
211
|
+
if (this.bufferIndex < this.commandDataSize - 1) {
|
|
212
|
+
this.bufferIndex++;
|
|
213
|
+
}
|
|
214
|
+
else {
|
|
215
|
+
this.bufferIndex = 0;
|
|
216
|
+
this.isIdentifying = false;
|
|
217
|
+
this.status &= ~StorageCard.STATUS_DRQ;
|
|
218
|
+
}
|
|
219
|
+
return data;
|
|
220
|
+
}
|
|
221
|
+
else if (this.isTransferring) {
|
|
222
|
+
const data = this.buffer[this.bufferIndex];
|
|
223
|
+
if (this.bufferIndex < StorageCard.SECTOR_SIZE - 1) {
|
|
224
|
+
this.bufferIndex++;
|
|
225
|
+
}
|
|
226
|
+
else {
|
|
227
|
+
this.bufferIndex = 0;
|
|
228
|
+
this.sectorOffset++;
|
|
229
|
+
if (this.sectorOffset < this.sectorCount) {
|
|
230
|
+
// Load the next sector
|
|
231
|
+
const offset = (this.sectorIndex() + this.sectorOffset) * StorageCard.SECTOR_SIZE;
|
|
232
|
+
this.storage.copy(this.buffer, 0, offset, offset + StorageCard.SECTOR_SIZE);
|
|
233
|
+
}
|
|
234
|
+
else {
|
|
235
|
+
this.isTransferring = false;
|
|
236
|
+
this.status &= ~StorageCard.STATUS_DRQ;
|
|
237
|
+
}
|
|
238
|
+
}
|
|
239
|
+
return data;
|
|
240
|
+
}
|
|
241
|
+
else {
|
|
242
|
+
return 0x00;
|
|
243
|
+
}
|
|
244
|
+
}
|
|
245
|
+
writeBuffer(value) {
|
|
246
|
+
this.buffer[this.bufferIndex] = value;
|
|
247
|
+
if (this.bufferIndex < StorageCard.SECTOR_SIZE - 1) {
|
|
248
|
+
this.bufferIndex++;
|
|
249
|
+
}
|
|
250
|
+
else {
|
|
251
|
+
this.bufferIndex = 0;
|
|
252
|
+
// Write the current sector to storage
|
|
253
|
+
const offset = (this.sectorIndex() + this.sectorOffset) * StorageCard.SECTOR_SIZE;
|
|
254
|
+
this.buffer.copy(this.storage, offset, 0, StorageCard.SECTOR_SIZE);
|
|
255
|
+
this.sectorOffset++;
|
|
256
|
+
// Check if all sectors have been written
|
|
257
|
+
if (this.sectorOffset >= this.sectorCount) {
|
|
258
|
+
this.isTransferring = false;
|
|
259
|
+
this.status &= ~StorageCard.STATUS_DRQ;
|
|
260
|
+
}
|
|
261
|
+
}
|
|
262
|
+
}
|
|
263
|
+
sectorIndex() {
|
|
264
|
+
return ((this.lba3 & 0x0F) << 24) | (this.lba2 << 16) | (this.lba1 << 8) | this.lba0;
|
|
265
|
+
}
|
|
266
|
+
sectorValid() {
|
|
267
|
+
return this.sectorIndex() < StorageCard.SECTOR_COUNT;
|
|
268
|
+
}
|
|
269
|
+
generateIdentity() {
|
|
270
|
+
// Generate emulated 128MB CF card identity
|
|
271
|
+
// Based on real Promaster 128MB CF card data
|
|
272
|
+
// Fill with zeros first
|
|
273
|
+
this.identity.fill(0x00);
|
|
274
|
+
// Word 0: General configuration
|
|
275
|
+
this.identity[0] = 0x84;
|
|
276
|
+
this.identity[1] = 0x8A; // Removable Disk
|
|
277
|
+
// Word 1: Number of cylinders
|
|
278
|
+
this.identity[2] = 0x00;
|
|
279
|
+
this.identity[3] = 0x04;
|
|
280
|
+
// Word 2: Reserved
|
|
281
|
+
this.identity[4] = 0x00;
|
|
282
|
+
this.identity[5] = 0x00;
|
|
283
|
+
// Word 3: Number of heads
|
|
284
|
+
this.identity[6] = 0x08;
|
|
285
|
+
this.identity[7] = 0x00;
|
|
286
|
+
// Word 4: Unformatted bytes per track
|
|
287
|
+
this.identity[8] = 0x00;
|
|
288
|
+
this.identity[9] = 0x40;
|
|
289
|
+
// Word 5: Unformatted bytes per sector
|
|
290
|
+
this.identity[10] = 0x00;
|
|
291
|
+
this.identity[11] = 0x02;
|
|
292
|
+
// Word 6: Sectors per track
|
|
293
|
+
this.identity[12] = 0x20;
|
|
294
|
+
this.identity[13] = 0x00;
|
|
295
|
+
// Words 7-9: Reserved
|
|
296
|
+
this.identity[14] = 0x04;
|
|
297
|
+
this.identity[15] = 0x00;
|
|
298
|
+
this.identity[16] = 0x00;
|
|
299
|
+
this.identity[17] = 0x00;
|
|
300
|
+
this.identity[18] = 0x00;
|
|
301
|
+
this.identity[19] = 0x00;
|
|
302
|
+
// Words 10-19: Serial number (20 ASCII characters)
|
|
303
|
+
const serial = 'ACWD6502EMUCF1010101';
|
|
304
|
+
for (let i = 0; i < serial.length; i++) {
|
|
305
|
+
this.identity[20 + i] = serial.charCodeAt(i);
|
|
306
|
+
}
|
|
307
|
+
// Word 20: Buffer type
|
|
308
|
+
this.identity[40] = 0x01;
|
|
309
|
+
this.identity[41] = 0x00;
|
|
310
|
+
// Word 21: Buffer size in 512 byte increments
|
|
311
|
+
this.identity[42] = 0x04;
|
|
312
|
+
this.identity[43] = 0x00;
|
|
313
|
+
// Word 22: ECC bytes
|
|
314
|
+
this.identity[44] = 0x04;
|
|
315
|
+
this.identity[45] = 0x00;
|
|
316
|
+
// Words 23-26: Firmware revision (8 ASCII characters)
|
|
317
|
+
const firmware = '1.0 ';
|
|
318
|
+
for (let i = 0; i < firmware.length; i++) {
|
|
319
|
+
this.identity[46 + i] = firmware.charCodeAt(i);
|
|
320
|
+
}
|
|
321
|
+
// Words 27-46: Model number (40 ASCII characters)
|
|
322
|
+
const model = 'ACWD6502EMUCF ';
|
|
323
|
+
for (let i = 0; i < model.length; i++) {
|
|
324
|
+
this.identity[54 + i] = model.charCodeAt(i);
|
|
325
|
+
}
|
|
326
|
+
// Word 47: Multiple sector setting
|
|
327
|
+
this.identity[94] = 0x01;
|
|
328
|
+
this.identity[95] = 0x00;
|
|
329
|
+
// Word 48: Double word not supported
|
|
330
|
+
this.identity[96] = 0x00;
|
|
331
|
+
this.identity[97] = 0x00;
|
|
332
|
+
// Word 49: Capabilities (LBA supported)
|
|
333
|
+
this.identity[98] = 0x00;
|
|
334
|
+
this.identity[99] = 0x02;
|
|
335
|
+
// Word 50: Reserved
|
|
336
|
+
this.identity[100] = 0x00;
|
|
337
|
+
this.identity[101] = 0x00;
|
|
338
|
+
// Word 51: PIO data transfer cycle timing
|
|
339
|
+
this.identity[102] = 0x00;
|
|
340
|
+
this.identity[103] = 0x02;
|
|
341
|
+
// Word 52: DMA transfer cycle timing
|
|
342
|
+
this.identity[104] = 0x00;
|
|
343
|
+
this.identity[105] = 0x00;
|
|
344
|
+
// Word 53: Field validity
|
|
345
|
+
this.identity[106] = 0x01;
|
|
346
|
+
this.identity[107] = 0x00;
|
|
347
|
+
// Word 54: Current number of cylinders
|
|
348
|
+
this.identity[108] = 0x00;
|
|
349
|
+
this.identity[109] = 0x04;
|
|
350
|
+
// Word 55: Current number of heads
|
|
351
|
+
this.identity[110] = 0x08;
|
|
352
|
+
this.identity[111] = 0x00;
|
|
353
|
+
// Word 56: Current sectors per track
|
|
354
|
+
this.identity[112] = 0x20;
|
|
355
|
+
this.identity[113] = 0x00;
|
|
356
|
+
// Words 57-58: Current capacity in sectors
|
|
357
|
+
this.identity[114] = 0x00;
|
|
358
|
+
this.identity[115] = 0x00;
|
|
359
|
+
this.identity[116] = 0x04;
|
|
360
|
+
this.identity[117] = 0x00;
|
|
361
|
+
// Word 59: Multiple sector setting
|
|
362
|
+
this.identity[118] = 0x01;
|
|
363
|
+
this.identity[119] = 0x01;
|
|
364
|
+
// Words 60-61: Total number of sectors in LBA mode
|
|
365
|
+
this.identity[120] = 0x00;
|
|
366
|
+
this.identity[121] = 0x00;
|
|
367
|
+
this.identity[122] = 0x04;
|
|
368
|
+
this.identity[123] = 0x00;
|
|
369
|
+
// Remaining words are zero
|
|
370
|
+
}
|
|
371
|
+
/**
|
|
372
|
+
* Load storage data from a file
|
|
373
|
+
* If the file doesn't exist, storage remains empty (initialized to 0x00)
|
|
374
|
+
*/
|
|
375
|
+
loadFromFile(filePath) {
|
|
376
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
377
|
+
try {
|
|
378
|
+
if ((0, fs_1.existsSync)(filePath)) {
|
|
379
|
+
const data = yield (0, promises_1.readFile)(filePath);
|
|
380
|
+
// Ensure the file is exactly the expected size
|
|
381
|
+
if (data.length === StorageCard.STORAGE_SIZE) {
|
|
382
|
+
data.copy(this.storage, 0, 0, StorageCard.STORAGE_SIZE);
|
|
383
|
+
console.log(`Storage loaded from: ${filePath}`);
|
|
384
|
+
}
|
|
385
|
+
else {
|
|
386
|
+
console.warn(`Warning: Storage file size mismatch. Expected ${StorageCard.STORAGE_SIZE} bytes, got ${data.length} bytes.`);
|
|
387
|
+
console.warn('Storage will remain empty.');
|
|
388
|
+
}
|
|
389
|
+
}
|
|
390
|
+
else {
|
|
391
|
+
console.log(`Storage file not found: ${filePath}`);
|
|
392
|
+
console.log('A new storage file will be created on exit.');
|
|
393
|
+
}
|
|
394
|
+
}
|
|
395
|
+
catch (error) {
|
|
396
|
+
console.error('Error loading storage file:', error);
|
|
397
|
+
}
|
|
398
|
+
});
|
|
399
|
+
}
|
|
400
|
+
/**
|
|
401
|
+
* Save storage data to a file
|
|
402
|
+
*/
|
|
403
|
+
saveToFile(filePath) {
|
|
404
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
405
|
+
try {
|
|
406
|
+
yield (0, promises_1.writeFile)(filePath, this.storage);
|
|
407
|
+
console.log(`Storage saved to: ${filePath}`);
|
|
408
|
+
}
|
|
409
|
+
catch (error) {
|
|
410
|
+
console.error('Error saving storage file:', error);
|
|
411
|
+
}
|
|
412
|
+
});
|
|
413
|
+
}
|
|
414
|
+
}
|
|
415
|
+
exports.StorageCard = StorageCard;
|
|
416
|
+
// Constants
|
|
417
|
+
StorageCard.STORAGE_SIZE = 128 * 1024 * 1024; // 128MB
|
|
418
|
+
StorageCard.SECTOR_SIZE = 512;
|
|
419
|
+
StorageCard.SECTOR_COUNT = StorageCard.STORAGE_SIZE / StorageCard.SECTOR_SIZE; // 262144 sectors
|
|
420
|
+
// Status Register Flags
|
|
421
|
+
StorageCard.STATUS_ERR = 0x01; // Error
|
|
422
|
+
StorageCard.STATUS_DRQ = 0x08; // Data Request
|
|
423
|
+
StorageCard.STATUS_RDY = 0x40; // Ready
|
|
424
|
+
// Error Register Flags
|
|
425
|
+
StorageCard.ERR_AMNF = 0x01; // Address Mark Not Found
|
|
426
|
+
StorageCard.ERR_ABRT = 0x04; // Aborted Command
|
|
427
|
+
StorageCard.ERR_IDNF = 0x10; // ID Not Found
|
|
428
|
+
//# sourceMappingURL=StorageCard.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"StorageCard.js","sourceRoot":"","sources":["../../../src/components/IO/StorageCard.ts"],"names":[],"mappings":";;;;;;;;;;;;AACA,0CAAiD;AACjD,2BAA+B;AAE/B;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,MAAa,WAAW;IA6CtB;QAxBA,0BAA0B;QAClB,WAAM,GAAW,MAAM,CAAC,KAAK,CAAC,WAAW,CAAC,WAAW,CAAC,CAAA;QACtD,gBAAW,GAAW,CAAC,CAAA;QACvB,oBAAe,GAAW,WAAW,CAAC,WAAW,CAAA;QACjD,iBAAY,GAAW,CAAC,CAAA;QAEhC,YAAY;QACJ,UAAK,GAAW,IAAI,CAAA;QACpB,YAAO,GAAW,IAAI,CAAA;QACtB,gBAAW,GAAW,IAAI,CAAA;QAC1B,SAAI,GAAW,IAAI,CAAA;QACnB,SAAI,GAAW,IAAI,CAAA;QACnB,SAAI,GAAW,IAAI,CAAA;QACnB,SAAI,GAAW,IAAI,CAAA;QACnB,WAAM,GAAW,IAAI,CAAA;QACrB,YAAO,GAAW,IAAI,CAAA;QAE9B,cAAc;QACN,kBAAa,GAAY,KAAK,CAAA;QAC9B,mBAAc,GAAY,KAAK,CAAA;QAEvC,aAAQ,GAAG,GAAG,EAAE,GAAE,CAAC,CAAA;QACnB,aAAQ,GAAG,GAAG,EAAE,GAAE,CAAC,CAAA;QAGjB,0CAA0C;QAC1C,IAAI,CAAC,OAAO,GAAG,MAAM,CAAC,KAAK,CAAC,WAAW,CAAC,YAAY,EAAE,IAAI,CAAC,CAAA;QAC3D,IAAI,CAAC,QAAQ,GAAG,MAAM,CAAC,KAAK,CAAC,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AAA;gBACvC,OAAO,CAAC,GAAG,CAAC,qBAAqB,QAAQ,EAAE,CAAC,CAAA;YAC9C,CAAC;YAAC,OAAO,KAAK,EAAE,CAAC;gBACf,OAAO,CAAC,KAAK,CAAC,4BAA4B,EAAE,KAAK,CAAC,CAAA;YACpD,CAAC;QACH,CAAC;KAAA;;AA3bH,kCA6bC;AA3bC,YAAY;AACY,wBAAY,GAAG,GAAG,GAAG,IAAI,GAAG,IAAI,AAApB,CAAoB,CAAE,QAAQ;AAC1C,uBAAW,GAAG,GAAG,AAAN,CAAM;AACjB,wBAAY,GAAG,WAAW,CAAC,YAAY,GAAG,WAAW,CAAC,WAAW,AAArD,CAAqD,CAAE,iBAAiB;AAE5G,wBAAwB;AACA,sBAAU,GAAG,IAAI,AAAP,CAAO,CAAE,QAAQ;AAC3B,sBAAU,GAAG,IAAI,AAAP,CAAO,CAAE,eAAe;AAClC,sBAAU,GAAG,IAAI,AAAP,CAAO,CAAE,QAAQ;AAEnD,uBAAuB;AACC,oBAAQ,GAAG,IAAI,AAAP,CAAO,CAAI,yBAAyB;AAC5C,oBAAQ,GAAG,IAAI,AAAP,CAAO,CAAI,kBAAkB;AACrC,oBAAQ,GAAG,IAAI,AAAP,CAAO,CAAI,eAAe"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.VGACard = void 0;
|
|
4
|
+
const VideoCard_1 = require("./VideoCard");
|
|
5
|
+
class VGACard extends VideoCard_1.VideoCard {
|
|
6
|
+
}
|
|
7
|
+
exports.VGACard = VGACard;
|
|
8
|
+
VGACard.DESCRIPTION = { className: 'VGACard', title: 'VGA Card' };
|
|
9
|
+
//# sourceMappingURL=VGACard.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"VGACard.js","sourceRoot":"","sources":["../../../src/components/IO/VGACard.ts"],"names":[],"mappings":";;;AACA,2CAAuC;AAEvC,MAAa,OAAQ,SAAQ,qBAAS;;AAAtC,0BAIC;AAFQ,mBAAW,GAAkB,EAAE,SAAS,EAAE,SAAS,EAAE,KAAK,EAAE,UAAU,EAAE,CAAA"}
|