SPI real Data rate in CYUSB3014-BZXI

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

cross mob
kjlee_2215711
Level 2
Level 2
5 questions asked 10 replies posted 10 sign-ins

Hello,


We are using the CYUSB3014-BZXI.
If I look at CYUSB301X_FX3_DataSheet(Document Number: 001-52136 Rev. *X), the maximum operating frequency is 33MHz.
1. When sending and receiving data with SPI at 33MHz clock, what is real data rate?


When measured with digital oscilloscope, it looks like there is some difference between the clock rate and the data rate because there is a gap between
the bytes of data. There is N - 1 gaps if N bytes transfer.

2. Is there any way to reduce this interval gap to speed up data transfer?

 

Thank you so much for your prompt response.

 

Best Regards,

KJ

 

0 Likes
11 Replies
Rashi_Vatsa
Moderator
Moderator
Moderator
5 likes given 500 solutions authored 1000 replies posted

Hello,

Please let me know what bit rate is seen in the traces and kindly confirm if the issue is seen with the default firmware in FX3 SDK (usbspiregmode/usbspidmamode)

If yes, please share the firmware and SPI traces for us to check

Regards,
Rashi
0 Likes

Hi Rashi,

Thanks for your quick reply.

We are using FX3 SDK v.1.2 usbspiregmode, of course the code for our board has been added.
First of all, we want to know the basic bitrate of SPI communication in default firmware in FX3 SDK usbspiregmode.

If we use SCK 24MHz, how can I guess the bit rate of SPI communication?

Regards,

KJ

0 Likes
lock attach
Attachments are accessible only for community members.

Hi Rashi,

Please refer to attached pictures which are waveform same condition when transmit 6bytes. We can see total 5 gaps between the bytes(#2).
#1: SSN
#2: SCK (12MHz)
#3: MOSI
#4: MISO
The Gap time is measured about 1usec. It doesn't change much and always stays around 1usec even if we change SCK.
So, I guess the bit rate can not exceed 8Mbps, even if we use SCK 33MHz.

Questions are.
1. What is the actual bitrate of SPI transmission when using SCK 24MHz?
2. Is there any way to reduce the gap to speed up data transfer?

Thank you so much for your help in advance.

Best Regards,

KJ

0 Likes

Hello,

The SCK will be active till the time FIFO has data to be sent. Please let me know how many bytes of data is being sent by the master.

Please share the SPI configuration settings and let me know how much data is being sent by the master.

Regards,
Rashi
0 Likes

Hello,

Please refer to below code sippet.

CyU3PMemSet ((uint8_t *)&spiConfig, 0, sizeof(spiConfig));
spiConfig.isLsbFirst = CyFalse;
spiConfig.cpol = CyFalse; //CyTrue;
spiConfig.ssnPol = CyFalse;
spiConfig.cpha = CyFalse; //CyTrue;
spiConfig.leadTime = CY_U3P_SPI_SSN_LAG_LEAD_HALF_CLK;
spiConfig.lagTime = CY_U3P_SPI_SSN_LAG_LEAD_HALF_CLK;
spiConfig.ssnCtrl = CY_U3P_SPI_SSN_CTRL_FW;
spiConfig.clock = nHz;
spiConfig.wordLen = 12000000;
status = CyU3PSpiSetConfig (&spiConfig, ULL);

The master was sending 5 bytes of data.

Regards,

KJ

0 Likes

Hello,

Apologies for the delay in response.

Please let me know word len supported by SPI slave. Kindly, populate the field with the same value.

spiConfig.wordLen = .......

Also, how many bytes are being sent when through SPI. Are you using SPI in DMA mode or register mode?

Regards,
Rashi
0 Likes

Hello,

There are some misspelled and corrections are follows.

spiConfig.clock = 12000000;
spiConfig.wordLen = 8;

Sorry for the confusion.

4800 bytes are being sent in register mode.

 

Regards,

KJ

0 Likes

Hello,

Please share the firmware and SPI traces for us to check

Regards,
Rashi
0 Likes

Hello,

The project was dropped.

Thank you very much for your help so far.

Regards,

KJ

0 Likes

Hello,

Thank you for the update.

We would suggest using the latest SDK 1.3.4 

 

Regards,
Rashi
0 Likes

Hello,

I uploaded information for your better understand.

Our team are very much looking forward to your reply. We need your answer based on default FX3 SDK firmware.

If you need more information please let me know.   

Many thanks for your quick response in advance.

Regards,

KJ

0 Likes