Skip to content

Analog Buffer cannot be dynamically allocated on Teensy 4 #54

@drjyeh

Description

@drjyeh

I am trying to use dynamically allocated buffers and AnalogBufferDMA, and found the following:

An instantiation of AnalogBufferDMA must be global if two buffers are used for continuous operation, is this correct.

An instantiation of AnalogBufferDMA can be dynamic if one buffer is used for IntervalTimer operation.

The buffers must be global. I tried malloc and new the buffer(s), and they will fill up the first time by the DMA, but will never be filled up again with new data.

I tried using double buffer for IntervalTimer operation, by setting stopOnCompletion(true) after init. But this does not work. I looked through the code and during init some other methods are called other then just setting _stop_on_completion.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions