How to Wake Up FX3/CX3 Using UART_CTS Pin - KBA219818

Version: **



How to wake up FX3/CX3 using UART_CTS pin? 



You can make FX3/CX3 to enter suspend mode and wake up with UART_CTS source as follows: 

  1.  Configure UART CTS as a wakeup source and polarity as High or Low through the CyU3PSysCheckSuspendParams () API
  2.  If wakeup polarity is HIGH, connect the UART CTS pin on the FX3/CX3 device to ground initially. If it is LOW, connect it to a 3.3-V source. 
  3.  Invoke the CyU3PSysEnterSuspendMode () API after checking the status from the previous step. This API is a non-returning call, which will push the device into suspend mode. 
  4.  Wait for some time.
  5. Toggle UART_CTS to HIGH by connecting it to a 3.3-V source or vice-versa for the alternate polarity case.
  6.  Device should come out of suspend and should enumerate again. 
      As per the datasheet of FX3/CX3, GPIOs could be configured as 16- or 32-bit data bus with other interfaces enabled/disabled.
      When the I/O matrix is configured to 32-bit data bus or 16-bit data+ UART, GPIO[54] acts as UART_CTS. When the I/O matrix is configured to 16-bit data bus+UART+SPI+I2S, GPIO[47] acts as UART_CTS. It will be OK to wake up FX3/CX3 with GPIO[54] being the source. 
      However, when the I/O matrix is 16-bit data bus+UART+SPI+I2S, FX3/CX3 cannot be woken up using GPIO[47](UART_CTS) as the source. It is a known issue. If GPIO[47] is expected to be the wakeup source, you should modify the gctlaon_regs.h file. 
      #define CY_U3P_GCTL_EN_UART_CTS                     (1u << 6) 
      #define CY_U3P_GCTL_EN_UART_CTS                      (1u << 4) 
      With the change above, FX3/CX3 could leave suspend mode with GIPO[47] as source.