4 Replies Latest reply on Sep 17, 2018 3:34 AM by LisaZ_26

    CCG2 CCG3 charge through dongle reference design firmware trouble

    aldr_3203566

      I am working with the charge through reference design and attempting to base a product design on it.  For development I have had the PCB assembled and have worked out the hardware issues, and now working on software issues.

       

      I am providing links to the other discussions related to this topic.

      https://community.cypress.com/thread/36338

      https://community.cypress.com/thread/35040

       

      The following is a link to the reference design being talked about.

      http://www.cypress.com/documentation/reference-designs/ez-pd-ccg3-usb-type-c-charge-through-dongle

       

      I have been struggling with the software end for over a week and would like some assistance with the CCG2 programming.

      Which sample code was used for the reference design?  I am assuming it was fully tested at Cypress before the reference design files were released.

       

      The closest example I can find to match this reference design is the following two sample code…

      CCG2 CYPD2122-24LQXI_notebook

      CCG3 CYPD3123-40LQXI_ctd_us

       

      The CCG3 appears to work correctly, but, I am having trouble with the CCG2 firmware.  Specifically I am going to list the issues I am having.

      + The notebook example has DP source enabled

         + attempting to disable it by changing usbpd_config.h

         + changing this line #define DISPLAY_PORT_SNK_CONFIGURATION (DISPLAY_PORT_SNK_SUPPORTED)

         + change to #define DISPLAY_PORT_SNK_CONFIGURATION      (DISPLAY_PORT_SNK_NOT_SUPPORTED)

         + this results in several linker errors and I do not know how to resolve these…

         + I dont know where the code is located that I need to remove related to DP

         + I can locate a type_c_manager.h, but not a type_c_manager.c

         + ERROR: L6218E: Undefined symbol dp_source_deinit (referred from type_c_manager.o).

         + ERROR: L6218E: Undefined symbol dp_source_init (referred from type_c_manager.o).

         + ERROR: L6218E: Undefined symbol get_dp_state (referred from usbpd_hpi.o).

         + ERROR: L6218E: Undefined symbol update_dp_config (referred from usbpd_hpi.o).

       

      + Next, the PDO data from the charger plugged into the CCG2 port (UFP?) is supposed to be relayed to the CCG3 by means of HPI

         + There should be an interrupt triggered from the CCG2, but I dont believe this is being triggered.

         + I believe this logic is not in the CCG2 notebook example.

       

      + Next I would like to change the logic of the CCG2 to act as a UFP only.

         + As it is now it acts as a DFP since it is from the notebook example

         + This is the only starting point I can find for this CCG 2122 part, and would like to alter the logic to fit the proper role.

       

      + Finally, I am a little confused with the best configuration of the jumper positions.

         + The jumpers I am mostly confused with are

          + J1, it connects VSYS to either 3V3, 5V0, or the CCG3 programming VTarg pin

         + J19 connects pull up resistors for system_i2c to either VSYS or CCG3_VDD

         + J18 connects pull up resistors for CCG3_NB_I2C to either CCG_VDD or VSYS

       

      A response from someone familiar with the charge through reference design would be appreciated.

      Also, some assistance with altering the CCG2 code to remove the DP components and enable the HPI communication between the CCG2 and CCG3 would be greatly appreciated.

        • 1. Re: CCG2 CCG3 charge through dongle reference design firmware trouble
          LisaZ_26

          Hi ,

           

          I have been made a example for remove HPI and dispalyPort, kindly refer link: Simple CCG2 example firmware for power bank

           

          Best Regards,

          Lisa

          • 2. Re: CCG2 CCG3 charge through dongle reference design firmware trouble
            aldr_3203566

            Thank you I have resolved the issue of removing the DP support from the project.

             

            I still have not resolved the following below issues...

             

            I will copy paste from the original content...

             

            + Next, the PDO data from the charger plugged into the CCG2 port (UFP?) is supposed to be relayed to the CCG3 by means of HPI

               + There should be an interrupt triggered from the CCG2, but I don’t believe this is being triggered.

               + I believe this logic is not in the CCG2 notebook example.

             

            + Finally, I am a little confused with the best configuration of the jumper positions.

               + The jumpers I am mostly confused with are

                + J1, it connects VSYS to either 3V3, 5V0, or the CCG3 programming VTarg pin

               + J19 connects pull up resistors for system_i2c to either VSYS or CCG3_VDD

               + J18 connects pull up resistors for CCG3_NB_I2C to either CCG_VDD or VSYS

             

            Update: I have discovered issues related to mis-configuration of the jumpers...

            J1 needs to be in position to connect VSYS to either 3V3 (1-4 position) or 5V0 (3-4 position) (connecting to 2-4 position does not function correctly)

            J19 should be in the 1-2 position connecting CCG3_VDD to SYSTEM_I2C pullup resistors (2.2k), failure to connect this results in not being able to charge the device connected to the USBC plug.

            J18 does not appear to have effect.  This connects CCG3_NB_I2C to either CCG3_VDD or VSYS.

            Can you confirm the above jumper configuration?

             

            Next I would add that I have some trouble with the Galaxy S8, I will add this in a different topic.

             

            Thank you.

            • 3. Re: CCG2 CCG3 charge through dongle reference design firmware trouble
              aldr_3203566

              Concerning this reference design firmware

              CYPD2122-24LQXI_ctd_ds for use with this reference design...

               

              I had to dig around a lot to locate this firmware, it was difficult to find and hope it was mentioned more clearly in the reference design webpage

              http://www.cypress.com/documentation/reference-designs/ez-pd-ccg3-usb-type-c-charge-through-dongle

              This is why I had many question and had trouble initially with this reference design... I could not find the firmware that was tested on it.

               

              I eventually found this firmware, however, it has been removed in the 3.0.2 SDK forward, without mention of why.  Is there a reason?

              It is mentioned in the document

              Release Notes CCGx Software Development Kit Version 3.0.2, April 10, 2017

              http://www.cypress.com/file/358961/download (this link was found on internet search engine, it is not referenced anymore on Cypress web)

              However, the folder/file does not exist... perhaps the document was not updated or the file was removed just before release.

               

               

              Eventually after searching through the v3.0.1 documents

              CCGx SDK v3.0.1 ReleaseNotes.pdf http://www.cypress.com/file/333226/download

              and

              CCGx SDK v3.0.1 UserGuide.pdf http://www.cypress.com/file/333231/download

              And I was able to locate it in the v3.0.1 SDK after downloading and installing it.

              However, it is in binary form only.

               

               

              The above documents can be found on this page

              http://www.cypress.com/documentation/software-and-drivers/ez-pd-software-development-kit

              and

              http://www.cypress.com/documentation/software-and-drivers-archive/ez-pd-sdk-archives

               

               

              It might be a good idea if this is passed on to the people who manage these documents.

              I assume there are issues of removal of other reference design firmware from later SDKs, but there is no mention on the reference design pages where the firmware that was tested with the design can be found.  I believe this is an important part of the development using a reference design.

               

              Concerning this CYPD2122-24LQXI_ctd_ds firmware.  In the V3.0.1 SDK release this is available in binary form.

              It would be very helpful if it was available in source code as well so the design can be customized.

              If this is not feasible... required rebuilt libraries not available, etc, can this be confirmed?

               

              The closest available project I can find to match this is CCG2 CYPD2122-24LQXI_notebook, however, it does not include the necessary logic to correctly communicate with the CCG3 CYPD3123 from what I understand.  If some short instructions can be provided to alter the CYPD2122-24LQXI_notebook to match the CYPD2122-24LQXI_ctd_ds firmware it would be greatly helpful in speeding up understanding of the charge through dongle reference design.

               

              Thank you.

              • 4. Re: CCG2 CCG3 charge through dongle reference design firmware trouble
                LisaZ_26

                Hi ,

                 

                Please kindly notice the release notes http://www.cypress.com/file/358961/download  only includes HEX/binary file of CYPD2122-24LQXI_ctd_ds.

                It is same file the one attached in the link of Charge Through Dongle website page. Since the firmware is power sink only and can re-use the SDK project of CCG2 to achieve this.

                 

                Best Regards,

                Lisa

                1 of 1 people found this helpful