Ηι,
I have a yun board working the bridge example, and everything works as expected.
Now I would like to send an http request from a local client
http://192.168.1.5/arduino/Arduino.html?cmd=100
where the parameter cmd is just after ? and want to control some leds...
The problem is that the linux part of Bridge client does'not transfer any part of the url after the ? mark
point....
In my loop I have the following code in order to print the string coming from linux side;
#include <Bridge.h>
#include <BridgeServer.h>
#include <BridgeClient.h>
#include <Process.h>
#include <Console.h>
void setup() {
// Bridge startup
pinMode(13, OUTPUT);
digitalWrite(13, LOW);
Bridge.begin();
Console.begin();
delay(2000); // wait 2 seconds
digitalWrite(13, HIGH);
// Listen for incoming connection only from localhost
// (no one from the external network could connect)
server.noListenOnLocalhost();
server.begin();
Console.buffer(256);
while (!Console) {
; // wait for Console port to connect.
}
}
void loop() {
BridgeClient client = server.accept();
// There is a new client?
while (client.available()) {
char c = client.read();
Console.print(c);
}
Console.flush();
delay(50); // Poll every 50ms
}
and the output at console is always trimmed at ?: Arduino.html
Does any with experience in the bridge can give an advice?
Thanks