summaryrefslogtreecommitdiff
path: root/ecp/src/dir.h
diff options
context:
space:
mode:
authorUros Majstorovic <majstor@majstor.org>2021-08-31 22:20:15 +0200
committerUros Majstorovic <majstor@majstor.org>2021-08-31 22:20:15 +0200
commit2a33ef2344145e12f1eea96214cdb317857321c1 (patch)
tree1db9ce4e9c227c54595132edbce8adc65dd086ce /ecp/src/dir.h
parent2a46bdf517eb5fcb8ba59c398a32859c6496475d (diff)
directory service added
Diffstat (limited to 'ecp/src/dir.h')
-rw-r--r--ecp/src/dir.h15
1 files changed, 15 insertions, 0 deletions
diff --git a/ecp/src/dir.h b/ecp/src/dir.h
new file mode 100644
index 0000000..ae8daa9
--- /dev/null
+++ b/ecp/src/dir.h
@@ -0,0 +1,15 @@
+#define ECP_MAX_DIR_ITEM 30
+#define ECP_SIZE_DIR_ITEM 40
+
+typedef struct ECPDirItem {
+ ECPNode node;
+ uint16_t capabilities;
+} ECPDirItem;
+
+typedef struct ECPDirList {
+ ECPDirItem item[ECP_MAX_DIR_ITEM];
+ uint16_t count;
+} ECPDirList;
+
+void ecp_dir_parse_item(unsigned char *buf, ECPDirItem *item);
+void ecp_dir_serialize_item(unsigned char *buf, ECPDirItem *item);