1
0
mirror of https://github.com/rkujawa/rk65c02.git synced 2024-12-13 01:29:57 +00:00

Add comments explaing what these functions do.

This commit is contained in:
Radosław Kujawa 2017-01-27 10:13:32 +01:00
parent b7f1b8095b
commit 0c63342ad7

View File

@ -12,6 +12,9 @@
void rk65c02_exec(rk65c02emu_t *); void rk65c02_exec(rk65c02emu_t *);
/*
* Prepare the emulator for use, set initial CPU state.
*/
rk65c02emu_t rk65c02emu_t
rk65c02_init(bus_t *b) rk65c02_init(bus_t *b)
{ {
@ -24,6 +27,9 @@ rk65c02_init(bus_t *b)
return e; return e;
} }
/*
* Execute a single instruction within emulator.
*/
void void
rk65c02_exec(rk65c02emu_t *e) rk65c02_exec(rk65c02emu_t *e)
{ {
@ -50,6 +56,9 @@ rk65c02_exec(rk65c02emu_t *e)
} }
} }
/*
* Start the emulator.
*/
void void
rk65c02_start(rk65c02emu_t *e) { rk65c02_start(rk65c02emu_t *e) {
@ -59,6 +68,9 @@ rk65c02_start(rk65c02emu_t *e) {
} }
} }
/*
* Execute as many instructions as specified in steps argument.
*/
void void
rk65c02_step(rk65c02emu_t *e, uint16_t steps) { rk65c02_step(rk65c02emu_t *e, uint16_t steps) {