how to transfer about 3 Mb file from control center to fx3

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

cross mob
veRN_2322216
Level 3
Level 3
5 likes given First like received First like given

Hello ,

            I am using Cypress control Center to transfer data from fx3 to PC and PC to fx3. my requirement is to transfer about 3 MB  file to Fx3 using BULK OUT END POINT 01 using Transfer File Out  Button .If i tried  for lower size files it is transmitting successfully but if i tried for larger files 997 error is coming can any one help me to sort out this problem

I also attached the screen shots of control center while transferring small files and the large files c1.pngc2.png

                       best regards veerendra

0 Likes
1 Solution
Anonymous
Not applicable

Hi,

The firmware loaded into FX3 must be able to handle such high amounts of data. The DMA Buffers in FX3 that are filled should be emptied as soon as the data is received, so that there is room for more and more incoming data. Once a part of the data is received in FX3's DMA Buffers, it should be transmitted out via some other interface (say GPIF, UART, SPI etc.) or the buffer should be simply discarded (if it is for testing purpose).

The reason why the small file was received was the DMA Buffers were able to accommodate  the whole file.

Regards,

- Madhu Sudhan

View solution in original post

0 Likes
6 Replies
Anonymous
Not applicable

Hi,

The firmware loaded into FX3 must be able to handle such high amounts of data. The DMA Buffers in FX3 that are filled should be emptied as soon as the data is received, so that there is room for more and more incoming data. Once a part of the data is received in FX3's DMA Buffers, it should be transmitted out via some other interface (say GPIF, UART, SPI etc.) or the buffer should be simply discarded (if it is for testing purpose).

The reason why the small file was received was the DMA Buffers were able to accommodate  the whole file.

Regards,

- Madhu Sudhan

0 Likes
NoriTan
Employee
Employee
25 sign-ins 5 questions asked 10 sign-ins

I did transfer a ~3MB file (the 2,970,707 Byte length AN65974 PDF file) into the USBBulkSourceSink example project using the Control Center application as follows.

GS003324.png

The USBBulkSourceSink firmware receives BULK-OUT packets from PC and discards all packets.

I will try USBBulkLoop firmware next.

Regards,

Noriaki

NoriTan
Employee
Employee
25 sign-ins 5 questions asked 10 sign-ins

The USBBulkLoop firmware receives packets from the Bulk-OUT endpoint and sends the received packets to the Bulk-IN endpoint.  Because the data buffer size in the FX3 is limited a receiver must be prepared on the PC to receive packets from the Bulk-IN endpoint.  In following investigation, I opened two Control Center applications for Bulk-OUT and Bulk-IN endpoints.

The investigation steps are follows.

  1. Download the USBBulkLoopAuto firmware to the FX3's RAM area.
  2. Open another (2nd) Control Center application.
  3. On the 2nd Control Center, select the "Bulk in endpoint" in the descriptor tree.
  4. On the 1st Control Center, select the "Bulk out endpoint" in the descriptor tree.
  5. On the 1st Control Center, click "Transfer File-OUT" button and select a file to be sent.  Do not click the "Open" button.
  6. On the 2nd Control Center, enter "4000000" to the "Bytes to transfer" text box.  The number must be bigger than the file size to be sent.
  7. On the 2nd Control Center, click "Transfer File-IN"
  8. On the 1st Control Center, click the "Open" button to start a file transfer.
  9. On the 2nd Control Center, a dialogue to specify a file name will open.  Enter a file name to store the received file.

GS003326.png

After the file transfer completed, it was found by the HEX address on the console that the size of transmitted and received are same.

Please note that the receiver side Control Center causes a time-out error when the step-8 is delayed.

Regards,

Noriaki

hi madhu lakhsmipathi,

                                      yes you are right but our requirement is to residence the around 3mb data in the fx3 some where so i can use it for booting of zync .i.e i want to send that data from fx3 to Zync. so i want to send the data as a file from control center to fX3  for booting zync.

i hope you understood me .

thanks regards veerendra

0 Likes
Anonymous
Not applicable

Hi Veerendra,

FX3 cannot store a file as big as 3 MB. You need to send the file to Zync part by part as soon as you receive every part from the control center.

Or, you can have an external memory like an SPI Flash in your board. As the data is sent from Control Center, you can store it part by part in SPI Flash.

Whenever you want to Boot up Zync, Fx3 can read the data back from SPI Flash part by part and send it to Zync.

You can refer to our cyfxusbspidmamode example projects on how to read / write SPI Flash using FX3.

Regards,

- Madhu Sudhan

Hello sir,

             thanks  for your response towards my post and because of your response i resolved lots of problems facing to save data to the to pc from fx3.and once again thanks .and i came to know that you worked on fx2LP so can you guide me how to start work with fx2LP .I hope you will accept my request help me to work on fx2LP

Best regards veeerenda

0 Likes