summaryrefslogtreecommitdiff
path: root/code/esp32/components/eos/include/transport.h
diff options
context:
space:
mode:
authorUros Majstorovic <majstor@majstor.org>2018-01-16 23:43:07 +0100
committerUros Majstorovic <majstor@majstor.org>2018-01-16 23:43:07 +0100
commit01c3e3af2394f863323b846fa304ff7e0a30e9df (patch)
tree84b499e6ece88e637ed86bbdd87333613e2433c5 /code/esp32/components/eos/include/transport.h
parent0d0e9facfcea3cf96da3b63285865182fdd5477e (diff)
eos support
Diffstat (limited to 'code/esp32/components/eos/include/transport.h')
-rw-r--r--code/esp32/components/eos/include/transport.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/code/esp32/components/eos/include/transport.h b/code/esp32/components/eos/include/transport.h
new file mode 100644
index 0000000..9d76d1b
--- /dev/null
+++ b/code/esp32/components/eos/include/transport.h
@@ -0,0 +1,13 @@
+#include <stdint.h>
+
+#define EOS_IPv4_ADDR_SIZE 4
+
+typedef struct EOSNetAddr {
+ unsigned char host[EOS_IPv4_ADDR_SIZE];
+ uint16_t port;
+} EOSNetAddr;
+
+void eos_net_init(void);
+void eos_net_connect(char *ssid, char *password);
+void eos_net_disconnect(void);
+ssize_t eos_net_send(void *msg, size_t msg_size, EOSNetAddr *addr);