diff options
author | jaseg <jaseg@jaseg.net> | 2014-02-01 22:07:03 +0100 |
---|---|---|
committer | jaseg <jaseg@jaseg.net> | 2014-02-01 22:07:03 +0100 |
commit | 809f8ac2e0fc17e956022051782a3f2203cdbfb4 (patch) | |
tree | b1c2dddd621348d5c02d85e29323365b9d33d70e /host/net.h | |
parent | 5a77d3a0e0a24c2c637aec0195919a13d42ac769 (diff) | |
download | matelight-809f8ac2e0fc17e956022051782a3f2203cdbfb4.tar.gz matelight-809f8ac2e0fc17e956022051782a3f2203cdbfb4.tar.bz2 matelight-809f8ac2e0fc17e956022051782a3f2203cdbfb4.zip |
Working on the new UDP protocol
Diffstat (limited to 'host/net.h')
-rw-r--r-- | host/net.h | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/host/net.h b/host/net.h new file mode 100644 index 0000000..d8ec949 --- /dev/null +++ b/host/net.h @@ -0,0 +1,18 @@ +#ifndef __NET_H__ +#define __NET_H__ + +#include "config.h" + +typedef struct { + uint8_t r, g, b; +} rgb_t; + +typedef struct { + uint32_t magic, seq; + uint16_t width, height; + rgb_t data[DISPLAY_WIDTH*DISPLAY_HEIGHT]; +} ml_packet_t; + +#define UDP_BUF_SIZE sizeof(ml_packet_t) + +#endif//__NET_H__ |