- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello Everyone,
I have created a state machine which is going to invalid state, but i haven't found why it is happening. Can you please tell me how to prevent from going to invalid state and if invalid state is achieved then how to return it to normal state?
Thanks
LD_DATA_COUNT is 8183
DE signal is data enable signal
Bus width is 16 bit
Buffer size is 16KB
Solved! Go to Solution.
- Tags:
- fx3 gpif
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello Sagar,
Please note that the CyU3PGpifGetSMState() API's parameter is a pointer variable. Hence, it has to be passed with an address value and not the variable directly. Please modify the statement as below.
stat = CyU3PGpifGetSMState(&j);
Best regards,
Srinath S
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello,
How do you identify the state machine goes into an invalid state? In case you are using CyU3PGpifGetSMState() API, kindly, post the code snippet.
Best regards,
Srinath S
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
status = CyU3PDmaMultiChannelGetBuffer (chHandle, &dmaBuffer, CYU3P_NO_WAIT);
while (status == CY_U3P_SUCCESS)
{
/* Add Headers*/
if (dmaBuffer.count == CY_FX_UVC_BUF_FULL_SIZE)
{
CyU3PDebugPrint (4, "DMA full Buffer Count: %d\r\n", dmaBuffer.count);
stat=CyU3PGpifGetSMState(j);
CyU3PDebugPrint (4, "Stat: %d, Current State: %d\r\n", stat, j);
/* A full buffer indicates there is more data to go in this video frame. */
CyFxUVCAddHeader (dmaBuffer.buffer - CY_FX_UVC_MAX_HEADER, CY_FX_UVC_HEADER_FRAME);
}
else
{
CyU3PDebugPrint (4, "DMA partial Buffer Count: %d\r\n", dmaBuffer.count);
stat=CyU3PGpifGetSMState(j);
CyU3PDebugPrint (4, "Stat: %d, Current State: %d\r\n", stat, j);
/* A partially filled buffer indicates the end of the ongoing video frame. */
CyFxUVCAddHeader (dmaBuffer.buffer - CY_FX_UVC_MAX_HEADER, CY_FX_UVC_HEADER_EOF);
#ifdef DEBUG_PRINT_FRAME_COUNT
glFrameCount++;
glDmaDone = 0;
#endif
}
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello Sagar,
Please note that the CyU3PGpifGetSMState() API's parameter is a pointer variable. Hence, it has to be passed with an address value and not the variable directly. Please modify the statement as below.
stat = CyU3PGpifGetSMState(&j);
Best regards,
Srinath S