mirror of
https://github.com/arduino/Arduino.git
synced 2025-02-07 01:54:26 +01:00
Fixed Process example
This commit is contained in:
parent
05b0fc5f0b
commit
ef9070e85c
@ -1,24 +1,25 @@
|
|||||||
#include <Process.h>
|
#include <Process.h>
|
||||||
|
|
||||||
void brk() {
|
|
||||||
Bridge.print((char)3);
|
|
||||||
Bridge.find("#");
|
|
||||||
}
|
|
||||||
|
|
||||||
void setup() {
|
void setup() {
|
||||||
|
pinMode(13,OUTPUT);
|
||||||
|
digitalWrite(13,LOW);
|
||||||
|
|
||||||
|
Serial.begin(9600);
|
||||||
Bridge.begin();
|
Bridge.begin();
|
||||||
|
|
||||||
|
digitalWrite(13,HIGH);
|
||||||
|
delay(2000);
|
||||||
|
|
||||||
Process p;
|
Process p;
|
||||||
p.begin("curl");
|
p.begin("curl");
|
||||||
p.addParameter("http://arduino.cc/asciilogo.txt");
|
p.addParameter("http://arduino.cc/asciilogo.txt");
|
||||||
p.run();
|
p.run();
|
||||||
|
|
||||||
String res = "";
|
while (p.available()>0) {
|
||||||
while (p.IO.available()>0) {
|
char c = p.read();
|
||||||
p.IO.read();
|
Serial.print(c);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void loop() {
|
void loop() {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user