Skip to content

Commit 852014f

Browse files
mos-platform/neo6502/api/controller.c: fix return type and set parameter for neo_controller_read() (#407)
1 parent 808f3cd commit 852014f

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

mos-platform/neo6502/api/controller.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,8 @@ uint8_t neo_controller_count(void) {
1616
return ControlPort.params[0];
1717
}
1818

19-
uint8_t neo_controller_read(uint8_t index) {
19+
uint32_t neo_controller_read(uint8_t index) {
20+
ControlPort.params[0] = index;
2021
KSendMessageSync(API_GROUP_CONTROLLER, API_FN_READ_CONTROLLER2);
2122
return *((uint32_t*) ControlPort.params);
2223
}

0 commit comments

Comments
 (0)