RT1064: Use LPSPI in QUAD Mode like QSPI NOR FLASH

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

RT1064: Use LPSPI in QUAD Mode like QSPI NOR FLASH

1,100 Views
MSchulz
Contributor II

Hello everybody,

I want to use the LPSPI of a RT1064 with a SCLK of 20+ MHz to transfer data to and from an FPGA. To achieve even higher bandwidth, I want to be able to use the LPSPI in QUAD Mode like QSPI.

The RT1064 would act as (Q)SPI master and the FPGA would be the (Q)SPI slave and act as bus master for a proprietary local bus inside the FPGA.

Every transaction would start in SINGLE-BIT-MODE to transfer a control word containing an opcode and an address. The opcode would control the function of the FPGA interface like 1Bit FDX Read/write or 4Bit HDX Read/Write and so on (likewise the QSPI for standard NOR FLASH does too). The PCS must be kept active throughout the complete transaction.

Single-Bit FDX Read/Write operations already work pretty good and I can use the standard API function of the MCUXpresso SDK but I have a lack of understanding how the transactions can be done when I want to use the 4Bit-mode.

In this case, the oparation mode of the LPSPI has to be changed after transferring the first control word from 1Bit FDX to 4Bit HDX Mode (writing to CFGR1 and TCR, changing from FDX to HDX transmit or receive) whilst the PCS must kept active.

Here are my questions:

  1. Is there a more detailed documentation of the software programming model of the LPSPI?
  2. Is it possible to use the standard API funtions of the MCUXpresso SDK to solve the problem?
  3. It is mentioned in the documentation, that it is possible to use LPSPI to connect to standard NOR FLASH but I didn't find any example for that. Is it ment to use QSPI-Mode for the FLASH and are there any examples for this use-case? (I think this could be helpful as QSPI NOR FLASH uses a similar transaction protocol)
  4. Are there any example for the usage of LPSPI in QUAD Mode?

Hoping that somone can help me I am looking forward for your replies,

Marco Schulz.

 

 

Labels (1)
Tags (4)
0 Kudos
Reply
3 Replies

1,026 Views
MSchulz
Contributor II

Hi Omar,

thank you for your reply.

Did you forget to append some informations here (as the sentence ends with a colon)?

"4. Unfortunately, there is no example for this but this setting needs to be set to use LPSPI in 4-bit mode:"

Best regards, Marco.

0 Kudos
Reply

1,013 Views
Omar_Anguiano
NXP TechSupport
NXP TechSupport

Omar_Anguiano_0-1686352590815.png

 

0 Kudos
Reply

1,078 Views
Omar_Anguiano
NXP TechSupport
NXP TechSupport

Hello
I hope you are well. I will gladly answer your questions.

1. The available documentation for LPSPI is present in the Reference Manual.

2. Some functions can be used but it is necessary to modify them so it adapts to your custom application.

3. This refers to the use of standard LPSPI NOR flash for recovery device unfortunately there is no example for this.

4. Unfortunately, there is no example for this but this setting needs to be set to use LPSPI in 4-bit mode:

Best regards,
Omar

0 Kudos
Reply