mirror of
https://github.com/jscrane/r65emu.git
synced 2025-01-13 23:30:02 +00:00
add seek()
This commit is contained in:
parent
c2eaeb4089
commit
b20119558a
2
acia.h
2
acia.h
@ -46,6 +46,6 @@ public:
|
|||||||
static const uint8_t eri = 1 << 7; // enable receive interrupt
|
static const uint8_t eri = 1 << 7; // enable receive interrupt
|
||||||
|
|
||||||
private:
|
private:
|
||||||
serialio *_device;
|
class serialio *_device;
|
||||||
};
|
};
|
||||||
#endif
|
#endif
|
||||||
|
@ -22,6 +22,15 @@ static File file;
|
|||||||
static Dir dir;
|
static Dir dir;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
bool flash_filer::seek(uint32_t pos)
|
||||||
|
{
|
||||||
|
#if defined(USE_SD) || defined(USE_SPIFFS) || defined(USE_FS)
|
||||||
|
_pos = _len = 0;
|
||||||
|
return file.seek(pos);
|
||||||
|
#endif
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
bool flash_filer::start()
|
bool flash_filer::start()
|
||||||
{
|
{
|
||||||
#if defined(USE_FS)
|
#if defined(USE_FS)
|
||||||
|
@ -15,6 +15,7 @@ public:
|
|||||||
|
|
||||||
bool start();
|
bool start();
|
||||||
void stop();
|
void stop();
|
||||||
|
bool seek(uint32_t pos);
|
||||||
|
|
||||||
uint8_t read() { return _buf[_pos++]; }
|
uint8_t read() { return _buf[_pos++]; }
|
||||||
bool more();
|
bool more();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user