NFC PN5180 porting to RT1050 SPI issue

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

NFC PN5180 porting to RT1050 SPI issue

Jump to solution
1,228 Views
yen_chen
Contributor III

Hi ,all

If I use SPI PCS0 pin and config to SPI,it will not pull low normally.

If SPI PCS0 pin config to GPIO it can pull low/high normally.

I want to config SPI for PCS0 and can low/high normally .

How can I do ?

Please see my DAL and SPI in the attachment.

 

Br,

Yen

Labels (1)
0 Kudos
1 Solution
1,217 Views
kerryzhou
NXP TechSupport
NXP TechSupport

Hi @yen_chen 

  Talk about my experience about the SPI control external modules experience.

   If the external SPI module need the special SPI CS control wave, normally, I won't use the MCU SPI IP CS, I will configure the CS pin as the GPIO, then in the Code use GPIO control high to low to generate the CS event.

   So your GPIO method, it is correct, as the IP module will control the CS directly without the freely control. You also can check the SPI register, not detail bit for the manually control, it is controlled by the IP hardware directly when you need to send the data and receive the data. 

  So, I still suggest you use the GPIO to control it.

 

Wish it helps you!

If you still have questions about it, please kindly let me know.

Best Regards,

kerry

 

View solution in original post

0 Kudos
3 Replies
1,218 Views
kerryzhou
NXP TechSupport
NXP TechSupport

Hi @yen_chen 

  Talk about my experience about the SPI control external modules experience.

   If the external SPI module need the special SPI CS control wave, normally, I won't use the MCU SPI IP CS, I will configure the CS pin as the GPIO, then in the Code use GPIO control high to low to generate the CS event.

   So your GPIO method, it is correct, as the IP module will control the CS directly without the freely control. You also can check the SPI register, not detail bit for the manually control, it is controlled by the IP hardware directly when you need to send the data and receive the data. 

  So, I still suggest you use the GPIO to control it.

 

Wish it helps you!

If you still have questions about it, please kindly let me know.

Best Regards,

kerry

 

0 Kudos
1,211 Views
yen_chen
Contributor III

Hi @kerryzhou 

If config PCS as GPIO, "PCS to clock delay time" ,time will long than config as SPI PCS.

Whether time will cause problem or not ?  

 

Br,

Yen

0 Kudos
1,208 Views
kerryzhou
NXP TechSupport
NXP TechSupport

Hi @yen_chen 

  Yes, GPIO CS control will longer than the SPI IP CS control, as the software code also consume time.

  IP hardware will pull it directly.

  But, it doesn't matter, to the slave, after CS is pulled low, it will also wait the master's clk and data, so it's OK to use it. IP CS quick, but can't control it freely to match your slave detail frame situation.

Wish it helps you!

Best Regards,

kerry

0 Kudos