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

Thread: Teensy 4.1 delay times

  1. #1
    Junior Member
    Join Date
    Aug 2022
    Posts
    5

    Teensy 4.1 delay times

    Simple question, what is the maximum audio delay time you can reasonably expect from a teensy 4.1 with the Delay effect & using internal memory?
    And how many audio blocks would you need to allocate for that?
    I've seen plenty of specs for the 3.2 but not for the 4.1!

  2. #2
    Senior Member PaulStoffregen's Avatar
    Join Date
    Nov 2012
    Posts
    26,797
    Each audio block gives 2.9ms delay, since the block size is 128 samples.

  3. #3
    Junior Member
    Join Date
    Aug 2022
    Posts
    5
    Quote Originally Posted by PaulStoffregen View Post
    Each audio block gives 2.9ms delay, since the block size is 128 samples.
    so how many audio blocks can you have on the 4.1?

    Thanks for the quick reply by the way :-)

  4. #4
    Senior Member
    Join Date
    Apr 2021
    Location
    Cambridgeshire, UK
    Posts
    443
    896 (see line 36)
    Last edited by h4yn0nnym0u5e; 08-04-2022 at 12:53 PM.

  5. #5
    Junior Member
    Join Date
    Aug 2022
    Posts
    5
    Quote Originally Posted by h4yn0nnym0u5e View Post
    229376 (see line 36)
    Thanks, that makes things easier to calculate :-)

  6. #6
    Senior Member
    Join Date
    Apr 2021
    Location
    Cambridgeshire, UK
    Posts
    443
    Please note I made an error initially - 229376 is the memory in bytes, not blocks: I edited my post accordingly. Also, it looks as if you can allocate more than that and the memory will be used, but the audio library will only make use of the first 896 blocks, the rest will be wasted.

  7. #7
    Junior Member
    Join Date
    Aug 2022
    Posts
    5
    Quote Originally Posted by h4yn0nnym0u5e View Post
    Please note I made an error initially - 229376 is the memory in bytes, not blocks: I edited my post accordingly. Also, it looks as if you can allocate more than that and the memory will be used, but the audio library will only deal with the first 1792 blocks, the rest will be wasted.
    yeah I just figured that out, so divided the memory by 128 :-)

    Cheers for the quick amendment :-)

  8. #8
    Senior Member
    Join Date
    Apr 2021
    Location
    Cambridgeshire, UK
    Posts
    443
    I was still in error - divide by 256, each sample is 2 bytes ... 896 is my final offer!

  9. #9
    Senior Member PaulStoffregen's Avatar
    Join Date
    Nov 2012
    Posts
    26,797
    You could just edit the code to change MAX_AUDIO_MEMORY if you *really* wanted to use more.

  10. #10
    Junior Member
    Join Date
    Aug 2022
    Posts
    5
    Quote Originally Posted by PaulStoffregen View Post
    You could just edit the code to change MAX_AUDIO_MEMORY if you *really* wanted to use more.
    I was wondering if that would be an option, Thanks for the heads up :-)

Posting Permissions

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