FX3 is not detecting in Control Center

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

cross mob
lock attach
Attachments are accessible only for community members.
poas_4520791
Level 4
Level 4
First like received

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.

0 Likes
1 Solution

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

Regards,
Rashi

View solution in original post

0 Likes
10 Replies
poas_4520791
Level 4
Level 4
First like received

Hi,

In DMA Channel creation i am getting API return status as 64.What might be the problem?

2.PNG

Regards,

Aswini.

0 Likes

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

Regards,
Rashi
0 Likes

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.

0 Likes

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

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

Hi Rashi,

I commented all the remaining DMA Channels.Can you please check the below attached firmware.

Regards,

Aswini.

0 Likes

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

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

Hi,

Now i commented all the DMA channel other than P to S channel.But still error remains same.

Regards,

Aswini.

0 Likes

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

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

Hi,

Below attached is the header file of the project.

Regards,

Aswini.

0 Likes

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

Regards,
Rashi
0 Likes