You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
47 lines
688 B
47 lines
688 B
|
5 months ago
|
#ifndef EBLAPP_H
|
||
|
|
#define EBLAPP_H
|
||
|
|
|
||
|
|
#include <stdint.h>
|
||
|
|
|
||
|
|
#define EBLAPP_REQUEST_FILE 0x11
|
||
|
|
#define EBLAPP_TRANSFER_START 0x12
|
||
|
|
#define EBLAPP_TRANSFER_DATA 0x13
|
||
|
|
#define EBLAPP_TRANSFER_END 0x14
|
||
|
|
#define EBLAPP_ACK 0x15
|
||
|
|
#define EBLAPP_WTF 0x16
|
||
|
|
|
||
|
|
struct Eblapp_request
|
||
|
|
{
|
||
|
|
uint32_t opcode;
|
||
|
|
uint32_t filename_size;
|
||
|
|
uint8_t filename[];
|
||
|
|
};
|
||
|
|
|
||
|
|
struct Eblapp_transfer_start
|
||
|
|
{
|
||
|
|
uint32_t opcode;
|
||
|
|
uint32_t file_size;
|
||
|
|
uint32_t crc;
|
||
|
|
};
|
||
|
|
|
||
|
|
struct Eblapp_transfer_data
|
||
|
|
{
|
||
|
|
uint32_t opcode;
|
||
|
|
uint32_t block_start;
|
||
|
|
uint8_t payload[];
|
||
|
|
};
|
||
|
|
|
||
|
|
struct Eblapp_transfer_end
|
||
|
|
{
|
||
|
|
uint32_t opcode;
|
||
|
|
};
|
||
|
|
|
||
|
|
struct Eblapp_ack
|
||
|
|
{
|
||
|
|
uint32_t opcode;
|
||
|
|
uint32_t ack_byte;
|
||
|
|
};
|
||
|
|
|
||
|
|
|
||
|
|
#endif /* EBLAPP_H */
|