Fix reader hook COM port andfix startup.bat and working on inputs

This commit is contained in:
Kayori 2024-08-26 10:08:42 +02:00
parent 11aabf50f8
commit 68f78d63bb
8 changed files with 29 additions and 15 deletions

View File

@ -209,7 +209,6 @@ $(BUILD_DIR_ZIP)/apm3.zip:
$(V)mkdir -p $(BUILD_DIR_ZIP)/apm3/DEVICE
$(V)cp $(BUILD_DIR_64)/subprojects/capnhook/inject/inject.exe \
$(BUILD_DIR_64)/apm3hook/apm3hook.dll \
$(DIST_DIR)/apm3/config_hook.json \
$(DIST_DIR)/apm3/segatools.ini \
$(DIST_DIR)/apm3/start.bat \
$(BUILD_DIR_ZIP)/apm3

View File

@ -16,6 +16,7 @@ EXPORTS
apm3_io_init
apm3_io_poll
apm3_io_led_init
apm3_io_led_set_colors
CFW_init
CFW_term
CFW_open

View File

@ -80,7 +80,7 @@ static DWORD CALLBACK apm3_pre_startup(void)
return hr;
}
hr = sg_reader_hook_init(&apm3_hook_cfg.aime, 3, 3, apm3_hook_mod);
hr = sg_reader_hook_init(&apm3_hook_cfg.aime, 3, 1, apm3_hook_mod);
if (FAILED(hr)) {
goto fail;

View File

@ -53,7 +53,19 @@ void apm3_io_get_opbtns(uint8_t *opbtn)
}
}
void apm3_io_get_gamebtns(uint8_t *btn)
{
if (btn != NULL) {
*btn = apm3_gamebtn;
}
}
HRESULT apm3_io_led_init(void)
{
return S_OK;
}
void apm3_io_led_set_colors(uint8_t board, uint8_t *rgb)
{
return;
}

View File

@ -53,3 +53,9 @@ void apm3_io_get_opbtns(uint8_t *opbtn);
Minimum API version: 0x0101 */
HRESULT apm3_io_led_init(void);
/* Update the RGB LEDs. rgb is a pointer to an array of up to 61 * 3 = 183 bytes.
Minimum API version: 0x0101 */
void apm3_io_led_set_colors(uint8_t board, uint8_t *rgb);

View File

@ -1,9 +0,0 @@
{
"credit" :
{
"coin_selector_AS6DB" :
{
"enable" : false
}
}
}

View File

@ -23,7 +23,7 @@ enable=1
aimePath=DEVICE\aime.txt
[vfd]
; Enable VFD emulation (currently just stubbed). Disable to use a real VFD
; Enable VFD emulation Disable to use a real VFD
; GP1232A02A FUTABA assembly.
enable=1
@ -101,3 +101,8 @@ test=0x70
service=0x71
; Keyboard button to increment coin counter. Default is the F3 key.
coin=0x72
up=0x57
down=0x53
left=0x41
right=0x44

6
dist/apm3/start.bat vendored
View File

@ -2,10 +2,10 @@
pushd %~dp0
start "AM Daemon" /min inject -d -k cmhook.dll amdaemon.exe -c config_common.json config_server.json config_client.json config_hook.json
inject -d -k cmhook.dll CardMaker.exe -screen-fullscreen 0 -popupwindow -screen-width 1080 -screen-height 1920
start "AM Daemon" /min inject -d -k apm3hook.dll amdaemonD.exe -c daemon_config\common.json daemon_config\standalone.json
inject -d -k apm3hook.dll Apmv3System.exe -screen-fullscreen 0 -popupwindow -screen-width 1920 -screen-height 1080
taskkill /f /im amdaemon.exe > nul 2>&1
taskkill /f /im amdaemonD.exe > nul 2>&1
echo.
echo Game processes have terminated