feat: 添加杰理 JL7016 SOC 代码生成模板

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
2026-08-19 16:05:36 +08:00
co-authored by Cursor
parent 0eda925f58
commit 16bffd16b2
914 changed files with 254709 additions and 45 deletions
+43
View File
@@ -0,0 +1,43 @@
#ifndef _UART_DEV_
#define _UART_DEV_
#include "typedef.h"
#define MSG_UART_UPDATE_READY 0x1
#define MSG_UART_UPDATE_START 0x2
#define MSG_UART_UPDATE_START_RSP 0X3
#define MSG_UART_UPDATE_READ_RSP 0x4
#define PROTOCAL_SIZE 528
#define SYNC_SIZE 6
#define SYNC_MARK0 0xAA
#define SYNC_MARK1 0x55
typedef union {
u8 raw_data[PROTOCAL_SIZE + SYNC_SIZE];
struct {
u8 mark0;
u8 mark1;
u16 length;
u8 data[PROTOCAL_SIZE + 2]; //最后CRC16
} data;
} protocal_frame_t;
struct file_info {
u8 cmd;
u32 addr;
u32 len;
} __attribute__((packed));
typedef struct __update_io {
u16 rx;
u16 tx;
u8 input_channel; //input channel选择,根据方案选择未被使用的channel
u8 output_channel; //同input channel
} uart_update_cfg;
void uart_update_init(uart_update_cfg *cfg);
void sava_uart_update_param(void);
#endif