changed to do ZCD inside the main loop.
This commit is contained in:
parent
f55dd8165a
commit
156dfb6e09
|
@ -48,10 +48,11 @@ int main(int argc, char **argv)
|
||||||
|
|
||||||
//The G1 pin is low at this point.
|
//The G1 pin is low at this point.
|
||||||
_delay_ms(2500);
|
_delay_ms(2500);
|
||||||
|
//EnOut_SetAllHigh(); //Sets G1 High
|
||||||
Enable_SetPinsHigh();
|
Enable_SetPinsHigh();
|
||||||
ZCD_Poll();
|
|
||||||
|
|
||||||
while(true){
|
while(true){
|
||||||
|
ZCD_Poll();
|
||||||
//Enable pins are enabled(set high) if the ADCLOAD value is valid.
|
//Enable pins are enabled(set high) if the ADCLOAD value is valid.
|
||||||
_delay_us(Tau);
|
_delay_us(Tau);
|
||||||
Load_HandleLoadPortA(ADC_LOAD1, EN1);
|
Load_HandleLoadPortA(ADC_LOAD1, EN1);
|
||||||
|
|
Loading…
Reference in New Issue