Files
ESP32_COMM/main/server/http_handlers.h
T
小龙虾 6335d05198 feat(main): 添加CAN 1Hz反馈轮询任务和HTTP接口
- 新增monitor/can_feedback_task.cpp组件,实现CAN 1Hz反馈轮询功能
- 在main.cpp中注册CAN反馈轮询任务,依赖SPI初始化完成后启动
- 在OTA协调器和中继模块中集成CAN反馈任务暂停/恢复机制
- 扩展CANFD桥接层,添加0xC1反馈查询、0xC2模式切换、0xC3ID快照协议支持
- 新增HTTP接口/can/feedback提供三路CAN反馈快照数据
- 新增HTTP接口/can/mode支持查询和切换CAN接收过滤模式
- 更新版本号从0.3.34到0.35
- 扩大SPI缓冲区以支持更大帧传输需求

BREAKING CHANGE: 新增CAN反馈监控功能需要GD32固件支持0xC1/0xC2/0xC3协议扩展
2026-06-29 01:51:44 +08:00

28 lines
838 B
C

#ifndef HTTP_HANDLERS_H
#define HTTP_HANDLERS_H
#include "esp_http_server.h"
// HTTP CORS and options
void http_set_cors_headers(httpd_req_t *req);
esp_err_t http_options_handler(httpd_req_t *req);
// OTA handlers
esp_err_t esp32_ota_update_handler(httpd_req_t *req);
esp_err_t ota_upload_handler(httpd_req_t *req);
esp_err_t ota_relay_trigger_handler(httpd_req_t *req);
esp_err_t restart_handler(httpd_req_t *req);
// Utility handlers
esp_err_t logs_handler(httpd_req_t *req);
esp_err_t can_send_handler(httpd_req_t *req);
esp_err_t spi_send_handler(httpd_req_t *req);
esp_err_t system_status_handler(httpd_req_t *req);
esp_err_t system_probe_handler(httpd_req_t *req);
// CAN 1Hz 反馈快照与接收模式
esp_err_t can_feedback_handler(httpd_req_t *req);
esp_err_t can_mode_handler(httpd_req_t *req);
#endif // HTTP_HANDLERS_H