feat:增加曝光調參
This commit is contained in:
@@ -10,6 +10,7 @@ soft_iic_info_struct eeprom_param;
|
|||||||
TYPE_UNION iic_buffer[DATA_IN_FLASH_NUM];
|
TYPE_UNION iic_buffer[DATA_IN_FLASH_NUM];
|
||||||
TYPE_UNION tiny_frame_param[20];
|
TYPE_UNION tiny_frame_param[20];
|
||||||
uint32_t *addre[2];
|
uint32_t *addre[2];
|
||||||
|
float auto_exp;
|
||||||
/**
|
/**
|
||||||
* @brief 参数初始化注册
|
* @brief 参数初始化注册
|
||||||
*
|
*
|
||||||
@@ -28,6 +29,7 @@ void jj_param_eeprom_init(void)
|
|||||||
PARAM_REG(aim_straight, &straight_aim, EFLOAT, 1, "str:");
|
PARAM_REG(aim_straight, &straight_aim, EFLOAT, 1, "str:");
|
||||||
PARAM_REG(aim_turn, &turn_aim, EFLOAT, 1, "tur:");
|
PARAM_REG(aim_turn, &turn_aim, EFLOAT, 1, "tur:");
|
||||||
PARAM_REG(baoguang, &FIX_BINTHRESHOLD, EFLOAT, 1, "bao:");
|
PARAM_REG(baoguang, &FIX_BINTHRESHOLD, EFLOAT, 1, "bao:");
|
||||||
|
PARAM_REG(auto_exp_param, &auto_exp, EFLOAT, 1, "exp:");
|
||||||
jj_param_read(); // 注冊
|
jj_param_read(); // 注冊
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -29,7 +29,7 @@ typedef enum {
|
|||||||
Page2_head,
|
Page2_head,
|
||||||
// 第二页参数
|
// 第二页参数
|
||||||
baoguang = Page2_head,
|
baoguang = Page2_head,
|
||||||
|
auto_exp_param,
|
||||||
Page3_head,
|
Page3_head,
|
||||||
DATA_IN_FLASH_NUM,
|
DATA_IN_FLASH_NUM,
|
||||||
|
|
||||||
@@ -65,4 +65,5 @@ void jj_param_eeprom_init(void);
|
|||||||
void jj_param_write(void);
|
void jj_param_write(void);
|
||||||
void jj_param_read(void);
|
void jj_param_read(void);
|
||||||
extern float data7;
|
extern float data7;
|
||||||
|
extern float auto_exp;
|
||||||
#endif
|
#endif
|
||||||
@@ -29,6 +29,7 @@
|
|||||||
#include "by_led.h"
|
#include "by_led.h"
|
||||||
#include "jj_param.h"
|
#include "jj_param.h"
|
||||||
#include "jj_blueteeth.h"
|
#include "jj_blueteeth.h"
|
||||||
|
#include "zf_device_config.h"
|
||||||
|
|
||||||
int main(void)
|
int main(void)
|
||||||
{
|
{
|
||||||
@@ -36,7 +37,7 @@ int main(void)
|
|||||||
clock_init(SYSTEM_CLOCK_144M);
|
clock_init(SYSTEM_CLOCK_144M);
|
||||||
system_delay_init();
|
system_delay_init();
|
||||||
debug_init();
|
debug_init();
|
||||||
mt9v03x_init();
|
|
||||||
ips200_init(IPS200_TYPE_SPI);
|
ips200_init(IPS200_TYPE_SPI);
|
||||||
|
|
||||||
by_led_init();
|
by_led_init();
|
||||||
@@ -46,6 +47,9 @@ int main(void)
|
|||||||
jj_bt_init();
|
jj_bt_init();
|
||||||
jj_param_eeprom_init();
|
jj_param_eeprom_init();
|
||||||
|
|
||||||
|
mt9v03x_init();
|
||||||
|
mt9v03x_sccb_set_exposure_time((uint8_t)auto_exp);
|
||||||
|
|
||||||
Page_Init();
|
Page_Init();
|
||||||
|
|
||||||
pit_ms_init(TIM1_PIT, 10);
|
pit_ms_init(TIM1_PIT, 10);
|
||||||
|
|||||||
@@ -130,7 +130,7 @@ void Page_Init(void)
|
|||||||
PAGE_REG(page_menu, "main");
|
PAGE_REG(page_menu, "main");
|
||||||
PAGE_REG(page_rtcam, "rtcam");
|
PAGE_REG(page_rtcam, "rtcam");
|
||||||
PAGE_REG(page_param1, "aim_param");
|
PAGE_REG(page_param1, "aim_param");
|
||||||
PAGE_REG(page_param2, "param2");
|
PAGE_REG(page_param2, "exp");
|
||||||
PAGE_REG(page_dparam, "dparam");
|
PAGE_REG(page_dparam, "dparam");
|
||||||
PAGE_REG(page_reset, "reset");
|
PAGE_REG(page_reset, "reset");
|
||||||
// PAGE_REG(page_argv);
|
// PAGE_REG(page_argv);
|
||||||
|
|||||||
@@ -33,7 +33,7 @@ static void Setup()
|
|||||||
} else if (Get_new_page() == page_param2) {
|
} else if (Get_new_page() == page_param2) {
|
||||||
pafrist = Page2_head;
|
pafrist = Page2_head;
|
||||||
paend = Page3_head;
|
paend = Page3_head;
|
||||||
ips200_show_string(0, 0, "Param2");
|
ips200_show_string(0, 0, "exp");
|
||||||
}
|
}
|
||||||
|
|
||||||
palong = paend - pafrist;
|
palong = paend - pafrist;
|
||||||
|
|||||||
@@ -33,7 +33,7 @@ static void Setup()
|
|||||||
} else if (Get_new_page() == page_param2) {
|
} else if (Get_new_page() == page_param2) {
|
||||||
pafrist = Page2_head;
|
pafrist = Page2_head;
|
||||||
paend = Page3_head;
|
paend = Page3_head;
|
||||||
ips200_show_string(0, 0, "Param2");
|
ips200_show_string(0, 0, "exp");
|
||||||
}
|
}
|
||||||
|
|
||||||
palong = paend - pafrist;
|
palong = paend - pafrist;
|
||||||
@@ -100,6 +100,7 @@ static void Event(page_event event)
|
|||||||
return;
|
return;
|
||||||
} else if (page_event_press_long == event) {
|
} else if (page_event_press_long == event) {
|
||||||
jj_param_write();
|
jj_param_write();
|
||||||
|
mt9v03x_set_exposure_time(auto_exp);
|
||||||
Page_Shift(page_menu);
|
Page_Shift(page_menu);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user