Internet Explorer ist kein von TI.com unterstützter Browser. Für eine optimale Erfahrung verwenden Sie bitte einen anderen Browser.
Video Player is loading.
Current Time 0:00
Duration 11:07
Loaded: 1.50%
Stream Type LIVE
Remaining Time 11:07
 
1x
  • Chapters
  • descriptions off, selected
  • en (Main), selected

Hello, and welcome to a demonstration video of the C2000 analog-to-digital converter, or ADC's, burst mode feature. . In this video, I will be going through a brief overview of what is a sampling and conversion prioritization in a C2000 ADC and, specifically, the burst mode feature.

I will also walk through all the necessary configuration in the software and an example available with the TI-provided software development package C2000Ware. I will showcase the demonstration on an F280039C control card hardware using the CCS IDE.

The C2000 ADC operates primarily using a round robin priority sequence. As seen here in the image, the SOC 0 to SOC 15 are a part of the round robin wheel. To understand the prioritization in this ADC model, take an example where the last serviced SOC is SOC number 15. Then the highest priority in the round robin fashion would next be assigned to SOC 0.

On top of round robin sequencing, the user has an option to differentiate certain number of SOCs from the round robin sequence for a high-priority conversion. The SOCs to be selected for high-priority conversion are configurable by the user.

In the example shown in the image, SOC 0 to SOC 3 are separated out from the round robin wheel for a high-priority conversion. The number of SOCs to be separated out is configurable by the user in the range of SOC 0 to SOC 15.

Burst mode in the C2000 ADC is a subpart of the round robin sequencing where a configurable number of SOCs can be converted using a single trigger. The single trigger walks through the round robin SOC in a burst fashion.

For example, as seen in the image, SOC 0 to SOC 3 are separated from the round robin sequence for a high-priority conversion, whereas SOCs 6 and 7 are configured to operate in burst mode, that is, using a common trigger. When the trigger for a high-priority SOC and the burst signal is received at the same instant, the high priority SOC 1 is serviced first by the ADC, and the burst mode SOCs are kept in the pool of pending conversions.

Once the conversion for SOC 1 is completed, the ADC services SOC 6 and 7 sequentially in a single burst, that is, without the need of an additional trigger. In the normal round robin mode of operation, each SOC would have its own trigger. Whereas in the burst mode, multiple SOCs can be configured to operate using a single trigger in a single burst.

For additional documentation on the burst mode feature, please check burst mode section in ADC chapter of the technical reference manual of your device.

The burst mode operation can be configured using the burst control register. The primary configurations in the burst control register includes the enable bit for burst mode; the burst size, which decides the number of round robin associates to be configured; and the burst trigger configurations. The user may directly use the corresponding driver functions provided in the C2000Ware software development kit for their configuration.

One corner case for the burst mode operation that the user needs to take here is that the number of associates to be configured in the burst mode should not exceed the total available resources in the round robin fashion.

As an example, if SOC 0 to SOC 11 are configured for a high priority, then the maximum available associates that can be configured for burst mode is four, which are SOC 12 to SOC 15. This means the resistor BURSTSIZE should have the value less than or equal to 3.

Next, to demonstrate the ADC burst mode feature, I will be running the demo example available with the C2000Ware SDK. I will be using CCS version 11.1 with the example taken from C2000Ware version 4.01. The example is a SysConfig GUI-based example. It uses ePWM1 to periodically trigger the ADC at 25 kilohertz rate.

There are five channels configured to convert-- A0 to A4. There are three bursts configured and each burst triggers three conversions. Each burst converts A0 and A1, while the third conversion rotates between channels A2, A3 and A4. This is achieved using SOC 7 to 15 where three sets of SOCs are configured with each burst.

That is, on reception of the first burst trigger, SOC 7 to SOC 9 will convert channels A0, A1, and A2. Similarly, on reception of burst two trigger, SOC 10 to SOC 12 will convert channels A0, A1, and A3. Lastly, on the signal trigger for burst three, SOC 13 to SOC 15 will convert channels A0, A1, and A4.

Each burst will include channels A0 and A1 in its conversion pool, while the third conversion is taken from A2, A3 and A4. The ADCA interrupts will be used to read the results.

For external connections, the voltage distributed sample should be connected to channels A0 to A4. The pinout details corresponding to the channels can be found in the bold schematic available with C2000Ware at the below mentioned location. The results are captured in the global variables adcresult0 to adcresult4, corresponding to each adcresult resistor.

Moving on to the demonstration part-- for running the example, open CCS and import the available example from C2000Ware. For that, click on Project in the menu bar, go to Import CCS Projects, click on Browse, and look for the example project in the C2000Ware directory. The example will be available inside the driverlib, device, examples, and ADC folder. Select the burst mode example and import in CCS environment by clicking on the Finish button.

Opening the Project View, primarily, there are two files with the function code sets. The source file is the main file where all the initialization and runtime code sets, where the SysConfig is a GUI-based tool which will generate the initialization code that will be directly used in the source file. Click on ADC. In the SysConfig file, you will see all the configurations made for the ADC module.

Let's see the burst mode section first. The example is already configured for ADC, where the burst mode is enabled and configured under the Burst Mode tab. As discussed during the theoretical understanding, burst mode has basically three configurations which can be seen here-- enable the burst mode, selection of trigger for the burst, and the burst size.

It is configured as 3 for this example as per the requirements. SOC 0 to SOC 6 are configured for high priority, while the SOCs 7 to 15 are configured for the burst mode under the SOC Configurations tab.

Now, for interrupt configurations, open the Interrupt Configurations tab. Here, the ADC interrupts are configured to occur at end of conversion for each burst where the results will be read. We'll go to the main .c file next. That covers the initialization part of the burst mode.

In the source code, we have the basic initializations for the device and the PWM configurations. All the ADC initialization, then using the SysConfig tool is called using the function Board_init.

Looking further into the code, we have the ADC interrupt, adcBurstISR, in which we read the data from the result registers for each burst. The expected sequence is that the CPU should enter burst 1 first, then burst 2, and lastly, burst 3. This will validate using the breakpoints when we run the example code on target hardware.

First, I will build the example code just to make sure that there are no errors in the example code. This example is clean. But in case there were any errors, they would have shown up under the Problems tab.

Now, I will load the code on the target hardware connected to the PC. For that, you can click on the Debug then on the top left. On my end, I have F280039C control card hardware connected with the computer. Make sure appropriate Target Configuration is set as Active under the Target Configurations tab.

Once done, you can see the Run icon on top left. But before that, to see the results, we'll need to add all result variables in the Expressions window. That can be done by right-clicking on the variable in the code and selecting Add Watch Expression. Now, we'll be able to see the results in Expressions window. Make sure that you enable Continuous Refresh to get the updated results.

I will run the code by clicking on the Run icon. The results can be seen in the Expressions window. To quickly check the processed load, I can add a breakpoint in each burst section inside the ADC ISR.

When running the code, as it hits the breakpoint, I should be able to see the code getting executed in sequence-- burst 1, then burst 2, and lastly, burst 3. We are able to see that the burst sequence goes through as desired. And that concludes the ADC burst mode demonstration.

You can visit our C2000 Academy which also provides training through the features of ADC and much more. Some more training material related to ADC feature set and SysConfig have also been marked here. For additional documentation, you can always refer to the technical reference manual and data sheet of the device.

The link to download C2000Ware's software development kit has been marked here in the presentation. In case you have any additional queries, you can ask them directly to the TI engineers on the TI's E2E support forum.

That's all. Thank you for watching.

Dieses Video ist Teil einer Serie