Qspi

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
User16347
Level 1
Level 1
Is there a way to set the level of the MOSI (=MTSR)-pin outside the active CS (=SLSO) phase ?

I would like to MOSI-pin to always have Lo, when the CS becomes inactive. Currently MOSI retains its last level until the next transmission.

Peter
0 Likes
4 Replies
User20639
Level 3
Level 3
First solution authored 10 replies posted 5 replies posted
Can you try using the IfxPort_setPinLow() function? It would definitely override the pin's state, not sure if it would switch back to QSPI control after. Worth a try.
0 Likes
User16347
Level 1
Level 1
Thank you qcoret.
I was hoping that there is an automatic way to achieve this, just by config of the QSPI - such possibility f.e. exists on the S32K family.
0 Likes
cwunder
Employee
Employee
5 likes given 50 likes received 50 solutions authored
Unfortunately there is not a setting to force the MOSI low after a transfer as it holds the value of the last bit sent (I agree this would be a nice feature). For this behavior I think you could perform a GLOBALCON.RESETS = (7 on TC2xx and 1 on TC3x devices) to flush the FIFO's (and State Machine). Then the QSPI MISO should be at a low level.
0 Likes
User20639
Level 3
Level 3
First solution authored 10 replies posted 5 replies posted
Had an idea. It's a bit far-fetched but it could work "automatically".

QSPI can generate an interrupt on phase transition using GLOBALCON1.PT1 or PT2. If you generate the interrupt at EOF, then when you service your interrupt, you can set the pin level to the desired level. It will be "automatic" as in it'll happen every time you send a frame.
0 Likes