An Introduction to the HTML5 Gamepad API
ActiveTuts+ has a nice introduction to the new GamePad API that has made it’s way into the Firefox nightly build (Chrome support is coming as well.) This will allow you to connect up game controllers to your game, including XBox and XBox 360 controllers.