高级会员
- 积分
- 627
- 威望
- 371
- 贡献
- 146
- 兑换币
- 173
- 注册时间
- 2015-11-25
- 在线时间
- 55 小时
- 毕业学校
- 海南科技大学
|
PixelAverageVoltageError = TargetPixelAverageVoltage - PixelAverageVoltage;//偏差
if(PixelAverageVoltageError < -TargetPixelAverageVoltageAllowError)
{
PixelAverageVoltageError = 0- PixelAverageVoltageError ;
PixelAverageVoltageError /= 5;
if(PixelAverageVoltageError > 10 )
PixelAverageVoltageError = 10 ;
IntegrationTime -= PixelAverageVoltageError;
}
if(PixelAverageVoltageError > TargetPixelAverageVoltageAllowError)
{
PixelAverageVoltageError /= 5;
if(PixelAverageVoltageError > 10 )
PixelAverageVoltageError = 10 ;
IntegrationTime += PixelAverageVoltageError;}
/*
uart_putchar(UART0,0XAA) ;//发送字节
uart_putchar(UART0,PixelAverageVoltage) ;
uart_putchar(UART0,PixelAverageVoltageError) ;
uart_putchar(UART0,IntegrationTime) ;
*/
if(IntegrationTime <= 1)
IntegrationTime = 1;
if(IntegrationTime >= 100)
IntegrationTime = 100;
}
这程序在计算曝光时间的原理是什么?
|
|