nosound.97 Administrator
Number of posts : 173 Age : 32 Location : Manchester Reputation : -1 Points : 5899 Registration date : 2009-02-07
| Subject: Wii Remote Plugin (Official Thread) Fri Feb 13, 2009 11:43 pm | |
| - Quote :
- Originally posted by John Peterson
Regular use
To avoid any potential problems (specifically problems from the dual mode option mentioned below) with the Wii Remote Plugin make sure that you have unchecked both "Connect real Wiimote" and "Use real Wiimote" in the Real Wiimote settings when you want to use the emulated wiimote. And make sure both are checked when you want to use the real wiimote. These either-or modes should almost always work. The only problem I have heard of with them is that the game may sometimes disconnect when you are using the real wiimote. But that may be an issue with the core, and I have not tried to trace the cause of it. The only times I have managed to cause the disconnet message is when the game have been waiting for a 0x22 acknowledgement report and I have not sent one for 5 or 10 seconds. I don't know why this would happen during regular gameplay, and it would probably be hard to trace the bug if we can't find a way to reproduce the error.
Dual mode (switch between the real and the emulated Wiimote during gameplay)
You can switch back and forth between the emulated and the real wiimote during gameplay by checking and unchecking the "Use real Wiimote" checkbox during gameplay. This works most of the time, but sometimes when you switch to the real Wiimote it may result in a disconnection that can currently not be fixed by any other mean than restarting the game.
This is a list of the settings that are currently shared or not shared:
- Data reporting mode: When switching to the real wiimote, if it doesn't use the correct data reporting mode it should be changed to the correct one (that the emulated wiimote use). However, this may fail, I think it may be because I don't turn of the regular wiiuse_io_read() and wiiuse_io_write() functions while I tell Wiiuse to do the status change, so that it gets swamped somehow. You can try changing back and forth between the real and emulated wiimote (by checking and unhecking the "Use real Wiimote" checkbox) if there is a problem with the input.
- Wiimote accelerometer calibration: This is shared by copying the first 42 byte of the Wiimote Eeprom to the emulated Wiimote eeprom when a connection to the real wiimote is done.
- Extension accelerometer and analog stick calibration: The calibration bytes in the extension registry between 0x20 and 0x40 are shared when a real wiimote is avaliable. When a third party Wireless Nunchuck is used we use default values instead. When switching to the real Wiimote during gameplay we make sure third party Wireless Nunchucks are working, and that the right reporting mode is set, by sending a 0x20 status report to the game. This will make sure that we also use the same encryption key for the emulated and the real Wiimote.
Movement recording
You can now record Wiimote movements in the Real Wiimote configuration window. Here's how to use it:
- Record: Press one of the recording buttons under "Rec.", then hold A and record your movement, release A to stop the recording (this will also save it to the WiimoteMovement.ini file). To be able to make a recording you must first have unchecked "Use real Wiimote" and pressed '+' on the Wiimote (to enable the regular status readings from the Wiimote).
- Playback: Select a HotKey from 0 to 9, these numbers refer to the regular numerical keys on your keyboard. To play back the Wiimote accelerometer values press Shift + HotKey, to play back the accelerometer values for the nunchuck press Ctrl + HotKey, to play back the IR recording press Alt + HotKey. You must have unchecked the "Use real Wiimote" checkbox for the playback to work (they will not interrupt the real wiimote data reports).
- IR: The IR boxes under "Movement recording" in the Configuration window shows the type of IR data that was recorded. The values 12 will be shown if it's recoded without a concected extension, the value 10 is from a recording with a connected extension. You can not play back a 10 recording when the game is currently using 12 or vice versa, you will not see that it didn't work in any other way than that the cursor didn't move. If you have checked the "Nunchuck connected" or "Classic Controller" connected boxes the emulated Wiimote is using th 10 bytes reporting mode and 12 bytes recordings will not work, and vice versa.
- Playback speed: Simply put, low values will play back the recording slower, and high values will play it back faster. The value 100 should be the "regular" playback speed, but I don't know what that is yet because I have not figured out exactly how fast the Data Reports are sent to the Wii. I have noticed that the updates are related to the current FPS of a game (you can see the current update rate under "Update rate" in the Wii Remote Configuration window in the Real Wiimote tab during gameplay), for example Wii Sports had an update rate of around twice the FPS when it was running at around 75 FPS, but Metroid Prime 3 has an update rate of around 8 times/s when the FPS is around 13 or 14. Currently 100 means that the playback is done in the same real time (the time shown on your clock, not the time the Wii game think progressed) that it was recorded with. So you'll have to try different values and see which one that works. For example a simple shake recording will most likely work when you play it back in the fastest 500 speed to.
- Apply or Close buttons: Pressing these will save the current settings. You need to press Apply after you have changed the HotKey or recorded a new movement to make it apply during gameplay.
Currently you can only record accelerometer values from the Wiimote, not from the Nunchuck, but most movements from the Wiimote should also work on the Nunchuck, especially the simple ones like shaking. That's because the range of the Wiimote and Nuchuck accelerometer values are the same, it's only the neutral values that may differ.
How to map a movement to a Gamepad button with XPadder
To use these movements during gameplay I suggest that you get a progam like XPadder and map the needed HotKeys to a gamepad button. There is no problem to add a combination of buttons in XPadder, just select a key and then bring up the Advanced window and select for example Shift for Slot 1 and a regular numerical key (0, 1, 2, 3 etc, not a NumPad key) for Slot 2. That will make XPadder emulate that Shift and for example 0 is pressed at the same time.
Sharing movement recordings with other users
If you don't have a real Wiimote and need a certain movement to play any particular Wii game please feel free to ask for someone to produce that recording for you. Also, if you have a real Wiimote please feel free to produce a WiimoteMovement.ini with the movements needed for a particular game. It could be interesting to make WiimoteMovement.ini with all the movements needed for a particual game, for example Sonic and the Secret Rings or any other game that frequently use different Wiimote movements for the controls.
When producing a recording for other users you may want to change the "Accelerometer neutral" values to the "Target" value that is shown. To calibrate the values for your wiimote let it lay still on the table (and make sure you have first pressed '+' so that the "Current" value is being updated), then change the value in the adjustments checkboxes until the "Current" values equal the "Target" values. This calibration may be needed for some movements if they are sensitive to the neutral values in any way. The game can be fairly sensitive to the neutral values if it wants to, for example Wii Sports will not show the cursor if I have given it the neutral values "132 132 159" if I'm actually producing a neutral value of "118 118 142" and vice versa, especially the last number, the Z value is important to show that the Wiimote is fairly horisontal and could potentially be pointing the the screen. The "132 132 159" neutral values are those that are shown on Wiibrew.org, "118 118 142" are the values that I think came with my Wiimote. I also think it's possible to change these values, and it should be fairly harmless since you can always reset the entire Eeprom (with Wiiuse for example). But I'm avoiding any options to change this data on the actual Wiimote to avoid breaking anyone's Wiimote, if a workaround is possible, for example the manual adjustment I mentioned, it's probably preferable over editing the actual Wiimote Eeprom. Ask all your questions here if you didn't understand something or have a problem | |
|