I'm a total noob in the Arduino scene and I have alot to understand. Right now I bought the new Arduino YUN for his WIFI capability. My first project is to be able to control a rc car from a tablet through the WIFI. So were I'm at right now is I managed to control the car throught SSH on the board then Telnet and sent stuff like F to go foward. Really basic stuff. Now my question is this how do I create my Interface on my tablet to talk to my YUN to make it go foward. What I would like is something simple like a button to go foward, one to go backward ect...
Plus I tried using the webserver on the yun and it really laggy so I would like maybe another option here.
Yeah you are so right about the sharpie thing. Now I had to buy a new tablet since my old one has permanent marking on it. Wish I had read your post before I made the error.
Now since you are asking for more details, I own a Android Nexus 7 tablet. The UI itself isn't a problem all I need to understand is how to connect to a specific socket. I've been reading on the web and I saw maybe WebSocket as maybe something usefull for me.
Here's the code I have on the Yun
#include <YunServer.h>
#include <Bridge.h>
#include <YunClient.h>
YunServer server(5678);
void setup() {
Serial.begin(9600);
// Bridge startup
pinMode(13, OUTPUT);
digitalWrite(13, LOW);
Bridge.begin();
digitalWrite(13, HIGH);
server.noListenOnLocalhost();
server.begin();
}
void loop() {
YunClient client = server.accept();
// There is a new client?
if (client) {
String command = "none";
while (command.indexOf("stop") != 0) {
if (client.available() > 0) {
command = client.readString();
client.print("Received: ");
client.print(command);
}
}
client.stop();
}
}
Dohhhh... It was writen ARDUINO in the header at the top, and I typed arduino.cc yet again I thought I was asking in a Android forum. When you look at it Arduino type fast spells out Arduino. My bad.
Thank you for your help Paul, I'll post in the Android forum. Hope I can type it good this time.
PS: This is the Project Guidance forum, and obviously here I need some guidance. It's the only reason why I ask.
PS: This is the Project Guidance forum, and obviously here I need some guidance. It's the only reason why I ask.
This is the forum to ask for guidance on using the Arduino. Your questions have about as much relevance here as they would at the Ford dealer or the grocery store.
I guess you are right. All I ask is for guidance on how to control a ARDUINO on a specific port. Nevermind the technologie, wether it's a tablet, phone or a computer, I'm using. Anyways thank you for the help.