Is it possible to send this data to a Windows 7 PC wirelessly for display purposes? If so, how would I start?
I'm a newbie to this so please explain any suggestions in detail
Explore... Chat... Share...
Moderator: igrr
// Processing UDP example to send and receive binary data
// https://thearduinoandme.wordpress.com/t utorials/esp8266-send-receive-binary-data/
// Badly hacked by Ray B. to display the UDP broadcast from ESP8266
import hypermedia.net.*; // http://ubaa.net/shared/processing/udp/udp_class_udp.htm
String ip = "10.10.10.1"; // the remote IP address of ESP8266
int port = 8888; // the destination port - any unused port
long previousMillis = 0;
long interval = 500;
UDP udp;
void setup() {
udp = new UDP(this, 8888);
udp.listen( true );
}
void draw() {
if (previousMillis < millis() - interval) {
previousMillis = previousMillis + interval;
byte[] message = new byte[2];
message[0] = 0; message[1] = 0;
udp.send(message, ip, port);
}
}
void keyPressed() {
if (key == '-')
{
byte[] message = new byte[2];
message[0] = 0; message[1] = 0;
udp.send(message, ip, port);
}
}
void keyReleased() {
if (key != '-') {
byte[] message = new byte[2];
message[0] = 0; message[1] = 0;
udp.send(message, ip, port);
}
}
void receive( byte[] data ) { // <– default handler
for (int i=0; i < data.length; i++)//void receive( byte[] data, String ip, int port ) { // <– extended handler
print(char(data[i]));
println();
}
It takes about 20-25 seconds for home assistant c[…]
I tried to upgrade tof my sonoff basic R2 with the[…]
a problem Perhaps you want to define "Probl[…]
Rebooting your router will not give you a faster I[…]
There are no other notifications from esptool.py i[…]
Using the Arduino IDE, you'll learn how to set up […]
In this project, you will post to Twitter using an[…]
In this project, we will build a water level contr[…]
I guess I'm late, but I had the same problem and f[…]
Last night I received my first D1 Minis for a lear[…]
Although I am aware that this is an old post, I fe[…]