23 Commits
Author SHA1 Message Date
グローランプ 89bd77e306 IO: Resolve IO DLL paths from environment variables (#119)
## Summary

Adds a unified mechanism for locating third-party IO DLLs through environment
variables, on top of the existing per-game `[xxxio] path=` INI setting.

## Changes

For each IO DLL, the path is resolved in this order:

1. The section-specific INI value, e.g. `[mai2io] path=`.
2. The section-specific environment variable, e.g. `SEGATOOLS_MAI2IO_PATH`.
3. `SEGATOOLS_IO_ROOT` joined with the default IO DLL filename, e.g.
   `%SEGATOOLS_IO_ROOT%\mai2io.dll`.
4. Empty path, which keeps the built-in IO implementation (unchanged default).

INI and environment-variable paths are run through Windows environment-variable
expansion, so values such as `%SEGATOOLS_IO_ROOT%\mai2io.dll` are valid in the
INI directly.

Reviewed-on: https://gitea.tendokyu.moe/TeamTofuShop/segatools/pulls/119
Co-authored-by: グローランプ <130208311+Gl0w1amp@users.noreply.github.com>
Co-committed-by: グローランプ <130208311+Gl0w1amp@users.noreply.github.com>
2026-07-08 20:23:08 +00:00
Dniel97 60e7e1d432 mai2: add all net auth 1.0 2025-12-25 00:05:51 +01:00
Dniel97 03513e7b0c add aime scan button to default segatools.ini 2025-07-16 15:44:05 +02:00
Dniel97 cdb6815c5a add keychip id and pcbid to default segatools.ini 2025-06-19 19:28:10 +02:00
Dniel97 e850346b79 renamed start.bat to launch.bat 2025-03-02 00:25:15 +01:00
Dniel97 4cb76dd1ee mai2: update all LED boards to use two boards 2025-03-02 00:01:45 +01:00
MahuyoandSucareto a1611afffc Mai2: Add touch and led15070 hook (#55)
In this PR, I have added the `mai2` touch and `led15070` hooks to provide an example for handling custom peripherals. This change allows users to implement the touch and `led15070` logic by writing appropriate `mai2io` scripts.

#### **Touch Hook**:
- The touch hook simulates touch points based on keyboard combinations. For example, to trigger the A1 touch point, the user must press the A and 1 keys on the keyboard. Input for the 1p requires Caps Lock to be off, while 2p requires Caps Lock to be on.
- The hook allows for independent control of whether device simulation is enabled for "1p" and "2p" and whether keyboard input mapping is enabled.
- **Note**: The current touch hook is not yet functional as it requires modifications to the `capnhook` for proper completion of the `sinmai` hook.

#### **LED15070 Hook**:
- This hook implements basic device simulation. Peripherals requiring lighting data should complete the logic as needed.
- **Note**: The LED data refresh can flood the console logs, so I’ve added a `DEBUG` flag to control whether the debug logging is enabled or not.

#### **Other Changes**:
- In certain versions of `sinmai`, key inputs for 1p and 2p can be directly read from the keyboard without requiring simulation via the `amdaemon io4` hook. I’ve added a switch to control this behavior to prevent redundant input.
- **Benefit**: This ensures that key input is only read when `sinmai` is in the foreground.

If you'd like to learn more about the touch and `led15070` features, my research findings are available here:
[Mai2Touch](https://github.com/Sucareto/Mai2Touch)

Co-authored-by: Sucareto <28331534+Sucareto@users.noreply.github.com>
Reviewed-on: https://gitea.tendokyu.moe/TeamTofuShop/segatools/pulls/55
Co-authored-by: Mahuyo <mahuyo@noreply.gitea.tendokyu.moe>
Co-committed-by: Mahuyo <mahuyo@noreply.gitea.tendokyu.moe>
2025-02-16 12:49:58 +00:00
kyoubate-haruka 26624f25b1 hide default vfd ports from configs 2024-08-24 11:14:13 +02:00
kyoubate-haruka 54cbbffae9 add almost full vfd implementation 2024-08-23 16:30:22 +02:00
Dniel97 c91c7db3c7 renamed [gpio] dipsw settings to [system] 2024-08-20 10:48:08 +02:00
Dniel97 3bfb046afc mu3, chusan: improved library doc 2024-05-15 21:42:15 +02:00
beerpsi 4041844ea9 mai2/mu3/cm: Integrate UnityDoorstop with segatools (#11)
[UnityDoorstop](https://github.com/NeighTools/UnityDoorstop) is a tool to execute managed code (.NET DLLs) before Unity does, useful for modding frameworks such as BepInEx.

This PR integrates parts of its code into segatools, so loading BepInEx is as simple as adding 2 lines to `segatools.ini`:
```ini
[unity]
targetAssembly=BepInEx\core\BepInEx.Preloader.dll
```

This PR also factors out the Unity path redirection hooks to its own module.

Reviewed-on: https://gitea.tendokyu.moe/Dniel97/segatools/pulls/11
Co-authored-by: beerpsi <beerpsi@duck.com>
Co-committed-by: beerpsi <beerpsi@duck.com>
2024-04-15 19:30:28 +00:00
Dniel97 2590e749ca config bugfixes 2024-03-07 15:46:43 +01:00
Dniel97 ca36a879cb updated README and added "AM Daemon" window name 2024-02-22 19:12:18 +01:00
Dniel97 e40e1dffe3 improved all segatools.ini configs 2024-02-21 21:58:44 +01:00
Dniel97 56e971c6a4 changed default operator buttons to F1, F2 and F3 and fixed subnets 2024-02-06 13:01:26 +01:00
Dniel97 451a7ec49d added VFD toggle to config 2024-02-06 12:34:11 +01:00
Dniel97 4ffcf25555 added freeplay setting to ALLS games 2023-12-03 22:22:17 +01:00
Dniel97 a4bd570cfc chusan, mai2, mu3, swdc: removed emoney config 2023-10-05 00:35:55 +02:00
Dniel97 51b11469d0 added aimeGen as default instead of feliciaGen 2023-08-29 22:57:04 +02:00
Dniel97 97234f26d7 cm, chusan, mai2, mu3, swdc: added emoney config 2023-08-15 22:02:38 +02:00
Dniel97 608c9ac1a6 chusan, cm, mai2, mu3: Added dipSw support and highBaudrate AiMe 2023-08-15 17:28:19 +02:00
Dniel97 0ee081ca1b mai2: segatools added 2023-07-14 01:00:28 +02:00