// max 256kbytes
#define BUFFER_SIZE 0x40000
+namespace PC8201 {
+
class CMT : public DEVICE
{
private:
bool is_wav, rec, remote;
_TCHAR rec_file_path[_MAX_PATH];
int bufcnt;
- uint8 buffer[BUFFER_SIZE];
+ uint8_t buffer[BUFFER_SIZE];
int prev_signal;
- uint32 prev_clock;
+ uint32_t prev_clock;
- void write_buffer(uint8 value, int samples);
+ void write_buffer(uint8_t value, int samples);
void put_signal();
public:
- CMT(VM* parent_vm, EMU* parent_emu) : DEVICE(parent_vm, parent_emu) {}
+ CMT(VM_TEMPLATE* parent_vm, EMU* parent_emu) : DEVICE(parent_vm, parent_emu)
+ {
+ set_device_name(_T("CMT I/F"));
+ }
~CMT() {}
// common functions
void initialize();
void release();
void reset();
- void write_signal(int id, uint32 data, uint32 mask);
- void save_state(FILEIO* state_fio);
- bool load_state(FILEIO* state_fio);
+ void write_signal(int id, uint32_t data, uint32_t mask);
+ bool process_state(FILEIO* state_fio, bool loading);
// unique functions
void rec_tape(const _TCHAR* file_path);
{
return rec;
}
+ bool is_tape_playing()
+ {
+ return false;
+ }
+ bool is_tape_recording()
+ {
+ return rec && remote;
+ }
+ int get_tape_position()
+ {
+ return 0;
+ }
};
+}
#endif