Skip to main content
Abdelhak GOUDJIL
Associate II
Mar 18, 2018 5:06 PM UTC
Question

How to retrieve the data converted by ADC using DMA on simulink ?

Posted on March 18, 2018 at 18:06

Hello,

I want to use the ADC and the DMA on Simulink

as follows

:

The ADC is triggered by

the rising edge

of Timer 2 which generates a PWM signal with a frequency of 100

kHz

.

So, I want to retrieve the 132 first data converted by ADC at every 1 second.

Any idea how to use DMA (or buffer) on

Simulink

and how to retrieve the 132 first data converted by ADC at every 1 second.

Thank you

very much.

Note: this post was migrated and contained many threaded conversations, some content may be missing.
    This topic has been closed for replies.

    9 replies

    Andrew Neil
    Super User
    Mar 18, 2018 7:06 PM UTC
    Posted on March 18, 2018 at 20:06

    Any idea how to use DMA (or buffer) on

    Simulink

    Is that not covered in the Simulink Documentation?

    https://uk.mathworks.com/help/simulink/index.html

     
    A complex system that works is invariably found to have evolved from a simple system that worked.A complex system designed from scratch never works and cannot be patched up to make it work.
    Abdelhak GOUDJIL
    Associate II
    Mar 19, 2018 4:33 PM UTC
    Posted on March 19, 2018 at 16:33

    Thank you Andrew for your response,

    But I want to

    know

    how to

    configure ADC and DMA on CubeMX and how to read DMA data under Simulink?

    Thanks in advance

    Andrew Neil
    Super User
    Mar 19, 2018 6:34 PM UTC
    Posted on March 19, 2018 at 18:34

    So that's two separate questions - isn't it:

    1. how to

      configure ADC and DMA on CubeMX
    2. how to read DMA data under Simulink?

    Is the fact that it came via DMA even relevant to Simulink?

    A complex system that works is invariably found to have evolved from a simple system that worked.A complex system designed from scratch never works and cannot be patched up to make it work.