GlovePIE:MediaPortal

From WiiLi

Jump to: navigation, search


Script for controlling MediaPortal media Player.

Very simple, uses only buttons for key controls, and then a combination with B + Other buttons for secondary functions (the B key alone was pressed accidentally too many times, so it does nothing on its own).

/*

WIIMOTE for MEDIA PORTAL 
MediaPortal available at http://www.team-mediaportal.com/
2008 08 16

*/
//Pending: LEDS, need to turn them off

//General KEYS
// Volume
Key.Equals =  Wiimote1.Plus
Key.Minus =   Wiimote1.Minus

// Escape and Home if key pressed longer than 2 secs.
Key.Escape =  Wiimote1.Home
Key.H = HeldDown(Wiimote1.Home, 2)

// WHEN B is not pressed

if (!Wiimote.B) then
   // Single keys
   Key.Enter =   Wiimote1.A

   // Mute and fullscreen
   Key.M =     Wiimote1.Two
   Key.X =     Wiimote1.One

   // Direction Keys
   Key.Up =     Wiimote1.Up
   Key.Down =   Wiimote1.Down
   Key.Left =   Wiimote1.Left
   Key.Right =  Wiimote1.Right

endif


// Combination Keys with B+...
// Key B on its own doesn't return anything,
//it was pressed accidentally too many times

// Next and previous song
Key.F7=  Wiimote1.B + Wiimote1.Left
Key.F8=  Wiimote1.B + Wiimote1.Right

// PageUp and Down
Key.PageUp    = Wiimote1.B + Wiimote1.Up
Key.PageDown  = Wiimote1.B + Wiimote1.Down

// Pause
Key.Space = Wiimote1.B + Wiimote1.A

// Show Context menu
Key.F9    = Wiimote1.B + Wiimote1.One

// Show info about element
Key.F3    = Wiimote1.B + Wiimote1.Two

Personal tools
Online Casino - best online casino reviews.
Facebook Developers - facebook applications, facebook developers, facebook development, social network application development and viral widget social media strategy