Skip to main content
ad ho
Associate II
July 13, 2017
Solved

I2S CLK Outputs on nucleo-F446RE

  • July 13, 2017
  • 3 replies
  • 1740 views
Posted on July 13, 2017 at 18:21

The original post was too long to process during our migration. Please click on the attachment to read the original post.
    This topic has been closed for replies.
    Best answer by Mohamed Jallouli_2
    Posted on July 28, 2017 at 16:29

    Hello

    Hoffet.Adrien

    ‌,

    Is the DMA mode circular or normal? If the DMA mode is normal, you might have missed the data when it was sent but that doesn't explain the missing clock signal.

    Regards.

    3 replies

    waclawek.jan
    Super User
    July 17, 2017
    Posted on July 17, 2017 at 17:10

    Simplify.

    Set up the I2S GPIOs and I2S itself (including PLL if you use it), then 'manually' feed data into its data register in a loop.

    If still no activity at the given pins, read out the relevant GPIO and I2S registers content and compare to expected values according to RM, or post them.

    JW

    ad ho
    ad hoAuthor
    Associate II
    July 28, 2017
    Posted on July 28, 2017 at 10:53

    Thanks for the tip! I am a bit too laizy to do this way, and I don't understand why the HAL would not work directly.

    ad ho
    ad hoAuthor
    Associate II
    July 28, 2017
    Posted on July 28, 2017 at 15:52

    Actually it is for an educational project and thus I need to go on the HAL + CubeMX way. Is it possible to get some support from @ST?

    Looking at 

    http://www.openstm32.org/forumthread2604

     I did exactly the same but no signal at all.
    waclawek.jan
    Super User
    July 28, 2017
    Posted on July 28, 2017 at 16:13

    What exactly of what I've wrote above can't be done using Cube and the eclipsoid?

    JW

    ad ho
    ad hoAuthor
    Associate II
    July 28, 2017
    Posted on July 28, 2017 at 16:23

    Haha nothing indeed, sorry I did not expressed myself correctly. I wanted to use the I2S api directly without going on the manual SPI thing...

    However it is in fact working, what made me think that it was not:

    • the clock is not sent when there is no data
    • when you don't feed the buffer, no output is produced
    • I was missing the one and only first data burst...

    Thus I was not measuring anything...

    Sorry I was not clear enough on how to operate with it.

    Mohamed Jallouli_2
    Associate
    July 28, 2017
    Posted on July 28, 2017 at 16:29

    Hello

    Hoffet.Adrien

    ‌,

    Is the DMA mode circular or normal? If the DMA mode is normal, you might have missed the data when it was sent but that doesn't explain the missing clock signal.

    Regards.

    ad ho
    ad hoAuthor
    Associate II
    July 28, 2017
    Posted on July 28, 2017 at 16:39

    jalloulimedd

    You spotted the issue, My DMA was in normal mode and the time I looked on my scope (that was in normal and not single shot), the clock pulse train was already finished. In circular mode it is way better !

    Cheers!