mirror of
https://github.com/TomHarte/CLK.git
synced 2025-02-18 16:30:29 +00:00
The Macintosh doesn't actually use the DMA signals, but uses pseudo-DMA mode so they nevertheless need to be appropriate.
25 lines
563 B
C++
25 lines
563 B
C++
//
|
|
// DirectAccessDevice.cpp
|
|
// Clock Signal
|
|
//
|
|
// Created by Thomas Harte on 22/08/2019.
|
|
// Copyright © 2019 Thomas Harte. All rights reserved.
|
|
//
|
|
|
|
#include "DirectAccessDevice.hpp"
|
|
|
|
using namespace SCSI;
|
|
|
|
bool DirectAccessDevice::read(const Target::CommandState &state, Target::Responder &responder) {
|
|
std::vector<uint8_t> data(512);
|
|
for(size_t c = 0; c < 512; ++c) {
|
|
data[c] = uint8_t(c);
|
|
}
|
|
|
|
responder.send_data(std::move(data), [] (const Target::CommandState &state, Target::Responder &responder) {
|
|
responder.end_command();
|
|
});
|
|
|
|
return true;
|
|
}
|