3 Replies Latest reply on May 20, 2020 2:16 AM by YashwantK_46

    CX3 GPIO control and power on status

    Kudo_4595136

      Hi,  Expert

       

      I have several questions on CX3 GPIO configuration.

      1. Except GPIO17~26, GPIO44~45, Can I reuse  UART interface and I2S interface as normal GPIO to control peripherals?

          If OK, 8 GPIOs(GPIO46~57) can be used.

      2. Where can I find IO port  state after boot?  I want to know power on state for GPIOs/ SPI/UART/I2C/MIPI/I2S.

      Thank you

      Kevin

        • 1. Re: CX3 GPIO control and power on status
          YashwantK_46

          Hello Kevin,

           

          1.) You can go ahead and use the I2S as GPIO's after overriding them since they are taken out to the expansion header as GPIO50,51,52.
          But the UART interface pins are routed to another chip on the CX3 Denebola kit as shown below:

          You can override the GPIO's and would need to take the outputs/inputs from these pins as above.

          But if you are using a custom board, you can override them and use them as GPIO's.

           

          2.) Please refer to section 11 Default State of I/Os During Boot of the app note AN76405 from the following link: https://www.cypress.com/file/201991/download

           

          Regards,
          Yashwant

          • 2. Re: CX3 GPIO control and power on status
            Kudo_4595136

            Hi Yashwant

            Thanks for your feedback!

            I will use it in a custom board.

             

            but I still have questions regarding IO

            1. Can all these IO be used a interrupt input?

            2. If using IO to simulate PWM wave via software, what is max frequency for this PWM?

             

            BR

            Kevin

            • 3. Re: CX3 GPIO control and power on status
              YashwantK_46

              Hello Kevin,

               

              1.) As mentioned in Section 4.1 of the FX3_TRM,

              --> You can configure all the 60 GPIO's as Simple GPIO's with Interrupt functionality.

              But the concept of configuring complex GPIO's from the total 60 GPIO's is mentioned in the above snapshot.

               

              2.) Please refer to the firmware provided in FX3 SDK for configuring a complex GPIO from the path: C:\Program Files (x86)\Cypress\EZ-USB FX3 SDK\1.3\firmware\serialif_examples\cyfxgpiocomplexapp

              The above example uses a 1KHz PWM signal on GPIO[50] as ouput.


              Also, for more info on the PWM configuration, you can refer to the following KBA: Calculating PWM Period and Duty Cycle in FX3 – KBA226759

              For more detailed info, please refer to the answer of the following thread: Re: generating pwm on fx3

               

              The max possible PWM frequency is ~50MHz as mentioned in the above threads.

               

              Regards,
              Yashwant