mobinmk
Full Member level 2
- Joined
- May 27, 2010
- Messages
- 140
- Helped
- 4
- Reputation
- 8
- Reaction score
- 4
- Trophy points
- 1,298
- Location
- Kollam (Quilon),kerala, India
- Activity points
- 2,484
Thnkz Sir,
i got it.....
pls check the setup ()
In setup () pwm pins 9,10,11 will be high for .5 seconds
after .5s , pwm pins will be low.
some doubts,
if the pwm pins 9,10,11 output will remain high , any problems?? should i set to LOW after .5 seconds??
also delay() function is not used if the timer 0 is disabled.
in program, after the delay () in setup (), timer 0 is disabled .
is this delay(500); will work ??
can u tell me how to get .5s??
Bootstrap Capactior value is 10uf electrolytic //el 200nf ceramic
Vcc is 15.8v
bootsrap diode is Uf4007
thus VOLTAGE across capacitor is 15.8 -1= 14.8V
Is this T = rc = .5 seconds ??
How to get R??
In ckt ,i use no resistance in bootstrap ckt .
i got it.....
pls check the setup ()
void setup()
{
pinMode(LED_PIN, OUTPUT);
// sets the digital pin as output
Serial.begin(115200); // connect to the serial port
Serial.println("DDS Test");
pinMode(TEST_PIN, OUTPUT); // sets the digital pin as output
pinMode(PWM_OUT_1, OUTPUT); // PWM output / frequency output
pinMode(PWM_OUT_2, OUTPUT); // PWM output / frequency output
pinMode(PWM_OUT_3, OUTPUT); // PWM output / frequency output
// short delay for .5s
digitalWrite(PWM_OUT_1, HIGH);
digitalWrite(lPWM_OUT_2, HIGH);
digitalWrite(PWM_OUT_3, HIGH);
delay(500);//wait for .5 second
digitalWrite(PWM_OUT_1, LOW);
digitalWrite(lPWM_OUT_2, LOW);
digitalWrite(PWM_OUT_3, LOW);
// Setup the timers
setup_timer1();
setup_timer2();
// disable interrupts to avoid timing distortion
cbi (TIMSK0, TOIE0); // disable Timer0 !!! delay() is now not available
sbi (TIMSK2, TOIE2); // enable Timer2 Interrupt
dfreq = 1000.0; // initial output frequency = 1000.0 Hz
tword_m = twoTo32 * dfreq / refclk; // calulate DDS new tuning word
}
In setup () pwm pins 9,10,11 will be high for .5 seconds
after .5s , pwm pins will be low.
some doubts,
if the pwm pins 9,10,11 output will remain high , any problems?? should i set to LOW after .5 seconds??
also delay() function is not used if the timer 0 is disabled.
in program, after the delay () in setup (), timer 0 is disabled .
is this delay(500); will work ??
can u tell me how to get .5s??
Bootstrap Capactior value is 10uf electrolytic //el 200nf ceramic
Vcc is 15.8v
bootsrap diode is Uf4007
thus VOLTAGE across capacitor is 15.8 -1= 14.8V
Is this T = rc = .5 seconds ??
How to get R??
In ckt ,i use no resistance in bootstrap ckt .