angel d 0 Posted April 9, 2014 Share Posted April 9, 2014 I need to do a frecuencymeter, but firts i need an interruption every second and in this interrupt count pulses in one line (ex. PD_0). only i need to do this interrupt how i can do? Quote Link to post Share on other sites
vladn 3 Posted April 9, 2014 Share Posted April 9, 2014 If the frequency is low (< few kHz) you can simply count interrupts from that pin in a 1s interval using Energia-only code. This is very easy to do. I can help you with that. However If you want something more serious (say >10kHz) you need to learn how to program Tiva timers at the low level (or find an existing frequency counter project). I've done an enhanced resolution (oversampling) frequency counter on a MSP430, but it is not using Energia and the code is not in the public domain (have not decided on that yet). Quote Link to post Share on other sites
energia 485 Posted April 10, 2014 Share Posted April 10, 2014 Here is a really nice tutorial for a Tiva frequency counter: http://coder-tronics.com/stellaris-timer-example/ Note that Timer5 is used for keeping track of millis(), micros() and delay(). Quote Link to post Share on other sites
vladn 3 Posted April 10, 2014 Share Posted April 10, 2014 What is the highest frequency you want to measure and the accuracy you want to achieve ? Quote Link to post Share on other sites
angel d 0 Posted April 20, 2014 Author Share Posted April 20, 2014 thaks the tutorial is very good, is just what I needed Quote Link to post Share on other sites
Antscran 35 Posted May 3, 2014 Share Posted May 3, 2014 Hi, Just joined as noticed some traffic from here to my site. @@energia, thank you for posting the link @@angel d, glad you found it useful I own one of the LM4F based Stellaris Launchpads but not had time to use it yet, as focussing on the C2000 for my course. I will try and add more useful tutorial as and when I have time. Cheers, Ant Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.