OSDN Git Service
(root)
/
csp-qt
/
common_source_project-fm7.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
[General] Merge Upstream 2018-12-27.
[csp-qt/common_source_project-fm7.git]
/
source
/
src
/
vm
/
pc6001
/
psub.h
diff --git
a/source/src/vm/pc6001/psub.h
b/source/src/vm/pc6001/psub.h
index
a3b35ae
..
852eb01
100644
(file)
--- a/
source/src/vm/pc6001/psub.h
+++ b/
source/src/vm/pc6001/psub.h
@@
-20,9
+20,7
@@
class FILEIO;
class FILEIO;
-#if defined(_USE_QT) || defined(_USE_AGAR)
-typedef uint8 byte;
-#endif
+namespace PC6001 {
class PSUB : public DEVICE
{
class PSUB : public DEVICE
{
@@
-38,11
+36,12
@@
private:
int CasRecv;
int CasMode;
int CasBaud, FileBaud;
int CasRecv;
int CasMode;
int CasBaud, FileBaud;
- uint8 CasData[0x10000];
+ uint8
_t
CasData[0x10000];
int CasLength;
int CasSkipFlag;
int CasLength;
int CasSkipFlag;
- uint8* key_stat;
+ const uint8_t* key_stat;
+// uint8_t key_stat[256];
int kbFlagFunc;
int kbFlagGraph;
int kbFlagCtrl;
int kbFlagFunc;
int kbFlagGraph;
int kbFlagCtrl;
@@
-52,23
+51,25
@@
private:
int stick0;
int StrigIntFlag;
int StrigEventID;
int stick0;
int StrigIntFlag;
int StrigEventID;
- void update_keyboard();
+ void update_keyboard(
int code
);
public:
public:
- PSUB(VM* parent_vm, EMU* parent_emu) : DEVICE(parent_vm, parent_emu) {}
+ PSUB(VM_TEMPLATE* parent_vm, EMU* parent_emu) : DEVICE(parent_vm, parent_emu)
+ {
+ set_device_name(_T("Pseudo Sub System"));
+ }
~PSUB() {}
// common functions
void initialize();
void release();
void reset();
~PSUB() {}
// common functions
void initialize();
void release();
void reset();
- void write_io8(uint32
addr, uint32
data);
- uint32
read_io8(uint32
addr);
+ void write_io8(uint32
_t addr, uint32_t
data);
+ uint32
_t read_io8(uint32_t
addr);
void event_frame();
void event_callback(int event_id, int err);
void event_frame();
void event_callback(int event_id, int err);
- uint32 intr_ack();
- void save_state(FILEIO* state_fio);
- bool load_state(FILEIO* state_fio);
+ uint32_t get_intr_ack();
+ bool process_state(FILEIO* state_fio, bool loading);
// unique functions
void set_context_pio(DEVICE* device)
// unique functions
void set_context_pio(DEVICE* device)
@@
-79,17
+80,16
@@
public:
{
d_timer = device;
}
{
d_timer = device;
}
- bool play_tape(_TCHAR* file_path);
- bool rec_tape(_TCHAR* file_path);
+ bool play_tape(
const
_TCHAR* file_path);
+ bool rec_tape(
const
_TCHAR* file_path);
void close_tape();
void close_tape();
- bool tape_inserted()
+ bool
is_
tape_inserted()
{
return (play || rec);
}
{
return (play || rec);
}
- int get_tape_ptr()
- {
- if(CasLength <= 0) return 0;
- return (CasIndex * 100) / CasLength;
- }
+ void key_down(int code);
+ void key_up(int code);
};
};
+
+}
#endif
#endif