Thanks once again for the reply teja.. 1. Please check the WDT frequency by toggling an GPIO in ISR and make sure you're getting 1mS time period. (If you're checking in Oscilloscope, time period will be twice the actual) Ans) I am using SMCLK at 16 MHZ to source watchdog timer. Configured watchdog as given below: WDTCTL = WDT_MDLY_16; // WDT 16ms, for SMCLK = 1Mhz,here SMCLK = 16Mhz so timer interval = 1ms 2. Why do you want to generate PWM signal and trigger ADC if you can use that timer to trigger ADC? Ans) Actually i want to drive MOSFET using Half bridge MOSFET driver, which can switch High side and Low side MOSFET alternately. For this, i am generating PWM signal using TIMER_A1. I wanted to change the duty cycle of the PWM signal based on some Analog input. I want to take multiple conversion of Analog input and use the average value to remove noise in the measurement. So to trigger the ADC Conversion, i can do this either using watchdog timer OR pwm signal. Till now i have worked with low profile controller having single clock source. This is the first time i am using advanced controller having multiple clock source. That's why i have a confusion...!!! NOTE: I don't want noise while switching the MOSFETS. MY Question is... 1) Which one is a better option to trigger ADC event so that there is NO Noise in the switching of the MOSFET? watchdog timer OR PWM signal? 2) If i use watchdog timer, won't it affect PWM generation OR i misunderstood completely and the operation of watchdog timer is completely independent to TIMER_A1 operation/pwm generation ? NOTE: Both Watchdog timer and TIMER_A1 is using same clock source i.e. SMCLK = 16 Mhz ( This is why i got a doubt..) ADC Clock source is using it's internal 5Mhz oscillator 3. I'd trigger the ADC with a timer rather than generating PWM from one timer and use GPIO Interrupt to trigger ADC. (Correct me if this is not what you meant) Ans) I guess i don't know how pwm trigger works? will it generate an interrupt and affect switching of the MOSFET? Thank you
↧