jegatheesan
Published © GPL3+

Mobile as PC Joystick

Play pc games using smartphone is a long time dream. Now come true.

IntermediateFull instructions provided1,163
Mobile as PC Joystick

Things used in this project

Hardware components

LinkIt ONE
MediaTek Labs LinkIt ONE
×1
Android device
Android device
×1

Software apps and online services

Arduino IDE
Arduino IDE
Microsoft visual basic 6
Bluetooth RC Car app

Story

Read more

Code

Bluetooth_Gamer.ino

Arduino
#include <LBT.h>
#include <LBTServer.h>
int readval;

void setup() {
 if(!LBTServer.begin((uint8_t*)"Sivam_LIO"))
 {
 return;
 }
 Serial.begin(9600); 
}
void loop() {
 uint8_t buf[1];
 int bytesRead;
// Serial.println("YES");
 if(LBTServer.connected())
 {
 while(true)
 {
 bytesRead = LBTServer.readBytes(buf, 1);
 if(!bytesRead)
 break;
 readval = buf[0];
 Serial.println(char(readval));
 }
 delay(10);
 }
 else
 {
 LBTServer.accept(5);
 }
}

Credits

jegatheesan

jegatheesan

16 projects • 40 followers
Simply A Mechatronics Lover.

Comments

Add projectSign up / Login