mirror of
https://github.com/jscrane/r65emu.git
synced 2024-11-16 21:10:58 +00:00
return status from tape start
This commit is contained in:
parent
0d307290ae
commit
14d3ad3e69
@ -12,10 +12,14 @@
|
||||
|
||||
static File file, dir;
|
||||
|
||||
void sdtape::start(const char *programs)
|
||||
bool sdtape::start(const char *programs)
|
||||
{
|
||||
dir = DISK.open(programs);
|
||||
if (!dir)
|
||||
return false;
|
||||
|
||||
_pos = _len = 0;
|
||||
return true;
|
||||
}
|
||||
|
||||
void sdtape::stop()
|
||||
|
6
sdtape.h
6
sdtape.h
@ -6,16 +6,14 @@ public:
|
||||
const char *advance();
|
||||
const char *rewind();
|
||||
|
||||
void start(const char *);
|
||||
bool start(const char *);
|
||||
void stop();
|
||||
|
||||
sdtape(): _pos(0), _len(0) {}
|
||||
|
||||
uint8_t read() { return _buf[_pos++]; }
|
||||
bool more();
|
||||
|
||||
private:
|
||||
unsigned int _pos, _len;
|
||||
unsigned _pos, _len;
|
||||
uint8_t _buf[128];
|
||||
};
|
||||
#endif
|
||||
|
Loading…
Reference in New Issue
Block a user