summaryrefslogtreecommitdiffhomepage
path: root/dev/Boot/Mod/NetBoot/NetBoot.h
diff options
context:
space:
mode:
authorAmlal <amlal.elmahrouss@icloud.com>2025-01-24 10:38:36 +0100
committerAmlal <amlal.elmahrouss@icloud.com>2025-01-24 10:38:36 +0100
commit7b4bd3577a31d0f0adc7371840642791ae1567f4 (patch)
tree1a8afc973aaa739d0d763315cad2fd376d1cea9c /dev/Boot/Mod/NetBoot/NetBoot.h
ADD: Open version, with important changes kept out.
Signed-off-by: Amlal <amlal.elmahrouss@icloud.com>
Diffstat (limited to 'dev/Boot/Mod/NetBoot/NetBoot.h')
-rw-r--r--dev/Boot/Mod/NetBoot/NetBoot.h31
1 files changed, 31 insertions, 0 deletions
diff --git a/dev/Boot/Mod/NetBoot/NetBoot.h b/dev/Boot/Mod/NetBoot/NetBoot.h
new file mode 100644
index 00000000..2375ef18
--- /dev/null
+++ b/dev/Boot/Mod/NetBoot/NetBoot.h
@@ -0,0 +1,31 @@
+/*
+ * ========================================================
+ *
+ * NetBoot
+ * Copyright (C) 2024-2025, Amlal EL Mahrouss, all rights reserved., all rights reserved.
+ *
+ * ========================================================
+ */
+
+#pragma once
+
+#include <NewKit/Defines.h>
+
+#define kNetBootINetMagic "NETB"
+#define kNetBootINetMagicLength 4
+
+/// @brief the internet header is used to download updates OTA.
+typedef struct NetBootInternetHeader
+{
+ Kernel::Char NB1; /// magic char 1 'N'
+ Kernel::Char NB2; /// magic char 2 'E'
+ Kernel::Char NB3; /// magic char 3 'T'
+ Kernel::Char NB4; /// magic char 4 'B'
+
+ Kernel::Char PatchName[255]; /// example: Modjo
+ Kernel::Int32 PatchLength; /// the patch length.
+ Kernel::Char PatchTarget[255]; /// the target file.
+ Kernel::Boolean ImpliesROM; /// does it imply an EEPROM reprogram?
+ Kernel::Boolean Preflight; /// is it a preflight packet.
+ Kernel::Char Data[]; /// non preflight packet has a patch blob for a **PatchTarget**
+} NetBootInternetHeader;