• Login
  • Register
  • Dolphin Forums
  • Home
  • FAQ
  • Download
  • Wiki
  • Code


Dolphin, the GameCube and Wii emulator - Forums › Dolphin Emulator Discussion and Support › Controllers v
« Previous 1 … 312 313 314 315 316 … 323 Next »

Full Wiimote Dolphin GlovePie script help
View New Posts | View Today's Posts

Thread Rating:
  • 1 Vote(s) - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Threaded Mode
Full Wiimote Dolphin GlovePie script help
09-01-2011, 04:26 AM
#1
Brewski606
Unregistered
 
Since I cant seem to find a single Glove Pie script for this,
I wanna start a project to build one that incorporates every function of the wiimote and motion plus

Im hoping this will help people (like myself) that hav had difficulty connecting using the default Dolphin pairing method

First question: is this possible?

Second: i hav all major button functions and will post wat I hav so far

I really need help writing up the parts for motion plus and ESPECIALLY the IR camera
i dont really know the functions for either of them


I will try to incorperate "4 players and attachments" later but would like to focus on the wiimote itself for now

Please note before u post:
yes i hav tried bluesoliel, it didnt help
im using PPJoy because its the only way to emulate analog joysticks correctly
Reply
09-01-2011, 06:01 AM
#2
Brewski606
Unregistered
 
Here is the first draft:
Classic needs some work and testing but wiimote and nunchuck work
Still need IR and motion
EDIT: Found Rumble is controlled by "Wiimote.Rumble", but im not sure how to implement

__________________________________________________________________________________________________________
/*
---BUTTON MAPPING to PPJoy 1--
Configuration:

1 POV Hat:
North: Digital 0
West: Digital 1
East: Digital 2
South: Digital 3

11 Buttons:
Digital 4 - Digital 14

6 Axes
1: X - Analog 0
2: Y - Analog 1
3: Z - Analog 4
4: Z Rotation - Analog 3
5: Slider - Analog 2
6: Throttle - Analog 5

*/

var.n=1 //sensitivity ajustment for analog

If Wiimote1.Exists

PPJoy1.Digital0 = Wiimote1.Up
PPJoy1.Digital1 = Wiimote1.Right
PPJoy1.Digital2 = Wiimote1.Left
PPJoy1.Digital3 = Wiimote1.Down
PPJoy1.Digital4 = Wiimote1.One
PPJoy1.Digital5 = Wiimote1.Two
PPJoy1.Digital6 = Wiimote1.A
PPJoy1.Digital7 = Wiimote1.B
PPJoy1.Digital8 = Wiimote1.Plus
PPJoy1.Digital9 = Wiimote1.Minus
PPJoy1.Digital10 = Wiimote1.Home

If Wiimote1.HasNunchuk
debug = "Nunchuck"
PPJoy1.Analog0 = Wiimote1.Nunchuk.JoyX * var.n
PPJoy1.Analog1 = Wiimote1.Nunchuk.JoyY * var.n
PPJoy1.Digital11 = Wiimote1.Nunchuk.CButton
PPJoy1.Digital12 = Wiimote1.Nunchuk.ZButton

else if Wiimote1.HasClassic //not done
debug = "Classic"
PPJoy1.Analog0 = Wiimote1.Classic.Joy1X * var.n
PPJoy1.Analog1 = Wiimote1.Classic.Joy1Y * var.n
PPJoy1.Analog3 = Wiimote1.Classic.Joy2X * var.n
PPJoy1.Analog4 = Wiimote1.Classic.Joy2Y * var.n
PPJoy1.Analog2 = Wiimote1.Classic.L
PPJoy1.Analog5 = Wiimote1.Classic.R
PPJoy1.Digital0 = Wiimote1.Classic.Up
PPJoy1.Digital1 = Wiimote1.Classic.Right
PPJoy1.Digital2 = Wiimote1.Classic.Left
PPJoy1.Digital3 = Wiimote1.Classic.Down
PPJoy1.Digital4 = Wiimote1.Classic.y
PPJoy1.Digital5 = Wiimote1.Classic.x
PPJoy1.Digital6 = Wiimote1.Classic.a
PPJoy1.Digital7 = Wiimote1.Classic.b
PPJoy1.Digital8 = Wiimote1.Classic.Plus
PPJoy1.Digital9 = Wiimote1.Classic.Minus
PPJoy1.Digital10 = Wiimote1.Classic.Home
PPJoy1.Digital11 = Wiimote1.Classic.LFull
PPJoy1.Digital12 = Wiimote1.Classic.RFull
PPJoy1.Digital13 = Wiimote1.Classic.ZL
PPJoy1.Digital14 = Wiimote1.Classic.ZR

Else
debug = "No Attachment"
End If


end if

//LEDs (True is on, False is off)
Wiimote.Led1 = false
Wiimote.Led2 = true
Wiimote.Led3 = false
Wiimote.Led4 = true



/*Debugs (These are great for testing if ur wiimote has these parts)
if wiimote.HasMotionPlus = True then debug = "WiiMotion Plus"
if wiimote.HasMotionPlus = false then debug = "WiiMotion Plus NOT DETECTED!"
if Wiimote.HasClassic = True then debug = "Classic"
if Wiimote.HasNunchuk = True then debug = "Nunchuk"
*/

/*Unknown functions:
wiimote.RawForceX
wiimote.RawForceY
wiimote.RawForceZ
Wiimote.gx
Wiimote.gy
Wiimote.gz
Wiimote.Pitch
Wiimote.Roll
Wiimote.RelAccX
Wiimote.RelAccY
Wiimote.RelAccZ
Wiimote.dot1x
Wiimote.dot1y
Wiimote.dot2x
Wiimote.dot2y
Wiimote.Nunchuk.gx
Wiimote.Nunchuk.gy
Wiimote.Nunchuk.gz
*/
Reply
09-01-2011, 07:44 PM
#3
siferion Offline
Junior Member
**
Posts: 20
Threads: 1
Joined: Nov 2010
WiiBrew Wiimote Documentation contains a lot of information about communicating with the Wiimote at a hardware level. Not sure if GlovePIE supports that level of control, but if it does that should help you figure it out. Down at the bottom of the page there is a link to the extension controller documentation which will be needed to decode the motion plus data.

From the looks of it the motion plus send yaw-pitch-roll, if GlovePIE doesn't expose the layers needed for hardware interaction then yaw can be estimated based on how far apart the IR dots are from each other. The wiki article on triangles should fill in a lot of the math required to pull this off, it wont be accurate but it should be good enough for games your pointing the Wiimote at the screen.
Find
Reply
09-06-2011, 05:39 AM
#4
Brewski606
Unregistered
 
thx
but they dont hav any specs on the glovepie commands or ppjoy
Reply
« Next Oldest | Next Newest »


  • View a Printable Version
Forum Jump:


Users browsing this thread: 1 Guest(s)



Powered By MyBB | Theme by Fragma