mirror of
https://github.com/jscrane/r65emu.git
synced 2024-12-21 12:29:51 +00:00
bugfixes
This commit is contained in:
parent
b7a9efe914
commit
a3111fa8a0
@ -6,6 +6,7 @@ static File file, dir;
|
||||
void sdtape::start(const char *programs)
|
||||
{
|
||||
dir = SD.open(programs);
|
||||
_pos = _len = 0;
|
||||
}
|
||||
|
||||
void sdtape::stop()
|
||||
|
@ -20,18 +20,18 @@ spiram::operator byte()
|
||||
|
||||
void spiram::checkpoint(Stream &s)
|
||||
{
|
||||
char buf[Memory::page_size];
|
||||
byte buf[Memory::page_size];
|
||||
for (int i = 0; i < pages(); i++) {
|
||||
spiRam.read_stream(i * 256, buf, sizeof(buf));
|
||||
s.write((byte *)buf, sizeof(buf));
|
||||
s.write(buf, sizeof(buf));
|
||||
}
|
||||
}
|
||||
|
||||
void spiram::restore(Stream &s)
|
||||
{
|
||||
char buf[Memory::page_size];
|
||||
byte buf[Memory::page_size];
|
||||
for (int i = 0; i < pages(); i++) {
|
||||
s.readBytes(buf, sizeof(buf));
|
||||
s.readBytes((char *)buf, sizeof(buf));
|
||||
spiRam.write_stream(i * 256, buf, sizeof(buf));
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user