ESP8266
eboot_command.h
1 #ifndef EBOOT_COMMAND_H
2 #define EBOOT_COMMAND_H
3 
4 #include <stdint.h>
5 
6 #ifdef __cplusplus
7 extern "C" {
8 #endif
9 
10 #define RTC_MEM ((volatile uint32_t*)0x60001200)
11 
12 enum action_t {
13  ACTION_COPY_RAW = 0x00000001,
14  ACTION_LOAD_APP = 0xffffffff
15 };
16 
17 #define EBOOT_MAGIC 0xeb001000
18 #define EBOOT_MAGIC_MASK 0xfffff000
19 
20 struct eboot_command {
21  uint32_t magic;
22  enum action_t action;
23  uint32_t args[29];
24  uint32_t crc32;
25 };
26 
27 
28 int eboot_command_read(struct eboot_command* cmd);
29 void eboot_command_write(struct eboot_command* cmd);
30 void eboot_command_clear();
31 
32 #ifdef __cplusplus
33 }
34 #endif
35 
36 #endif //EBOOT_COMMAND_H
uint32_t args[29]
Definition: eboot_command.h:23
enum action_t action
Definition: eboot_command.h:22
Definition: eboot_command.h:20
uint32_t crc32
Definition: eboot_command.h:24
uint32_t magic
Definition: eboot_command.h:21