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

Thread: PT8211 Oversampling deprecated? :s

  1. #1

    PT8211 Oversampling deprecated? :s

    When I activate Oversampling on output_pt8211_2.h and compile I get the following error:

    'define' does not name a type define AUDIO_PT8211_OVERSAMPLING


    All I did was uncommenting the lines:

    define AUDIO_PT8211_OVERSAMPLING
    &
    define AUDIO_PT8211_INTERPOLATION_LINEAR

    Any idea what might be happening? I'm on Teensy 4.0.

  2. #2
    Senior Member
    Join Date
    Aug 2013
    Location
    Ohio
    Posts
    128

    Preprocessor definitions require "#" character

    It looks like a "#" character is missing.

    The way to enable these things is with a preprocessor macro, so use "#define" preprocessor operator.

    Code:
    #define AUDIO_PT8211_OVERSAMPLING
    
    #define AUDIO_PT8211_INTERPOLATION_LINEAR

  3. #3
    Senior Member PaulS's Avatar
    Join Date
    Apr 2015
    Location
    Netherlands
    Posts
    1,096
    Oversampling is enabled by default in output_pt8211_2.h:

    Click image for larger version. 

Name:	Capture.PNG 
Views:	11 
Size:	11.3 KB 
ID:	30672

    By the way: it's 4x oversampling, see here.

    Paul
    Last edited by PaulS; 03-20-2023 at 09:18 PM.

  4. #4
    Thanks a lot, a lapsus made me think uncommenting also meant deleting the # symbol :s

    It works fine, using it with a TDA1387 after changing the corresponding line on the .cpp file.

Posting Permissions

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