- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
I am using the below attached firmware to transfer data from P-Port to S0-Port of FX3.The data from DDR3 is sent to P-Port of FX3.Before programming FX3,it is detecting as a Bootloader device in Control Center but after programming the below firmware,it is showing nothing in control center.Can anyone please check this at your end and let me know what might be the reason?
Regards,
Aswini.
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello Aswini,
I wen through the firmware you shared and found
> The I2C block is not enabled in the iomatrix, and the I2c functionality is used in the firmware. If you want to have I2C functionality you need to enable I2C block in the io matrix configuration.
And the channel creation is failing because the channel is being created between PIB > SIB but the SIB block is not started as PIB block is started using PibInit, similarly sib block need to be started before creating the channel using sibstart API
Regards,
Rashi
Rashi
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
In DMA Channel creation i am getting API return status as 64.What might be the problem?
Regards,
Aswini.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello Aswini,
The error 64 (0x40) is due to bad argument.
Please check the following
- the producer socket and consumer sockets are valid i.e. ther are not used with any other DMA channel.
- You have not mentioned the DMA mode in the DMA channel configuration
- couldn't find the prodAvailCount
- also check that total DMA buffer size allocated (including all DMA channels) should not be > 224 KB for 512 KB SRAM. If FX3 number supports 256 KB RAM, the memory allocated to DMA buffer be reduced from 224 KB. If you ask for more memory for DMA buffer than what is allocated, the API will return Bad argument error. Please confirm the SRAM size.
Regards,
Rashi
Rashi
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Rashi,
Thanks for your reply.
Below is my DMA Channel Creation for P to S Transfer
/* Create a DMA MANUAL channel for P2S transfer. */
dmaCfg.size = 512;
dmaCfg.count = 4;
dmaCfg.prodSckId = CY_FX_PRODUCER_PPORT_SOCKET;
dmaCfg.consSckId = CY_FX_CONSUMER_SPORT_SOCKET;// CY_U3P_SIB_SOCKET_0;
dmaCfg.dmaMode = CY_U3P_DMA_MODE_BYTE;
dmaCfg.notification = CY_U3P_DMA_CB_CONS_EVENT ;
dmaCfg.cb = CyFxSlFifoPtoSDmaCallback;
dmaCfg.prodHeader = 0;
dmaCfg.prodFooter = 0;
dmaCfg.consHeader = 0;
dmaCfg.prodAvailCount = 0;
apiRetStatus = CyU3PDmaChannelCreate (&glChHandleSlFifoPtoS,
CY_U3P_DMA_TYPE_AUTO, &dmaCfg);
if (apiRetStatus != CY_U3P_SUCCESS)
{
CyU3PDebugPrint (4, "CyU3PDmaChannelCreate failed, Error code = %d\n", apiRetStatus);
CyFxAppErrorHandler(apiRetStatus);
}
With the above configuration also i am getting apireturn status as 64.
Regards,
Aswini.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello Asiwini,
Can you try commenting out the other DMA channels and only create this channel. And let me know whether the channel is created or not
Regards,
Rashi
Rashi
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Aswini,
I didn't see commenting out of all the DMA channel other than P>S channel. I don't need the firmware.
Please let me know whether the Channel create API passes successfully ( without any error) or not
Regards,
Rashi
Rashi
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello Aswini,
Can you share the header (.h) file of the project which contains the definitions of macro used for producer and consumer sockets
Regards,
Rashi
Rashi
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello Aswini,
I wen through the firmware you shared and found
> The I2C block is not enabled in the iomatrix, and the I2c functionality is used in the firmware. If you want to have I2C functionality you need to enable I2C block in the io matrix configuration.
And the channel creation is failing because the channel is being created between PIB > SIB but the SIB block is not started as PIB block is started using PibInit, similarly sib block need to be started before creating the channel using sibstart API
Regards,
Rashi
Rashi