NCO Calculator


Closed Thread
Results 1 to 25 of 25

Thread: NCO Calculator

Hybrid View

  1. #1
    Join Date
    Nov 2003
    Location
    Greece
    Posts
    4,132


    Did you find this post helpful? Yes | No

    Default Re: NCO Calculator

    I never used the NCO up to this moment. What is the purpose of this module?

    Ioannis

  2. #2
    Join Date
    Mar 2003
    Location
    Commerce Michigan USA
    Posts
    1,166


    Did you find this post helpful? Yes | No

    Default Re: NCO Calculator

    Well Ioannis, Here is an excerpt form the data sheet:

    The Numerically Controlled Oscillator (NCO1) module
    is a timer that uses the overflow from the addition of an
    increment value to divide the input frequency. The
    advantage of the addition method over simple
    counter-driven timer is that the output frequency
    resolution does not vary with the divider value. The
    NCO1 is most useful for applications that require
    frequency accuracy and fine resolution at a fixed duty
    cycle.

    I have recently built and coded a closed loop PID control for a stepper motor with the NCO.
    Dave Purola,
    N8NTA
    EN82fn

  3. #3
    Join Date
    Nov 2003
    Location
    Greece
    Posts
    4,132


    Did you find this post helpful? Yes | No

    Default Re: NCO Calculator

    Thanks Dave for the info.

    Ioannis

  4. #4
    Join Date
    Apr 2014
    Location
    OK
    Posts
    557


    Did you find this post helpful? Yes | No

    Default Re: NCO Calculator

    With NCO you can target frequencies with spectacular accuracy as opposed to PWM or other methods. Many of the newer PICs with NCO also have the option of using LFINTOSC and MFINTOSC with NCO for a slower-than-Fosc(/4) clock. My current project targets frequencies as slow as 2 Hz, with accuracy to 0.02 Hz, and as high as 3.1 MHz. NCO lets me get that accurate.

  5. #5
    Join Date
    Aug 2005
    Location
    Michigan, USA
    Posts
    224


    Did you find this post helpful? Yes | No

    Default Re: NCO Calculator

    Hi mpgmike:

    At the risk of seeming like a troll, may I make a couple suggestions, just in case you ever revisit your NCO Calc program, please?

    (1) Allow entry of NCO Frequencies such as 8388608-Hz without rounding.
    (2) Correct the NCO bit width constant (2097152) in your calculations.
    (3) Display the NCO frequency resolution.
    (4) Display the output frequency error.

    I whipped up a quick spreadsheet to highlight the calculation problems I'm experiencing. Your NCO Calc app' introduces errors by rounding the NCO frequency and by using the incorrect NCO bit width constant in your calculations.

    Have fun. Best wishes. Cheerful regards, Mike, K8LH

    Name:  K8LH NCO Calc.png
Views: 5586
Size:  37.5 KB
    Last edited by Mike, K8LH; - 11th May 2018 at 01:03.

  6. #6
    Join Date
    Nov 2003
    Location
    Greece
    Posts
    4,132


    Did you find this post helpful? Yes | No

    Default Re: NCO Calculator

    Isn't easier all these calculation done in a Excel file?

    Ioannis

  7. #7
    Join Date
    Apr 2014
    Location
    OK
    Posts
    557


    Did you find this post helpful? Yes | No

    Default Re: NCO Calculator

    Thoughts I never thought. There are 2 modes for NCO, toggle (the one used) and a pulse-out, which yields 2X the frequency output of toggle mode. I had thought of possibly adding calculations for pulse-out mode.

  8. #8
    Join Date
    Aug 2005
    Location
    Michigan, USA
    Posts
    224


    Did you find this post helpful? Yes | No

    Default Re: NCO Calculator

    Quote Originally Posted by Ioannis View Post
    Isn't easier all these calculation done in a Excel file?

    Ioannis
    A spreadsheet is easier to make but I don't think it's easier to use. Mike's stand-alone app' is a seriously cool accomplishment. Personally, I'd rather use a small stand-alone app' instead of a spreadsheet.

    Many years ago I built an SPBRG Calculator spreadsheet followed by an SPBRG Calculator app' written in JustBASIC. I much prefer using the app'.

    Cheerful regards, Mike, K8LH

    Name:  K8LH SPBRG Calc.png
Views: 4451
Size:  44.7 KB

Similar Threads

  1. help with calculator
    By minssss in forum General
    Replies: 3
    Last Post: - 10th November 2009, 00:12
  2. Calculator LCD
    By menze in forum General
    Replies: 0
    Last Post: - 26th June 2006, 21:31
  3. help with my calculator project
    By loayaouad in forum mel PIC BASIC Pro
    Replies: 1
    Last Post: - 17th May 2005, 07:42
  4. Calculatorīs LCD
    By srspinho in forum mel PIC BASIC Pro
    Replies: 7
    Last Post: - 4th May 2005, 10:27
  5. Calculator
    By neiron21 in forum mel PIC BASIC Pro
    Replies: 5
    Last Post: - 1st February 2005, 00:53

Members who have read this thread : 0

You do not have permission to view the list of names.

Posting Permissions

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