summaryrefslogtreecommitdiffstats
path: root/include/udp.h
blob: 0bf43ff67ede553120f4fcfb126433af4ae95043 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#ifndef DEVICE_UDP_H
#define DEVICE_UDP_H

#include <ESP8266WiFi.h>
#include <WiFiUdp.h>

static const int com_port = 6996;
IPAddress ip;	/* Daemon IP */
WiFiUDP Udp;

extern void discover_client(const int port);
extern void udp_init_packet(IPAddress ip, const int port);
extern void udp_push(const void * const data, const size_t size);
extern int udp_flush(void);

#endif /* DEVICE_UDP_H */