Another USBQemu plugin, this time in VB.net (Keyboard only)
#31
That is more of a bug with PCSX2.

During boot/start-up, PCSX2 passes a pointer to IOP memory (as some USB information is stored here and is needed by the plug-in), however if you alter settings during emulation, PCSX2 will not re-pass this pointer.
A workaround is already present to keep track of this when you configure the usb plug-in.

however, if you hot swap, the newly loaded plug-in won't have that pointer to begin with, so it errors out.

I suspect you will have the same issue with identical files named differently and hot swapped. and also with wheel/singstar plugin swapping with copies of itself by jackun (depending, It might need to support save-states, or have the game re-initialise usb hardware).
Reply

Sponsored links

#32
(05-30-2016, 03:45 AM)Ge-Force Wrote: That is more of a bug with PCSX2.

During boot/start-up, PCSX2 passes a pointer to IOP memory (as some USB information is stored here and is needed by the plug-in), however if you alter settings during emulation, PCSX2 will not re-pass this pointer.
A workaround is already present to keep track of this when you configure the usb plug-in.

however, if you hot swap, the newly loaded plug-in won't have that pointer to begin with, so it errors out.

I suspect you will have the same issue with identical files named differently and hot swapped. and also with wheel/singstar plugin swapping with copies of itself by jackun (depending, It might need to support save-states, or have the game re-initialise usb hardware).

This image pretty much sums up my opinion of pcsx2 at this point.
[Image: 55491866.jpg]

Because this shouldn't even be an issue.

Someone apparently said "lets pass a pointer on boot that contains some info plugins may need and not pass it when plugins get reloaded" ....... Words cannot explain...... just have a
[Image: 59938349.jpg] .....
ASUS ROG G750JM
Intel i7-4700HQ CPU @2.40GHz (Overclock 3.7GHz)
Intel® HD Graphics 4600
NVIDIA GeForce GTX 860M
32.0GB RAM
Reply
#33
(05-30-2016, 03:45 AM)Ge-Force Wrote: That is more of a bug with PCSX2.

During boot/start-up, PCSX2 passes a pointer to IOP memory (as some USB information is stored here and is needed by the plug-in), however if you alter settings during emulation, PCSX2 will not re-pass this pointer.
A workaround is already present to keep track of this when you configure the usb plug-in.

however, if you hot swap, the newly loaded plug-in won't have that pointer to begin with, so it errors out.

I suspect you will have the same issue with identical files named differently and hot swapped. and also with wheel/singstar plugin swapping with copies of itself by jackun (depending, It might need to support save-states, or have the game re-initialise usb hardware).
The wheel/singstar plugin doesn't have the issue. I made a custom build of that to fix a bug and have an older version, and it doesn't mind hotswapping between those and the latest version.

Have you looked into fixing the issue in PCSX2 yourself or reporting it?
Reply
#34
(05-30-2016, 11:34 AM)FlatOut Wrote: The wheel/singstar plugin doesn't have the issue. I made a custom build of that to fix a bug and have an older version, and it doesn't mind hotswapping between those and the latest version.

Have you looked into fixing the issue in PCSX2 yourself or reporting it?

That plugin doesn't export a USBfreeze function (looking at it's .def file) so it will run in an idle/off state (which won't hit any code that needs the pointer) until the game initialises usb devices.
I can reproduce it by using full boot, hotswapping in the bios and waiting for the game to initialise usb devices (at which point it crashes).

USBsetRAM isn't called within the normal open routine. https://github.com/PCSX2/pcsx2/blob/1208....cpp#L1257
Instead is is called in cpuReset in https://github.com/PCSX2/pcsx2/blob/9306...00.cpp#L97

It was a long while back when I first encountered this issue and at the time I wasn't big on reporting issues. (Edit: I have now filed a bug report for it)

I'm not sure what the best method of resolving this is. the code in R5900 does not have an obvious suspend/resume function and the call was moved out of SysCorePlugins:OhmypenPlugin_USB() for a reason. ("iopMem is not initialized yet")

It might be just a case of putting the call back in to SysCorePlugins:OhmypenPlugin_USB() when iopMem->Main is not null. This might possible lead to an outdated pointer being passes, I have not looked into this in much detail.
Reply
#35
(05-29-2016, 10:58 PM)gh0stp1rate Wrote: Yes, I was able to use a USB keyboard when I still had my PS2 console with these cheat discs. I actually had the one that was made and sold from the guys who created ARMAX lol.

<Logs>

Investigating further.

Codebreaker does seem to initialise the USB controller, but doesn't seem to detect a keyboard

Codebreaker seems to disable interrupts and repetitively read HcRhDescriptorA (0x1F801648)

I tried to use PCSX2's debugger to try and figure out what it is doing with the result, but I can't seem to breakpoint on IOP instructions.

ARMax and GameShark should work. but I'm at a loss as to what specificity the issue with codebreaker is.

@Flatout In lilypad, are you using Windows messaging, Raw input or DirectInput for Keyboard API?[url=http://forums.pcsx2.net/User-FlatOut][/url]
Reply
#36
(05-30-2016, 06:43 PM)Ge-Force Wrote: @Flatout In lilypad, are you using Windows messaging, Raw input or DirectInput for Keyboard API?
Like I said, I use the default settings so Windows messaging.
Reply
#37
(05-30-2016, 07:05 PM)FlatOut Wrote: Like I said, I use the default settings so Windows messaging.

Must admit I hadn't seen any issues with either blocking/interfering with each other when both are at default input APIs (Windows messaging for both)

That being said, some do have menus, etc. that can be controlled with the keyboard and it seems the keyboard input gets prioritised sometimes.
Reply
#38
I think it mostly happens after pausing and resuming the emulator.
Reply
#39
(05-30-2016, 07:24 PM)FlatOut Wrote: I think it mostly happens after pausing and resuming the emulator.

I'm still unable to reproduce this...
Reply
#40
(05-30-2016, 07:24 PM)FlatOut Wrote: I think it mostly happens after pausing and resuming the emulator.

Had this issue in the past with version 4 of the plugin but i haven't seen this issue since then so yeah same as air-gamer unable to reproduce and i just tried.
ASUS ROG G750JM
Intel i7-4700HQ CPU @2.40GHz (Overclock 3.7GHz)
Intel® HD Graphics 4600
NVIDIA GeForce GTX 860M
32.0GB RAM
Reply




Users browsing this thread: 1 Guest(s)