02-28-2014 11:58 AM
Hi all. I want to make a program which has a continuous sine wave as input, for which, I want to design 3 Boolean lights to show when the amplitude is greater than 0,less than 0 and greater than threshold,which could be set. I want them to indicate it continuously. Problem is it doesn't glow continuously(dosen't flicker when amplitude changes). Only when I stop the while loop,the LED depending on the last value glows!! Or when I use the highlight execution it shows...
Thank you in advance..
02-28-2014 12:21 PM
We need to see some code. Most like likely your loop spins millions if times per second, blurring all LEDs.
02-28-2014 12:52 PM
What is the frequency of the sine wave? LEDs will not appear illuminated if they are being turned off and on too rapidly. My guess is that you are not allowing enough time to energize the direct band gap through the p-n junction of the transtisitor. Try setting your frequency to less than 1 Hz.
02-28-2014 01:43 PM
thank you allenbach and tmoutney sir... the frequency was very high. i reduced it to below 10 and the sampling per time too. Now it works!
But if i remove the sine wave generator and instead interface with a real time system(say ECG) where frequency would be more, then can you recomend something to indicate the changes?
i have attached the photo of my simple program..