mirror of
https://github.com/afska/gba-link-connection.git
synced 2026-09-08 17:07:33 -05:00
Improving LinkCable's API to mimic LinkUniversal and better support mid-frame reads
This commit is contained in:
@@ -38,7 +38,10 @@ int main() {
|
||||
data[i] = 0;
|
||||
|
||||
while (true) {
|
||||
// (4) Send/read messages
|
||||
// (4) Sync
|
||||
linkCable->sync();
|
||||
|
||||
// (5) Send/read messages
|
||||
u16 keys = ~REG_KEYS & KEY_ANY;
|
||||
linkCable->send(keys + 1); // (avoid using 0)
|
||||
|
||||
@@ -63,9 +66,6 @@ int main() {
|
||||
output += std::string("Waiting...");
|
||||
}
|
||||
|
||||
// (5) Mark the current state copy (front buffer) as consumed
|
||||
linkCable->consume();
|
||||
|
||||
VBlankIntrWait();
|
||||
log(output);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user