Giter Club home page Giter Club logo

node-virtual-gamepads's Introduction

node-virtual-gamepads

This nodejs application provides the possibility to use your smartphone as a gamepad controller on Linux OS simply by reaching a local address. You can virtually plug up to 4 gamepad controllers.

Demo

Demo video 1 player in game here

Demo video 3 players on EmulStation here

Prerequisite

This application is only compatible with Linux OS with the uinput kernel module installed.

Installation

git clone https://github.com/miroof/node-virtual-gamepads
cd node-virtual-gamepads
npm install
sudo node main.js

If you encounter problems while installing or running node-virtual-gamepads have a look at the troubleshooting page.

Usage

Once the nodejs application is launched, you just have to plug your gamepad controller by connecting your device on the same local network and by reaching the address http://node_server_address

Features

Plug up to 4 virtual gamepads

The application will plug automatically a new controller when the web application is launched and unplug it at disconnection. 4 slots are available so 4 virtual gamepads can be created. You can see your current slot on the indicator directly on the vitual gamepad.

Virtual gamepad

Use it as standalone application (chrome mobile)

With the add to homescreen chrome feature, you can easily use virtual gamepads application without launching the browser each time you want to play.

With only 3 clicks, virtual gamepads web application becomes a standalone application.

Standalone installation step 1 Standalone installation step 2

Then a shortcut is added on your homescreen and the application will be launched outside the browser.

Virtual gamepad directly from the homescreen Launched outside the browser

Enjoy haptic feedbacks

Because it's difficult to spot the right place in a touch screen without looking at it, the touch zone of each button was increased. LT button was moved at the center of the screen to let as much space as possible for the joystick and avoid touch mistakes.

Step 1

To know if we pressed a button with success, the web application provides an haptic feedback which can be easily deactivated by turning off the vibrations of the phone.

Developing

For developing you will also have to install coffeescript

sudo apt-get install coffeescript

When you changed something in a coffeescript (e.g. main.coffee) run

coffee -c main.coffee

This will compile main.coffee to main.js which than can be run with node (see Installation) To compile all coffee files when ever they change run

coffee -cw .

If you want do add a new keyboard layout please refer to this file.

node-virtual-gamepads's People

Contributors

cmstew avatar cxong avatar jehervy avatar joolswills avatar marcosnils avatar mikaxii avatar robsdedude avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.