L2 suspend mode in FX3s when in USB 2.0 mode

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

cross mob
JaYe_3798301
Level 2
Level 2

Hi,

According to this knowledge base article:Low Power Modes in FX3, FX3S, CX3, SD3, FX2G2, and SD2 – KBA225742

There are L2, L3 and L4 low power modes for FX3S when operating at usb 2.0 mode.

Reference the LowPowerTest project in the SDK:

pastedImage_6.png

Only the 0xE3 command works in my system. And I send the command, the USB device disappear in the control center.

pastedImage_8.png

What should I do to correctly put the FX3s in the L2 mode and wake up by the host sending any USB command?

0 Likes
1 Solution

Hello,

- It is not mandatory to disconnect the USB during SUSPEND mode. In fact, when using USB bus activity as the wake up source, the USB must NOT be disconnected.

- To test the working of vendor command 0xE5, modify the configuration descriptors (SuperSpeed, High Speed and Full Speed) in the LowPowerTest firmware as follows. This modification enables the driver to put the device into U3 (USB Suspend) mode. When the device enters the U3 mode, the CY_U3P_USB_EVENT_SUSPEND event gets generated, which in turn sets the glTriggerSuspend parameter to CyTrue. Now, the UART logs can be seen to indicate the device entering the L2 suspend mode with USB bus activity as the wake-up source. Any activity on the USB Control Center/ communication with the device will result in waking up the device.

0x80,                          /* Config characteristics - Bus powered */

0xA0,                          /* Config characteristics - Bus powered */

Best regards,

Srinath S

View solution in original post

0 Likes
5 Replies
SrinathS_16
Moderator
Moderator
Moderator
1000 replies posted 750 replies posted 500 replies posted

Hello,

- 0xE3 vendor command puts the FX3 device into SUSPEND mode with UART CTS as the wake-up source. The Control Center displays error code 997 because the firmware is written such that this vendor command does not have any data phase. Please modify the "Bytes to transfer" field to 0 and perform the vendor command.

- Disconnection of device from the PC is an expected behavior as per the LowPowerTest firmware. Please ground the CTS pin of FX3 before initiating the vendor command and release the same when the device needs to be taken out of SUSPEND. This vendor command (0xE3) does not initiate wake-up from USB.

Best regards,

Srinath S

0 Likes

Hi,

Thanks for the reply.

3 more questions:

1. Is there any low power mode without disconnecting from the host?

2. If so, what should I do to correctly put the FX3s in this mode and wake up by the host sending any USB command?

3. Only the 0xE3 command has effect in my setup, is it normal?

0 Likes

Hello,

- To perform low power entry without disconnecting from the host, modify the code as below:

...

else if (glTriggerSuspend)

        {

            /* Enter suspend mode. */

            glTriggerSuspend = CyFalse;

          

            CyU3PDebugPrint (4,"Entering Suspend Mode with Wake-Up Source %d\r\n", glWakeUpSrc);

            CyU3PBusyWait (2000);  

            if (glCurVendorCmd == CY_FX_LP_UART_SUSPEND_RQT)

                //CyU3PConnectState (CyFalse, CyTrue);  /*This line is commented out*/

...

- Please let me know what happens on other vendor commands? The vendor command 0xE1 (STANDBY mode with UART-CTS as wakeup source) should also show similar behavior except that the power consumption will be lesser than in SUSPEND mode and the firmware runs from the start unlike the SUSPEND mode in which the firmware resumes from the point before entering SUSPEND.

Best regards,

Srinath S

0 Likes

Hi Srinath,

1. Is it mandatory to have the USB disconnected in the L2 suspend mode?

    I just want to know whether the 0xE3 behavior is designed to be this or it is needed to be this.

    Will keeping the USB connected affect the power consumption in L2 suspend mode?

2. I use the CyU3PDebugPrint to trace the lowpowertest example and found out the Fx3 only print out the "Entering Suspend Mode with Wake-Up Source....." with command 0xE3. And there's not certain message with command 0xE4, 0xE5.

3. Again, my goal is to have the Fx3 enter L2 suspend mode and wake up by the host by sending USB packers.

0 Likes

Hello,

- It is not mandatory to disconnect the USB during SUSPEND mode. In fact, when using USB bus activity as the wake up source, the USB must NOT be disconnected.

- To test the working of vendor command 0xE5, modify the configuration descriptors (SuperSpeed, High Speed and Full Speed) in the LowPowerTest firmware as follows. This modification enables the driver to put the device into U3 (USB Suspend) mode. When the device enters the U3 mode, the CY_U3P_USB_EVENT_SUSPEND event gets generated, which in turn sets the glTriggerSuspend parameter to CyTrue. Now, the UART logs can be seen to indicate the device entering the L2 suspend mode with USB bus activity as the wake-up source. Any activity on the USB Control Center/ communication with the device will result in waking up the device.

0x80,                          /* Config characteristics - Bus powered */

0xA0,                          /* Config characteristics - Bus powered */

Best regards,

Srinath S

0 Likes