+ Post New Thread
Results 1 to 4 of 4
  1. #1
    Newbie level 4
    Points: 311, Level: 3

    Join Date
    May 2011
    Posts
    5
    Helped
    0 / 0
    Points
    311
    Level
    3

    Sine wave freq Lookup Table

    Okay so I created Block RAM using Xilinx's Block Memory Generator, creating an 8-bit sine wave coded as a .coe file with 256 samples. I need a look up table to assign 44 different frequencies spread out among 4 octaves (Middle C up). How should I go about doing this?


    -Much appreciation in advance

    •   AltAdvertisement

        
       

  2. #2
    Member level 1
    Points: 1,712, Level: 9

    Join Date
    Mar 2006
    Posts
    33
    Helped
    3 / 3
    Points
    1,712
    Level
    9

    Re: Sine wave freq Lookup Table

    donot quite follow what u want to do ?



    •   AltAdvertisement

        
       

  3. #3
    Advanced Member level 5
    Points: 14,946, Level: 29
    mrflibble's Avatar
    Join Date
    Apr 2010
    Posts
    2,724
    Helped
    687 / 683
    Points
    14,946
    Level
    29

    Re: Sine wave freq Lookup Table

    Take a look at the DDS Compiler in the core generator in xilinx ise. That might be what you are looking for....



    •   AltAdvertisement

        
       

  4. #4
    Super Moderator
    Points: 53,524, Level: 56

    Join Date
    Apr 2011
    Location
    Minneapolis, Minnesota, USA
    Posts
    13,062
    Helped
    2604 / 2604
    Points
    53,524
    Level
    56

    Re: Sine wave freq Lookup Table

    It sounds as though you're using a method that will have lookup tables consisting of partial sine waves. First and last values may be far apart.

    This will result in sudden transitions at the speaker. You'll get harsh sounding sine waves.

    You only need one lookup table. You stated your memory has room for 44 x 256 steps. It must contain one entire sine wave.

    Then you will generate different frequencies by skipping so many steps down the lookup table. Skip many steps to make a high frequency. Skip few steps to make low freq.

    Read the value, send voltage to output. Again skip same number of steps, read the value, send to output, etc.



--[[ ]]--