feat: 链路控制、延迟校准与长测工具,补全文档
- 固件:新增 link_control / stream_control,覆盖运行中 Wi-Fi 断线恢复、取帧节拍、 温控与质量/帧率减载;UDP 发送增加有界重试预算与帧期限,PSRAM JPEG 直发减少拷贝。 - 协议:重组器严格校验分片布局,统计未收齐、超时与完全缺失的帧,处理帧号回绕与设备重启。 - 桌面端:视频改 latest-value 通道并前置帧时间标记,拒绝积压和慢解码的过期画面;新增 延迟标记页与 --latency-report 校准,完善录制、服务端与退出流程。 - 文档与脚本:新增硬件、开发、延迟、功耗、实时性、稳定性文档和改动记录,重写根 README; 新增构建、性能、延迟与串口长测脚本,以及长测客户端脚本。 - 构建:固定 esp-1.97.0.0 工具链,分区表随构建复制,更新 sdkconfig 与忽略规则。
This commit is contained in:
@@ -112,6 +112,8 @@ typedef struct {
|
||||
size_t height;
|
||||
int format;
|
||||
void *handle; /* internal driver frame; do not touch */
|
||||
int64_t capture_started_us; /* same monotonic clock as esp_timer_get_time */
|
||||
uint32_t skipped_before; /* older completed frames released by latest get */
|
||||
} cam_wrapper_fb_t;
|
||||
|
||||
esp_err_t cam_wrapper_init(const cam_wrapper_config_t *config, cam_wrapper_sensor_t sensor);
|
||||
@@ -119,6 +121,7 @@ esp_err_t cam_wrapper_init(const cam_wrapper_config_t *config, cam_wrapper_senso
|
||||
/* Acquire one frame into `out`. Returns ESP_OK on success, ESP_FAIL if the
|
||||
* driver could not hand out a frame (e.g. timeout or buffer starvation). */
|
||||
esp_err_t cam_wrapper_fb_get(cam_wrapper_fb_t *out, cam_wrapper_sensor_t sensor);
|
||||
esp_err_t cam_wrapper_fb_get_latest(cam_wrapper_fb_t *out, uint32_t timeout_ms);
|
||||
|
||||
void cam_wrapper_fb_release(cam_wrapper_fb_t *fb);
|
||||
|
||||
@@ -129,6 +132,26 @@ esp_err_t cam_wrapper_deinit(void);
|
||||
/* Name of the sensor the driver detected, or "unknown". Never NULL. */
|
||||
const char *cam_wrapper_sensor_name(void);
|
||||
|
||||
/* Keep the sensor's JPEG encoder; effect 2 removes chroma in the sensor ISP. */
|
||||
esp_err_t cam_wrapper_set_grayscale(int enabled);
|
||||
/* Runtime JPEG compression, 0..63, without restarting the camera pipeline. */
|
||||
esp_err_t cam_wrapper_set_quality(unsigned quality);
|
||||
/* OV5640 target bias: 0 = default, -1 / -2 select approximately -1.1 / -1.9 EV. */
|
||||
esp_err_t cam_wrapper_set_exposure_bias(int ev);
|
||||
/* 0 = auto shutter; nonzero holds that exposure in sensor lines, AGC stays on. */
|
||||
esp_err_t cam_wrapper_set_shutter_lines(unsigned lines);
|
||||
/* Keep AEC/AGC automatic, cap exposure lines, and disable night frame extension. */
|
||||
esp_err_t cam_wrapper_set_exposure_limit(unsigned lines);
|
||||
/* 0 keeps the driver timing; nonzero changes OV5640 horizontal total only. */
|
||||
esp_err_t cam_wrapper_set_horizontal_timing(unsigned hts);
|
||||
int cam_wrapper_exposure_lines(void);
|
||||
/* OV5640 gain in 1/16 units; -1 when unavailable. */
|
||||
int cam_wrapper_gain_raw(void);
|
||||
float cam_wrapper_probe_frame_rate(void);
|
||||
/* Silicon temperature, not ambient or camera-sensor temperature. */
|
||||
esp_err_t cam_wrapper_temperature_init(void);
|
||||
esp_err_t cam_wrapper_temperature_read(float *celsius);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user