| ??? 05/22/06 16:34 Read: times |
#116851 - elaborationg on simple solution Responding to: ???'s previous message |
This is actual code from my "LED intensity regulator". T1 is configured as a counter and count pulses fron the l/f. GBupdateIntensity = TRUE signals main to correct the LED intensity based on the GCintBas value.
In the T0 ISR:
GCambientLoops--;
if ( !GCambientLoops)
{
GCintBas = S0_TH1 ;
S0_TL1 = 0;
S0_TH1 = 0;
GCambientLoops = 15;
GBupdateIntensity = TRUE;
}Erik
Sorry, This is just plain source, I do not have a source 2 since I do not know what it is, hope it helps |



