1
0
mirror of https://github.com/TomHarte/CLK.git synced 2025-11-02 02:16:18 +00:00

Compare commits

...

3 Commits
master ... Tube

Author SHA1 Message Date
Thomas Harte
71d5c58577 Introduce one-directional FIFO. 2025-10-30 22:23:01 -04:00
Thomas Harte
e0673e97a5 Slightly clean-up spacing. 2025-10-30 22:22:47 -04:00
Thomas Harte
746836c8ea Add Tube boot ROM. 2025-10-30 22:22:25 -04:00
5 changed files with 58 additions and 1 deletions

View File

@@ -831,12 +831,12 @@ public:
}
adc_.run_for(duration);
if constexpr (has_1770) {
// The WD1770 is nominally clocked at 8Mhz.
wd1770_.run_for(duration * 4);
}
//
// Questionably-clocked devices.
//
@@ -943,6 +943,7 @@ public:
return duration;
}
//
// ROM or RAM access.
//

View File

@@ -0,0 +1,37 @@
//
// Header.hpp
// Clock Signal
//
// Created by Thomas Harte on 30/10/2025.
// Copyright © 2025 Thomas Harte. All rights reserved.
//
#pragma once
namespace Acorn::Tube {
template <size_t length>
struct FIFO {
uint8_t status() const {
return
((read != write) ? 0x80 : 0x00) |
((write - read < length) ? 0x40 : 0x00);
}
void write(const uint8_t value) {
if(write - read == length) return;
buffer[write++] = value;
}
void read() {
const uint8_t result = buffer[read];
if(write != read) ++read;
}
private:
std::array<uint8_t, length> buffer;
uint32_t read = 0;
uint32_t write = 0;
};
}

View File

@@ -453,6 +453,14 @@ const std::vector<Description> &Description::all_roms() {
16_kb,
0x8314fed0u
},
{
BBCMicroTube110,
"BBCMicro",
"the Tube 1.10 Boot ROM",
"TUBE110.rom",
2_kb,
0x9ec2dbd0u
},
//
// ColecoVision.

View File

@@ -85,6 +85,7 @@ enum Name {
BBCMicroDFS226,
BBCMicroADFS130,
BBCMicroAdvancedDiscToolkit140,
BBCMicroTube110,
// ColecoVision.
ColecoVisionBIOS,

View File

@@ -1612,6 +1612,7 @@
4B49F0A823346F7A0045E6A6 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = Base; path = "Clock Signal/Base.lproj/MacintoshOptions.xib"; sourceTree = SOURCE_ROOT; };
4B4A75BC2EB2C55100EA398F /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = Base; path = Base.lproj/CompositeDynamicCropOptions.xib; sourceTree = "<group>"; };
4B4A75BF2EB399D700EA398F /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = Base; path = Base.lproj/DynamicCropOptions.xib; sourceTree = "<group>"; };
4B4A75C22EB43F1C00EA398F /* FIFO.hpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.h; path = FIFO.hpp; sourceTree = "<group>"; };
4B4A762E1DB1A3FA007AAE2E /* AY38910.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = AY38910.cpp; sourceTree = "<group>"; };
4B4A762F1DB1A3FA007AAE2E /* AY38910.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = AY38910.hpp; sourceTree = "<group>"; };
4B4B1A3A200198C900A0F866 /* KonamiSCC.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = KonamiSCC.cpp; sourceTree = "<group>"; };
@@ -3354,6 +3355,14 @@
path = uPD7002;
sourceTree = "<group>";
};
4B4A75C32EB43F1C00EA398F /* Tube */ = {
isa = PBXGroup;
children = (
4B4A75C22EB43F1C00EA398F /* FIFO.hpp */,
);
path = Tube;
sourceTree = "<group>";
};
4B4A762D1DB1A35C007AAE2E /* AY38910 */ = {
isa = PBXGroup;
children = (
@@ -4673,6 +4682,7 @@
4BB505682B962DDF0031C43C /* Acorn */ = {
isa = PBXGroup;
children = (
4B4A75C32EB43F1C00EA398F /* Tube */,
4BB505692B962DDF0031C43C /* Archimedes */,
4B710C8C2E77A3B20056BDF4 /* BBCMicro */,
4BB5056A2B962DDF0031C43C /* Electron */,