]> www.fi.muni.cz Git - bike-lights.git/commitdiff
ambient.c: detect drop of ambient light
authorJan "Yenya" Kasprzak <kas@fi.muni.cz>
Thu, 13 Jun 2013 19:14:30 +0000 (21:14 +0200)
committerJan "Yenya" Kasprzak <kas@fi.muni.cz>
Thu, 13 Jun 2013 19:14:30 +0000 (21:14 +0200)
Measure also longer-term running average of ambient light values,
and log instead of minima and maxima of adc readings the diffrence
between this longer-term average and normal avereage (ambient_val).
This is so that we would be able to switch the front light on when
entering a darkish area from the bright sun.


No differences found