summaryrefslogtreecommitdiff
path: root/code/fe310/eos/net.h
diff options
context:
space:
mode:
authorUros Majstorovic <majstor@majstor.org>2019-10-13 02:05:03 +0200
committerUros Majstorovic <majstor@majstor.org>2019-10-13 02:05:03 +0200
commit8c6c68e92d6b4c8aa5e2fcc784ed52da40845acc (patch)
tree0251bea9be01701c488f9d8719b52eeb2a64855d /code/fe310/eos/net.h
parent2a39fdf6d943f5738ba174368053a86304b0d8fa (diff)
net refactor; rename cmd -> type
Diffstat (limited to 'code/fe310/eos/net.h')
-rw-r--r--code/fe310/eos/net.h19
1 files changed, 16 insertions, 3 deletions
diff --git a/code/fe310/eos/net.h b/code/fe310/eos/net.h
index d09cd96..d50ee94 100644
--- a/code/fe310/eos/net.h
+++ b/code/fe310/eos/net.h
@@ -1,14 +1,27 @@
#include <stdint.h>
#include "event.h"
-#include "net_def.h"
+#define EOS_NET_FLAG_BUF_FREE 0x1
+#define EOS_NET_FLAG_BUF_ACQ 0x2
+
+#define EOS_NET_MTYPE_FLAG_ONEW 0x10
+
+#define EOS_NET_MTYPE_SOCK 1
+#define EOS_NET_MTYPE_AUDIO 2
+
+#define EOS_NET_MTYPE_WIFI 5
+#define EOS_NET_MTYPE_CELL 6
+#define EOS_NET_MTYPE_SIP 7
+#define EOS_NET_MTYPE_APP 8
+
+#define EOS_NET_MAX_MTYPE 8
void eos_net_init(void);
void eos_net_start(uint32_t sckdiv);
void eos_net_stop(void);
-void eos_net_set_handler(unsigned char cmd, eos_evt_fptr_t handler, uint8_t flags);
+void eos_net_set_handler(unsigned char type, eos_evt_fptr_t handler, uint8_t flags);
int eos_net_acquire(unsigned char reserved);
int eos_net_release(void);
unsigned char *eos_net_alloc(void);
int eos_net_free(unsigned char *buffer, unsigned char more);
-int eos_net_send(unsigned char cmd, unsigned char *buffer, uint16_t len);
+int eos_net_send(unsigned char type, unsigned char *buffer, uint16_t len);