Commit Graph

306 Commits

Author SHA1 Message Date
James 54b06a5c34
Recover DreamLink hardware after load state (#2003) 2025-07-10 20:32:00 +02:00
Isaac Marovitz af043c55cd
CMake Refactors (#1979)
Signed-off-by: Isaac Marovitz <isaacryu@icloud.com>
2025-06-24 16:33:12 +02:00
Flyinghead 8801b2ae16 haptic: add sine effect. implement spring for midi FFB
Add sine effect to haptic api and stop using maple rumble for naomi FFB.
Emulate spring in midi FFB. Thanks to njz3 for his help on decoding the
protocol.
Don't use exponential scale for rumble when using haptic sine effect.

serialize Sh4OCache::writeBack/ThroughBufferCycles
2025-06-16 17:50:36 +02:00
Flyinghead c20ec680a8 Merge remote-tracking branch 'origin/master' into dev 2025-04-30 22:58:14 +02:00
Xphalnos 240be07bbb Misc: Remove Duplicated Semicolons 2025-04-10 11:30:33 +02:00
James 34fda43d9c
DreamPicoPort fixes/enhancements (#1892)
* added getFunctionDefinitions
* Set DreamPort device default deadzone to 0% while preserving user customization
* Fixed default dead zone 0% for DreamPicoPort; set UsePhysicalVmuMemory default to true
* Use DisabledScope for UsePhysicalVmuMemory; moved DreamLinkGamepad::getDefaultMapping() to protected scope to match parent
* Set unique ID for DreamPicoPort devices so they enumerate the same way by flycast on every load
* Implement DreamLinkGamepad::resetMappingToDefault() and set C, D, and Z buttons for DreamPicoPort
---------
Co-authored-by: Nexus382 <anthonyscordino@gmail.com>
2025-04-07 19:23:14 +02:00
Isaac Marovitz 5a110fd666
Replace sprintf with snprintf (#1884)
Signed-off-by: Isaac Marovitz <isaacryu@icloud.com>
2025-03-25 18:47:07 +01:00
James 2631706fe2
Enable physical VMU memory access (#1881) 2025-03-22 15:59:42 +01:00
James 4e74619d9e
Harden serial comm interface (#1847)
* Harden serial interface
* Fixed build errors
* Minor tweaks
* Automatically attached A->A, B->B, etc
* Interfaces go in decending order
* Do a modulo in case I decide to move interface numbers
* Do specifically mod 4
* Call SDL_JoystickGetDeviceInstanceID which seems to help with a Windows bug
* Made MapleDevices smart pointers so they can freely be swapped out without leaking
* Fixed issues some issues reported by kosekmi
* Added missing bracket
* Fixed another compile issue
* Fixed a missing else
* If device had no serial number, fall down to checking name
* Use new DreamPort firmware dynamics
* Added missing parens
* Fixed screen blanking issue
* Added const
* Reset VMU Screen on game/emulator exit
* Added gameTermination() hook to hardware gamepad
* Send SW port on game termination
* Added checks so port is only sent if data is valid
* Fixed bug: wait for write to complete in sendCmd
* Fixed bug leading to multiple pointers to VMU and Rumble pack
---------

Co-authored-by: Mike Kosek <mike@kosek.de>
2025-02-16 17:36:57 +01:00
Flyinghead d84108de32 maple: yet another maple timing change
Use 2 Mb/s for console and 740 Kb/s for devices.
Fixes Silent Scope vmu load issue at boot. Issue #1796
D+Vine has issues detecting A and B presses with one controller
connected but it does work eventually. No issue with more than 1
controller. Issue #1279
Power Drift only boots with one controller connected. Crashes with 2 or
more.
2025-01-28 17:26:22 +01:00
Mike Kosek 77636391fc Enabled the usage of VMUs and Rumble Packs with Original DC Controllers 2025-01-25 17:02:18 +01:00
Flyinghead 944af44c7f naomi: some digital outputs still missing for f355
Lamps use 14 bits of output in f355.
2025-01-25 17:00:48 +01:00
Flyinghead 1b6bf25e7a naomi: broadcast digital outputs even when using FFB drive
The first byte is for lamps, the next two are for FFB.
Fixes missing lamp notifications when broadcasting digital outputs
(F355).
2025-01-23 18:40:24 +01:00
Flyinghead 553f77c675 dreamconn: send buzzer messages. Rename controller. Use asio iostream
Issue #1305
2024-12-27 18:47:12 +01:00
Flyinghead b9fdd5070b dreamconn: detect dreamconn+ with VID/PID. Send maple data as text.
Create DreamConn gamepad when detected.
Send/receive maple data in ascii dump form.
Simplify maple device creation.

Issue #1305
2024-12-20 20:02:58 +01:00
Flyinghead 34a5e7f47d input: dreamconn+ support prototype
Issue #1305
2024-12-16 17:17:45 +01:00
Flyinghead 421245aeba lightgun xhair: centralize logic in crosshairNeeded() 2024-12-13 17:21:32 +01:00
Flyinghead 1507097bcd naomi: set offscreen sensor when reloading. fix wldkicks PCB inputs
Most games using analog inputs for lightguns also have an offscreen
sensor (lupinsho, mok, hotd2, confmiss). Activate it when reloading or
shooting offscreen.
Fix World Kicks PCB inputs.
2024-12-09 16:02:30 +01:00
Flyinghead fc6142b332 maple: do a full save of the vmu after loading a state
A partial save might corrupt the vmu file system.
2024-11-04 19:19:31 +01:00
Flyinghead 5fc84acdfb maple: base vmu file name on game ID for multidisk games
Build vmu file name with game ID so that all disks of multidisk games
share the same vmu (A1 only, or all with libretro when enabled).
Rename existing vmu file to new format if none exists.
Issue #1556
2024-11-03 17:14:31 +01:00
Flyinghead 4d5ced1ce6 maple: add Full Controller with 2 analog sticks and all buttons
add AllStatusReq string for purupuru device.

Issue #1171
2024-11-02 18:13:38 +01:00
Flyinghead a81a02f14b maple: save rfid card after decrementing counter
Issue #1626
2024-09-07 14:50:29 +02:00
Flyinghead 7174ef1194 naomi: full rfid chip emulation for mushiking series
Fixes hang after playing 3 games.
Issue #1626
2024-09-04 09:48:34 +02:00
Flyinghead f039a809da naomi: limit max analog values to avoid overflow
Fixes overflow in wild riders when going full right or full accel/brake.
Follow up to Issue #1627
2024-09-02 17:04:17 +02:00
Flyinghead 1223154665 jvs: fix analog axes values encoding
The least significant byte of analog axis values seems to be handled as
signed.
Fixes crazy taxi going right when turning full left.
Issue #1627
2024-09-01 18:41:37 +02:00
Flyinghead 244bb724c9 naomi: add FFB support for Tokyo Bus Guide
Only rumble seems to be used.
Issue #1601

Add info about awave BIOS
2024-08-24 16:29:29 +02:00
Flyinghead cb0b667129 maple: don't assert dma interrupt if using hardware dma trigger
Fixes Virtua Cop 2 pause when shooting. Regression due to ecce915
Issue #474
2024-08-17 17:23:34 +02:00
Flyinghead adeba60ba9 input: ffb support for arcade games. rumble support (f355, 18wheeler)
SDL force feedback for racing wheels.
Support for jvs ffb (f355, 18wheeler), atomiswave (maxspeed, ftspeed)
and midi ffb (initd, clubk, kingrt66, sgdrvsim).
Simple haptic rumble for f355 and 18wheeler.
2024-06-01 11:03:14 +02:00
Flyinghead 21c77adc4d os_notify 2024-05-14 22:43:55 +02:00
Flyinghead 13302b87c8 move ui to its own folder 2024-05-07 22:23:51 +02:00
Flyinghead de6a43bd21 savestate: drop support for legacy libretro and <v16 savestates 2024-04-16 09:40:55 +02:00
Flyinghead e8340bfa5e maple: implement AllStatusReq for controller and VMU 2024-04-07 11:47:42 +02:00
Flyinghead 5ce1f92e5c naomi: allow mapping of left & right trigger 2
Makes rear brake usable in wild riders
Issue #1450
2024-03-12 14:36:38 +01:00
Flyinghead 43bb7c83f7 hide P3 and P4 light gun crosshairs for arcade games 2024-03-06 16:42:43 +01:00
flyinghead c146a92f83
Merge pull request #1379 from flyinghead/dev
merge dev branch
2024-02-03 18:25:15 +01:00
Flyinghead e286f98f72 naomi: new rom ntvmys 2024-01-31 16:52:34 +01:00
Flyinghead ecce9157bd maple: raise interrupt on vblank when maple bus is occupied
Raise a maple interrupt at the next vblank when the host occupies the
maple bus to read the lightgun position. Fixes RevolveR single shot
issue since the game is waiting for the interrupt.
Issue #1369
2024-01-28 15:21:40 +01:00
Flyinghead 10d3ffdf09 jvs: fix crackin'dj inputs. serialize coin count
crackin'dj: map vertical mouse axis to right turntable. Invert fader.
Simulate turntable motor. Embed eeproms with calibration done.
Fix coin being inserted after loading a savestate.
2024-01-24 19:39:20 +01:00
Flyinghead c001240797 move audio drivers to their own folder 2024-01-10 11:45:54 +01:00
scribam 6aa59c54a5
Minor misc changes (#1360)
* core: cleanup include headers
* dx11: remove unimplemented function
* core: annotate destructors with override
* aica: use range-based for loop
* bm: use const reference/structured bindings with blkmap
2024-01-02 14:38:16 +01:00
Flyinghead 192838b9c1 maple: lightgun must return 0 for trigger axes
Fixes Death Crimson 2 fast forwarding in story mode when using a
lightgun.
Issue #646
2023-12-16 16:47:48 +01:00
Flyinghead e9beea484d Merge remote-tracking branch 'origin/master' into dev 2023-12-04 11:58:12 +01:00
Flyinghead ce4a3a7147 scif: always schedule timer when updating baud rate
Old savestates don't have any callback set, and read only devices
(barcode readers) won't schedule any either
UI message when r/w card is ejected
2023-12-03 18:22:52 +01:00
Flyinghead d6593b9c6e maple: race controller has only 3 axes
Reporting 5 axes (with the optional pedals unit) breaks some games:
daytona usa, super speed racing, F1 world grand prix, ...
2023-11-29 12:26:04 +01:00
Flyinghead df83ca436c input: use 16 bits of precision for analog axes/triggers 2023-11-15 18:24:30 +01:00
Flyinghead 926877397c Merge remote-tracking branch 'origin/master' into dev 2023-11-07 16:32:12 +01:00
Flyinghead fd3f207e45 maple: move arcade input settings into maple init
Get rid of settings.input.JammaSetup
2023-11-02 19:00:29 +01:00
Bobby Smith 3e047a6e03 Create expansion device for "Racing Controller" 2023-11-01 15:43:08 +01:00
Flyinghead b7d923e02b maple: clear mapleDmaOut on reset. Other reset issues
mapleDmaOut wasn't reset, causing crashes or freezes in subsequent runs
Issue #1253

reset YUV state, pvr tile clip, MMU sq_remap, sh4 sq_buffer and more
2023-10-20 16:15:42 +02:00
Flyinghead f6f6637973 naomi: mushikep compatibility 2023-10-11 14:25:11 +02:00