Forum Discussion

Altera_Forum's avatar
Altera_Forum
Icon for Honored Contributor rankHonored Contributor
18 years ago

NCO Megacore Phase Adjust

Hello

I am using the Altera Megacore NCO Compiler and need to dinamically adjust the phase of the generated sine wave.

The core has an input called phase_mod_i[] which is used for this purpose. The problem is that I don't know the relation between the desired phase adjust (in degrees) and the number I need to input in the core.

Is it linear? As in:

Input (with 15 bits of angular precision) / Phase Difference (degrees)

000000000000000 / 0

100000000000000 / 180

111111111111111 / 360 (or 0)

Can anyone help me please?

Thank you

Thiago

11 Replies

  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    --- Quote Start ---

    ok thx, now i have done approximately an schematic in simulink, but i don't sure on the first part on bit mapping and how "teach" at the NCO how change the phase...

    However i attach my schematic...

    --- Quote End ---

    just multiply stream by sin/cos.

    +1* nco output = nco output

    -1* nco output = - nco output