mirror of
https://github.com/TomHarte/CLK.git
synced 2025-01-23 11:30:24 +00:00
Removes many stray spaces.
This commit is contained in:
parent
770d7e90e9
commit
ee89be6730
@ -11,7 +11,7 @@
|
||||
using namespace Analyser::Dynamic;
|
||||
|
||||
MultiKeyboardMachine::MultiKeyboardMachine(const std::vector<std::unique_ptr<::Machine::DynamicMachine>> &machines) :
|
||||
keyboard_(machines_) {
|
||||
keyboard_(machines_) {
|
||||
for(const auto &machine: machines) {
|
||||
KeyboardMachine::Machine *keyboard_machine = machine->keyboard_machine();
|
||||
if(keyboard_machine) machines_.push_back(keyboard_machine);
|
||||
|
@ -80,7 +80,7 @@ Analyser::Static::TargetList Analyser::Static::Commodore::GetTargets(const Media
|
||||
target->memory_model = Target::MemoryModel::Unexpanded;
|
||||
std::ostringstream string_stream;
|
||||
string_stream << "LOAD\"" << (is_disk ? "*" : "") << "\"," << device << ",";
|
||||
if(files.front().is_basic()) {
|
||||
if(files.front().is_basic()) {
|
||||
string_stream << "0";
|
||||
} else {
|
||||
string_stream << "1";
|
||||
|
@ -63,9 +63,9 @@ class Accessor {
|
||||
#define z(v) (v & 7)
|
||||
|
||||
Instruction::Condition condition_table[] = {
|
||||
Instruction::Condition::NZ, Instruction::Condition::Z,
|
||||
Instruction::Condition::NC, Instruction::Condition::C,
|
||||
Instruction::Condition::PO, Instruction::Condition::PE,
|
||||
Instruction::Condition::NZ, Instruction::Condition::Z,
|
||||
Instruction::Condition::NC, Instruction::Condition::C,
|
||||
Instruction::Condition::PO, Instruction::Condition::PE,
|
||||
Instruction::Condition::P, Instruction::Condition::M
|
||||
};
|
||||
|
||||
|
@ -34,7 +34,7 @@ class AudioGenerator: public ::Outputs::Speaker::SampleSource {
|
||||
private:
|
||||
Concurrency::DeferringAsyncTaskQueue &audio_queue_;
|
||||
|
||||
unsigned int counters_[4] = {2, 1, 0, 0}; // create a slight phase offset for the three channels
|
||||
unsigned int counters_[4] = {2, 1, 0, 0}; // create a slight phase offset for the three channels
|
||||
unsigned int shift_registers_[4] = {0, 0, 0, 0};
|
||||
uint8_t control_registers_[4] = {0, 0, 0, 0};
|
||||
int16_t volume_ = 0;
|
||||
|
@ -85,7 +85,7 @@ Base::Base(Personality p) :
|
||||
}
|
||||
|
||||
TMS9918::TMS9918(Personality p):
|
||||
Base(p) {
|
||||
Base(p) {
|
||||
// crt_->set_video_signal(Outputs::Display::VideoSignal::RGB);
|
||||
crt_.set_visible_area(Outputs::Display::Rect(0.055f, 0.025f, 0.9f, 0.9f));
|
||||
|
||||
|
@ -391,7 +391,7 @@ class Base {
|
||||
/*
|
||||
Fetching routines follow below; they obey the following rules:
|
||||
|
||||
1) input is a start position and an end position; they should perform the proper
|
||||
1) input is a start position and an end position; they should perform the proper
|
||||
operations for the period: start <= time < end.
|
||||
2) times are measured relative to a 172-cycles-per-line clock (so: they directly
|
||||
count access windows on the TMS and Master System).
|
||||
@ -411,7 +411,7 @@ class Base {
|
||||
|
||||
Provided for the benefit of the methods below:
|
||||
|
||||
* the function external_slot(), which will perform any pending VRAM read/write.
|
||||
* the function external_slot(), which will perform any pending VRAM read/write.
|
||||
* the macros slot(n) and external_slot(n) which can be used to schedule those things inside a
|
||||
switch(start)-based implementation.
|
||||
|
||||
@ -752,14 +752,14 @@ class Base {
|
||||
fetch_tile_name(column+1, row_info) \
|
||||
sprite_y_read(location+5, sprite); \
|
||||
slot(location+6): \
|
||||
slot(location+7): \
|
||||
slot(location+7): \
|
||||
slot(location+8): \
|
||||
fetch_tile(column+1) \
|
||||
fetch_tile_name(column+2, row_info) \
|
||||
sprite_y_read(location+9, sprite+2); \
|
||||
slot(location+10): \
|
||||
slot(location+11): \
|
||||
slot(location+12): \
|
||||
slot(location+12): \
|
||||
fetch_tile(column+2) \
|
||||
fetch_tile_name(column+3, row_info) \
|
||||
sprite_y_read(location+13, sprite+4); \
|
||||
|
@ -253,7 +253,7 @@ uint8_t AY38910::get_data_output() {
|
||||
const uint8_t mask = port_handler_ ? port_handler_->get_port_input(selected_register_ == 15) : 0xff;
|
||||
|
||||
switch(selected_register_) {
|
||||
default: break;
|
||||
default: break;
|
||||
case 14: return mask & ((registers_[0x7] & 0x40) ? registers_[14] : 0xff);
|
||||
case 15: return mask & ((registers_[0x7] & 0x80) ? registers_[15] : 0xff);
|
||||
}
|
||||
@ -280,7 +280,7 @@ void AY38910::update_bus() {
|
||||
// Assume no output, unless this turns out to be a read.
|
||||
data_output_ = 0xff;
|
||||
switch(control_state_) {
|
||||
default: break;
|
||||
default: break;
|
||||
case LatchAddress: select_register(data_input_); break;
|
||||
case Write: set_register_value(data_input_); break;
|
||||
case Read: data_output_ = get_register_value(); break;
|
||||
|
@ -54,7 +54,7 @@ class DiskII:
|
||||
void run_for(const Cycles cycles);
|
||||
|
||||
/*!
|
||||
Supplies the image of the state machine (i.e. P6) ROM,
|
||||
Supplies the image of the state machine (i.e. P6) ROM,
|
||||
which dictates how the Disk II will respond to input.
|
||||
|
||||
To reduce processing costs, some assumptions are made by
|
||||
|
@ -36,8 +36,8 @@ std::vector<std::unique_ptr<Configurable::Option>> Configurable::standard_option
|
||||
if(mask & (DisplayRGB | DisplayComposite | DisplaySVideo)) {
|
||||
std::vector<std::string> display_options;
|
||||
if(mask & DisplayComposite) display_options.emplace_back("composite");
|
||||
if(mask & DisplaySVideo) display_options.emplace_back("svideo");
|
||||
if(mask & DisplayRGB) display_options.emplace_back("rgb");
|
||||
if(mask & DisplaySVideo) display_options.emplace_back("svideo");
|
||||
if(mask & DisplayRGB) display_options.emplace_back("rgb");
|
||||
options.emplace_back(new Configurable::ListOption("Display", "display", display_options));
|
||||
}
|
||||
if(mask & AutomaticTapeMotorControl) options.emplace_back(new Configurable::BooleanOption("Automatic Tape Motor Control", "autotapemotor"));
|
||||
|
@ -185,7 +185,7 @@ class ConcreteJoystick: public Joystick {
|
||||
// convenient hard-coded values. TODO: make these a function of time.
|
||||
using Type = Joystick::Input::Type;
|
||||
switch(input.type) {
|
||||
default: did_set_input(input, is_active ? 1.0f : 0.0f); break;
|
||||
default: did_set_input(input, is_active ? 1.0f : 0.0f); break;
|
||||
case Type::Left: did_set_input(Input(Type::Horizontal, input.info.control.index), is_active ? 0.1f : 0.5f); break;
|
||||
case Type::Right: did_set_input(Input(Type::Horizontal, input.info.control.index), is_active ? 0.9f : 0.5f); break;
|
||||
case Type::Up: did_set_input(Input(Type::Vertical, input.info.control.index), is_active ? 0.1f : 0.5f); break;
|
||||
@ -203,7 +203,7 @@ class ConcreteJoystick: public Joystick {
|
||||
// Otherwise apply a threshold test to convert to digital, with remapping from axes to digital inputs.
|
||||
using Type = Joystick::Input::Type;
|
||||
switch(input.type) {
|
||||
default: did_set_input(input, value > 0.5f); break;
|
||||
default: did_set_input(input, value > 0.5f); break;
|
||||
case Type::Horizontal:
|
||||
did_set_input(Input(Type::Left, input.info.control.index), value <= 0.25f);
|
||||
did_set_input(Input(Type::Right, input.info.control.index), value >= 0.75f);
|
||||
|
@ -1167,7 +1167,7 @@ Machine *Machine::AmstradCPC(const Analyser::Static::Target *target, const ROMMa
|
||||
using Target = Analyser::Static::AmstradCPC::Target;
|
||||
const Target *const cpc_target = dynamic_cast<const Target *>(target);
|
||||
switch(cpc_target->model) {
|
||||
default: return new AmstradCPC::ConcreteMachine<true>(*cpc_target, rom_fetcher);
|
||||
default: return new AmstradCPC::ConcreteMachine<true>(*cpc_target, rom_fetcher);
|
||||
case Target::Model::CPC464: return new AmstradCPC::ConcreteMachine<false>(*cpc_target, rom_fetcher);
|
||||
}
|
||||
}
|
||||
|
@ -123,7 +123,7 @@ template <Analyser::Static::AppleII::Target::Model model> class ConcreteMachine:
|
||||
void pick_card_messaging_group(AppleII::Card *card) {
|
||||
const bool is_every_cycle = is_every_cycle_card(card);
|
||||
std::vector<AppleII::Card *> &intended = is_every_cycle ? every_cycle_cards_ : just_in_time_cards_;
|
||||
std::vector<AppleII::Card *> &undesired = is_every_cycle ? just_in_time_cards_ : every_cycle_cards_;
|
||||
std::vector<AppleII::Card *> &undesired = is_every_cycle ? just_in_time_cards_ : every_cycle_cards_;
|
||||
|
||||
if(std::find(intended.begin(), intended.end(), card) != intended.end()) return;
|
||||
auto old_membership = std::find(undesired.begin(), undesired.end(), card);
|
||||
@ -154,7 +154,7 @@ template <Analyser::Static::AppleII::Target::Model model> class ConcreteMachine:
|
||||
|
||||
On a IIe with auxiliary memory the following orthogonal changes also need to be factored in:
|
||||
|
||||
0000 to 0200 : can be paged independently of the rest of RAM, other than part of the language card area which pages with it
|
||||
0000 to 0200 : can be paged independently of the rest of RAM, other than part of the language card area which pages with it
|
||||
0400 to 0800 : the text screen, can be configured to write to auxiliary RAM
|
||||
2000 to 4000 : the graphics screen, which can be configured to write to auxiliary RAM
|
||||
c100 to d000 : can be used to page an additional 3.75kb of ROM, replacing the IO area
|
||||
@ -308,16 +308,16 @@ template <Analyser::Static::AppleII::Target::Model model> class ConcreteMachine:
|
||||
public:
|
||||
ConcreteMachine(const Analyser::Static::AppleII::Target &target, const ROMMachine::ROMFetcher &rom_fetcher):
|
||||
m6502_(*this),
|
||||
video_bus_handler_(ram_, aux_ram_),
|
||||
video_(video_bus_handler_),
|
||||
audio_toggle_(audio_queue_),
|
||||
speaker_(audio_toggle_) {
|
||||
// The system's master clock rate.
|
||||
const float master_clock = 14318180.0;
|
||||
video_bus_handler_(ram_, aux_ram_),
|
||||
video_(video_bus_handler_),
|
||||
audio_toggle_(audio_queue_),
|
||||
speaker_(audio_toggle_) {
|
||||
// The system's master clock rate.
|
||||
const float master_clock = 14318180.0;
|
||||
|
||||
// This is where things get slightly convoluted: establish the machine as having a clock rate
|
||||
// equal to the number of cycles of work the 6502 will actually achieve. Which is less than
|
||||
// the master clock rate divided by 14 because every 65th cycle is extended by one seventh.
|
||||
// This is where things get slightly convoluted: establish the machine as having a clock rate
|
||||
// equal to the number of cycles of work the 6502 will actually achieve. Which is less than
|
||||
// the master clock rate divided by 14 because every 65th cycle is extended by one seventh.
|
||||
set_clock_rate((master_clock / 14.0) * 65.0 / (65.0 + 1.0 / 7.0));
|
||||
|
||||
// The speaker, however, should think it is clocked at half the master clock, per a general
|
||||
@ -334,8 +334,8 @@ template <Analyser::Static::AppleII::Target::Model model> class ConcreteMachine:
|
||||
Memory::Fuzz(aux_ram_, sizeof(aux_ram_));
|
||||
|
||||
// Add a couple of joysticks.
|
||||
joysticks_.emplace_back(new Joystick);
|
||||
joysticks_.emplace_back(new Joystick);
|
||||
joysticks_.emplace_back(new Joystick);
|
||||
joysticks_.emplace_back(new Joystick);
|
||||
|
||||
// Pick the required ROMs.
|
||||
using Target = Analyser::Static::AppleII::Target;
|
||||
|
@ -38,7 +38,7 @@ class TIA {
|
||||
|
||||
void set_sync(bool sync);
|
||||
void set_blank(bool blank);
|
||||
void reset_horizontal_counter(); // Reset is delayed by four cycles.
|
||||
void reset_horizontal_counter(); // Reset is delayed by four cycles.
|
||||
|
||||
/*!
|
||||
@returns the number of cycles between (current TIA time) + from_offset to the current or
|
||||
|
@ -76,7 +76,7 @@ class Joystick: public Inputs::ConcreteJoystick {
|
||||
}
|
||||
break;
|
||||
|
||||
case Input::Up: if(is_active) direction_ &= ~0x01; else direction_ |= 0x01; break;
|
||||
case Input::Up: if(is_active) direction_ &= ~0x01; else direction_ |= 0x01; break;
|
||||
case Input::Right: if(is_active) direction_ &= ~0x02; else direction_ |= 0x02; break;
|
||||
case Input::Down: if(is_active) direction_ &= ~0x04; else direction_ |= 0x04; break;
|
||||
case Input::Left: if(is_active) direction_ &= ~0x08; else direction_ |= 0x08; break;
|
||||
|
@ -34,7 +34,7 @@ enum Key: uint16_t {
|
||||
Key1 = key(0, 0x01), Key3 = key(0, 0x02), Key5 = key(0, 0x04), Key7 = key(0, 0x08),
|
||||
Key9 = key(0, 0x10), KeyPlus = key(0, 0x20), KeyGBP = key(0, 0x40), KeyDelete = key(0, 0x80),
|
||||
|
||||
KeyRestore = 0xfffd
|
||||
KeyRestore = 0xfffd
|
||||
#undef key
|
||||
};
|
||||
|
||||
|
@ -645,7 +645,7 @@ class ConcreteMachine:
|
||||
case 2: {
|
||||
// TODO:
|
||||
// b6 caps lock LED
|
||||
// b5 audio output
|
||||
// b5 audio output
|
||||
|
||||
// b4: cassette motor relay
|
||||
tape_player_.set_motor_control(!(value & 0x10));
|
||||
|
@ -57,7 +57,7 @@ class Joystick: public Inputs::ConcreteJoystick {
|
||||
switch(digital_input.type) {
|
||||
default: return;
|
||||
|
||||
case Input::Up: if(is_active) state_ &= ~0x01; else state_ |= 0x01; break;
|
||||
case Input::Up: if(is_active) state_ &= ~0x01; else state_ |= 0x01; break;
|
||||
case Input::Down: if(is_active) state_ &= ~0x02; else state_ |= 0x02; break;
|
||||
case Input::Left: if(is_active) state_ &= ~0x04; else state_ |= 0x04; break;
|
||||
case Input::Right: if(is_active) state_ &= ~0x08; else state_ |= 0x08; break;
|
||||
@ -383,9 +383,9 @@ class ConcreteMachine:
|
||||
private:
|
||||
static TI::TMS::Personality tms_personality_for_model(Analyser::Static::Sega::Target::Model model) {
|
||||
switch(model) {
|
||||
case Target::Model::SG1000: return TI::TMS::TMS9918A;
|
||||
case Target::Model::SG1000: return TI::TMS::TMS9918A;
|
||||
case Target::Model::MasterSystem: return TI::TMS::SMSVDP;
|
||||
case Target::Model::MasterSystem2: return TI::TMS::SMSVDP;
|
||||
case Target::Model::MasterSystem2: return TI::TMS::SMSVDP;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -29,10 +29,10 @@ uint16_t KeyboardMapper::mapped_key_for_key(Inputs::Keyboard::Key key) {
|
||||
BIND(Hyphen, KeyMinus); BIND(Equals, KeyEquals); BIND(BackSlash, KeyBackSlash);
|
||||
BIND(OpenSquareBracket, KeyOpenSquare); BIND(CloseSquareBracket, KeyCloseSquare);
|
||||
|
||||
BIND(BackSpace, KeyDelete); BIND(Delete, KeyDelete);
|
||||
BIND(BackSpace, KeyDelete); BIND(Delete, KeyDelete);
|
||||
|
||||
BIND(Semicolon, KeySemiColon); BIND(Quote, KeyQuote);
|
||||
BIND(Comma, KeyComma); BIND(FullStop, KeyFullStop); BIND(ForwardSlash, KeyForwardSlash);
|
||||
BIND(Comma, KeyComma); BIND(FullStop, KeyFullStop); BIND(ForwardSlash, KeyForwardSlash);
|
||||
|
||||
BIND(Escape, KeyEscape); BIND(Tab, KeyEscape);
|
||||
BIND(CapsLock, KeyControl); BIND(LeftControl, KeyControl); BIND(RightControl, KeyControl);
|
||||
|
@ -366,7 +366,7 @@ struct ActivityObserver: public Activity::Observer {
|
||||
BIND(VK_ForwardDelete, Delete);
|
||||
|
||||
BIND(VK_LeftArrow, Left); BIND(VK_RightArrow, Right);
|
||||
BIND(VK_DownArrow, Down); BIND(VK_UpArrow, Up);
|
||||
BIND(VK_DownArrow, Down); BIND(VK_UpArrow, Up);
|
||||
}
|
||||
#undef BIND
|
||||
|
||||
|
@ -169,7 +169,7 @@ static Analyser::Static::ZX8081::Target::MemoryModel ZX8081MemoryModelFromSize(K
|
||||
std::unique_ptr<Target> target(new Target);
|
||||
target->machine = Analyser::Machine::AppleII;
|
||||
switch(model) {
|
||||
default: target->model = Target::Model::II; break;
|
||||
default: target->model = Target::Model::II; break;
|
||||
case CSMachineAppleIIModelAppleIIPlus: target->model = Target::Model::IIplus; break;
|
||||
case CSMachineAppleIIModelAppleIIe: target->model = Target::Model::IIe; break;
|
||||
case CSMachineAppleIIModelAppleEnhancedIIe: target->model = Target::Model::EnhancedIIe; break;
|
||||
|
@ -141,7 +141,7 @@ class MachinePicker: NSObject {
|
||||
case 13: diskController = .thirteenSector
|
||||
case 16: diskController = .sixteenSector
|
||||
case 0: fallthrough
|
||||
default: diskController = .none
|
||||
default: diskController = .none
|
||||
}
|
||||
|
||||
return CSStaticAnalyser(appleIIModel: model, diskController: diskController)
|
||||
@ -162,7 +162,7 @@ class MachinePicker: NSObject {
|
||||
switch oricDiskInterfaceButton!.selectedTag() {
|
||||
case 1: diskInterface = .microdisc
|
||||
case 2: diskInterface = .pravetz
|
||||
default: break;
|
||||
default: break;
|
||||
|
||||
}
|
||||
var model: CSMachineOricModel = .oric1
|
||||
|
@ -303,7 +303,7 @@ class Z80MachineCycleTests: XCTestCase {
|
||||
MachineCycle(operation: .readOpcode, length: 4),
|
||||
MachineCycle(operation: .readOpcode, length: 4),
|
||||
MachineCycle(operation: .read, length: 3),
|
||||
MachineCycle(operation: .read, length: 3),
|
||||
MachineCycle(operation: .read, length: 3),
|
||||
MachineCycle(operation: .read, length: 3),
|
||||
MachineCycle(operation: .read, length: 3),
|
||||
]
|
||||
@ -318,7 +318,7 @@ class Z80MachineCycleTests: XCTestCase {
|
||||
MachineCycle(operation: .readOpcode, length: 4),
|
||||
MachineCycle(operation: .readOpcode, length: 4),
|
||||
MachineCycle(operation: .read, length: 3),
|
||||
MachineCycle(operation: .read, length: 3),
|
||||
MachineCycle(operation: .read, length: 3),
|
||||
MachineCycle(operation: .write, length: 3),
|
||||
MachineCycle(operation: .write, length: 3),
|
||||
]
|
||||
@ -333,7 +333,7 @@ class Z80MachineCycleTests: XCTestCase {
|
||||
MachineCycle(operation: .readOpcode, length: 4),
|
||||
MachineCycle(operation: .readOpcode, length: 4),
|
||||
MachineCycle(operation: .read, length: 3),
|
||||
MachineCycle(operation: .read, length: 3),
|
||||
MachineCycle(operation: .read, length: 3),
|
||||
MachineCycle(operation: .read, length: 3),
|
||||
MachineCycle(operation: .read, length: 3),
|
||||
]
|
||||
@ -348,7 +348,7 @@ class Z80MachineCycleTests: XCTestCase {
|
||||
MachineCycle(operation: .readOpcode, length: 4),
|
||||
MachineCycle(operation: .readOpcode, length: 4),
|
||||
MachineCycle(operation: .read, length: 3),
|
||||
MachineCycle(operation: .read, length: 3),
|
||||
MachineCycle(operation: .read, length: 3),
|
||||
MachineCycle(operation: .write, length: 3),
|
||||
MachineCycle(operation: .write, length: 3),
|
||||
]
|
||||
|
@ -11,7 +11,7 @@
|
||||
using namespace Outputs::Display::OpenGL;
|
||||
|
||||
Rectangle::Rectangle(float x, float y, float width, float height):
|
||||
pixel_shader_(
|
||||
pixel_shader_(
|
||||
"#version 150\n"
|
||||
|
||||
"in vec2 position;"
|
||||
|
@ -45,7 +45,7 @@ enum Personality {
|
||||
};
|
||||
|
||||
#define has_decimal_mode(p) ((p) >= Personality::P6502)
|
||||
#define is_65c02(p) ((p) >= Personality::PSynertek65C02)
|
||||
#define is_65c02(p) ((p) >= Personality::PSynertek65C02)
|
||||
#define has_bbrbbsrmbsmb(p) ((p) >= Personality::PRockwell65C02)
|
||||
#define has_stpwai(p) ((p) >= Personality::PWDC65C02)
|
||||
|
||||
|
@ -265,7 +265,7 @@ void CPCDSK::set_tracks(const std::map<::Storage::Disk::Track::Address, std::sha
|
||||
sector.fdc_status1 = 0;
|
||||
sector.fdc_status2 = 0;
|
||||
|
||||
if(source_sector.second.has_data_crc_error) sector.fdc_status2 |= 0x20;
|
||||
if(source_sector.second.has_data_crc_error) sector.fdc_status2 |= 0x20;
|
||||
if(source_sector.second.has_header_crc_error) sector.fdc_status1 |= 0x20;
|
||||
if(source_sector.second.is_deleted) sector.fdc_status2 |= 0x40;
|
||||
}
|
||||
|
@ -155,7 +155,7 @@ bool FileHolder::check_signature(const char *signature, std::size_t length) {
|
||||
// read and check the file signature
|
||||
std::vector<uint8_t> stored_signature = read(length);
|
||||
if(stored_signature.size() != length) return false;
|
||||
if(std::memcmp(stored_signature.data(), signature, length)) return false;
|
||||
if(std::memcmp(stored_signature.data(), signature, length)) return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
|
@ -49,7 +49,7 @@ class CAS: public Tape {
|
||||
// each chunk is preceded by a header which may be long, and is optionally
|
||||
// also preceded by a gap.
|
||||
struct Chunk {
|
||||
bool has_gap;
|
||||
bool has_gap;
|
||||
bool long_header;
|
||||
std::vector<std::uint8_t> data;
|
||||
};
|
||||
|
@ -67,7 +67,7 @@ std::unique_ptr<Parser::FileSpeed> Parser::find_header(Storage::Tape::BinaryTape
|
||||
of a 0 start bit. The HI cycle length is placed in WINWID and will be used to discriminate
|
||||
between LO and HI cycles."
|
||||
*/
|
||||
total_length = total_length / 256.0f; // To get the average, in microseconds.
|
||||
total_length = total_length / 256.0f; // To get the average, in microseconds.
|
||||
// To convert to the loop count format used by the MSX BIOS.
|
||||
uint8_t int_result = static_cast<uint8_t>(total_length / (0.00001145f * 0.75f));
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user