Skip to main content
Graduate II
April 5, 2024
Solved

Can I use OCTOSPI as a Classic SPI?

  • April 5, 2024
  • 2 replies
  • 2667 views

Hi.

 

I am using STM32H735VG for SPI communication with external ADCs.

But I want to add external ADCs and I already used all 5 SPIs.

So I will use OCTOSPI, can OCTOSPI play the same role as classic SPI?

In menual, OCTOSPI in indirect operating mode works like a classical SPI interface.

If they play the same role, how I set the pin?

(I will use only one OCTOSPI.)

 

Thank you.

    This topic has been closed for replies.
    Best answer by KDJEM.1

    Hello @giwonKIM and welcome to the Community :),

    The OCTOSPI provides a flexible hardware interface, that enables the support of multiple hardware configurations: Single-SPI (legacy SPI), Dual-SPI, Quad-SPI, Dual-quad-SPI and Octo-SPI. Please take a look at FAQ: Does OctoSPI interface support QuadSPI memories?

    To set and configure the OCTOSPI interface , I recommend you to refer to AN5050 precisely "6 OCTOSPI application examples" section.

    Note that, the OctoSPI  work only as a master, for that this interface supports the Single-SPI (legacy SPI). 

    For more information, I advise you to take a look at RM0468 section OCTOSPI regular-command protocol Section.

    I think this discussion can help you.

    I hope this answer your request!

    Thank you

    Kaouthar

     

     

    2 replies

    KDJEM.1Answer
    Technical Moderator
    April 5, 2024

    Hello @giwonKIM and welcome to the Community :),

    The OCTOSPI provides a flexible hardware interface, that enables the support of multiple hardware configurations: Single-SPI (legacy SPI), Dual-SPI, Quad-SPI, Dual-quad-SPI and Octo-SPI. Please take a look at FAQ: Does OctoSPI interface support QuadSPI memories?

    To set and configure the OCTOSPI interface , I recommend you to refer to AN5050 precisely "6 OCTOSPI application examples" section.

    Note that, the OctoSPI  work only as a master, for that this interface supports the Single-SPI (legacy SPI). 

    For more information, I advise you to take a look at RM0468 section OCTOSPI regular-command protocol Section.

    I think this discussion can help you.

    I hope this answer your request!

    Thank you

    Kaouthar

     

     

    giwonKIMAuthor
    Graduate II
    April 5, 2024

    Thank you.

     

    If Single-SPI of OCTOSPI works the same as the legacy SPI, do IO1, IO2 pins behave the same as MOSI and MISO pins?

     

     

    Technical Moderator
    April 5, 2024

    Hi @giwonKIM ,

    As mentioned in RM0468, if you want to use the OCTOSPI as SPI, the SO/IO0 signal will be used to output the data from STM32, then it is MOSI (master Output Salve Input). The IO1 (SI) signal will be used to receive data so it acts as MISO.

    KDJEM1_0-1712304507011.png

    I suggest you to take a look at this post "Which OCTOSPI pins can be used as MOSI and MISO in single mode?"

    Thank you for your contribution in STCommunity.

    Kaouthar

    giwonKIMAuthor
    Graduate II
    April 5, 2024

    Thank you very much.

    Visitor II
    April 5, 2024

    As long as you do not need a full-duplex SPI (MOSI and MISO in both direction at the same time - as a "regular" SPI is) - you can use OCTOSPI as "single SPI".

    Bear in mind: STM calls it "single SPI" but not "regular SPI"!

    It is NOT a full, regular SPI, not with full-duplex. OCTOSPI works only in "half-duplex" mode: Tx or Rx, but never both at the same time (not possible, see the commands you can configure, never READ + WRITE).