Forum Rule: Always post complete source code & details to reproduce any issue!
Results 1 to 5 of 5

Thread: FreqCount on Teensy 3.0

  1. #1
    Junior Member
    Join Date
    Nov 2012
    Posts
    1

    FreqCount on Teensy 3.0

    Hi Paul,

    I like to use the teensy 3.0 for frequency measurements with FreqCount.
    FreqCount/util/timer.h does not contain a definition for teensy 3.0 yet.

    Is it complicated to add it?
    Will the maximal frequency be higher as on teensy 2.0 if I use 96 MHz?

    By the way, many thanks for the great board and the perfect support!

    Kindest regards,
    Peter

  2. #2
    Senior Member PaulStoffregen's Avatar
    Join Date
    Nov 2012
    Posts
    22,114
    Quote Originally Posted by peja View Post
    Hi Paul,

    I like to use the teensy 3.0 for frequency measurements with FreqCount.
    FreqCount/util/timer.h does not contain a definition for teensy 3.0 yet.

    Is it complicated to add it?
    Yes, it's complicated.

    I will do it, but this isn't easy, so it's not something I can do very quickly.


    Will the maximal frequency be higher as on teensy 2.0 if I use 96 MHz?
    I believe the timers can be externally clocked up to 1/4 of the clock. However, the timers run from the bus clock (as almost all the peripherals do), not the cpu clock. The bus clock is 48 MHz when the CPU is either 48 or 96 MHz. So 12 MHz will probably be the maximum.

  3. #3
    Senior Member
    Join Date
    Feb 2013
    Posts
    563
    Quote Originally Posted by PaulStoffregen View Post
    Yes, it's complicated.

    I will do it, but this isn't easy, so it's not something I can do very quickly.




    I believe the timers can be externally clocked up to 1/4 of the clock. However, the timers run from the bus clock (as almost all the peripherals do), not the cpu clock. The bus clock is 48 MHz when the CPU is either 48 or 96 MHz. So 12 MHz will probably be the maximum.
    did anyone make any progress on this one? or any clues as to where the complications reside? (sorry if that sounds lazy... i just found out this hasn't been ported yet, and after finding this, i feel slightly intimidated)

    edit. just found this - http://www.digitalmisery.com/2013/06...on-teensy-3-0/
    looks like more worthwhile than trying to fiddle with that library
    Last edited by mxxx; 09-30-2013 at 11:27 PM.

  4. #4
    Senior Member
    Join Date
    Nov 2012
    Location
    Boston, MA, USA
    Posts
    1,111
    Just for followup for anyone tracking this thread, Paul reported porting FreqCount and FreqMeasure to Teensy 3.x back in June 2014.

    Paul, what input circuit did you use with Teensy 3.x here? The ones for Teensy 2 looks as if the transistor would be into saturation on a 3V3 rail.

  5. #5
    Senior Member PaulStoffregen's Avatar
    Join Date
    Nov 2012
    Posts
    22,114
    Quote Originally Posted by Nantonos View Post
    Paul, what input circuit did you use with Teensy 3.x here?
    I cheated. I just drove the Teensy pin directly with a waveform from a function generator. It was a Siglent SDG5082, to be specific, with the min & max voltage set to 0 and 3.3V.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •