TIDU312A May   2014  – November 2020

 

  1.   Trademarks
  2. 1Introduction
    1. 1.1 PFC Stage Implementation
    2. 1.2 BL PFC Electrical Specifications
  3. 2Software Overview
    1. 2.1 Software Control Flow
    2. 2.2 Incremental Builds
  4. 3Procedure for Running the Incremental Builds
    1. 3.1 Build 1: Open-Loop Boost With ADC Measurements
      1. 3.1.1 Build 1 Objective
      2. 3.1.2 Build 1 Overview
      3. 3.1.3 Build 1 Protection
      4. 3.1.4 Build 1 Procedure
        1. 3.1.4.1 Step 1.1: Start CCS and Open a Project
        2. 3.1.4.2 Step 1.2: Device Initialization, Main, and ISR Files
        3. 3.1.4.3 Step 1.3: Build and Load the Project
        4. 3.1.4.4 Step 1.4: Debug the Environment Windows
          1. 3.1.4.4.1 Step 1.5: Use Real-Time Emulation
          2. 3.1.4.4.2 Step 1.6: Run the Code for Build 1
    2. 3.2 Build 2: BL PFC With Closed-Current Loop
      1. 3.2.1 Build 2 Objective
      2. 3.2.2 Build 2 Overview
      3. 3.2.3 Build 2 Procedure
        1. 3.2.3.1 Step 2.1: Build and Load Project
    3. 3.3 Build 3: BL PFC With Closed Voltage and Current Loop
      1. 3.3.1 Build 3 Objective
      2. 3.3.2 Build 3 Overview
      3. 3.3.3 Build 3 Procedure
        1. 3.3.3.1 Step 3.1: Build and Load Project
  5. 4Test Results
  6. 5References
  7. 6Revision History

Step 1.2: Device Initialization, Main, and ISR Files

Note:

Do not make any changes to the source files –Only Inspect

  1. Open and inspect BridgelessPFC-DevInit_F2803x.c by double clicking on the filename in the project window. Note that system clock, peripheral clock prescale, and peripheral clock enables have been setup. Next, notice that the shared GPIO pins have been configured.
  2. Open and inspect BridgelessPFC -Main.c. Notice the call made to DeviceInit() function and other variable initialization. Also notice code for different incremental build options, the ISR intialization and the background for(;;) loop.
  3. Locate and inspect the following code in the main file under initialization code specific for build 1. This is where the PWMDRV_1ch_UpDwnCnt and ADCDRV_1CH blocks are connected in the control flow.   

      

    GUID-C2C1552A-7BB3-40EA-BF17-5DA6CD084F8F-low.gif

     

  4. Locate and inspect the following code in the main file under initialization code. This is where the PWMDRV_1ch_UpDwnCnt block is configured and initialized. This is common for all incremental builds. This PWM driver module inputs the total PWM period value of 300 and internally calculates the period register value of 150.

     

    GUID-29E2D6E5-47A4-4B66-A3BC-113BA5F85B10-low.gif

     

  5. Also locate and inspect the following code in the main file under initialization code. This is where the ADCDRV_1CH block is configured and initialized. This is also common for all incremental builds.

     

    GUID-6177948F-9E94-405D-AE8D-6B8EDCD140FF-low.gif

     

  6. Open and inspect BridgelessPFC-DPL-ISR.asm. Notice the _DPL_Init and _DPL_ISR sections under build 1. This is where the PWM and ADC driver macro instantiation is done for initialization and runtime, respectively.