This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

adding DLOG to c28027 project

Hello,

I want to use DataLOG module in C28027 micro based project. For this feature,

- DLOG4CH-HVPM_eSensorless.h and DLOG4CHC.ASM files are added to project. And  initializations and calling are shown below are done in main .c file by taking referance HVPMSM_sensorless.

F2802x_Headers_nonBIOS.CMD file under the adress device support/ f2802x / v210 / f2802x_headres / cmd and f28027.CMD file under the adress device support/ f2802x / v210 / common/ cmd is used or the project.

After compiling project the warning "warning #10247-D: creating output section "DLOG" without a SECTIONS" is seen in the CCS editor.

And after running project and  then graph under the folder HVPM_Sensorless graph1.graphProp -  graph2.graphProp I cant see any variables on the graph. What can be the problem?

 

int16 DlogCh1 = 0;

int16 DlogCh2 = 0;

int16 DlogCh3 = 0;
int16 DlogCh4 = 0;

-DLOG_4CH dlog = DLOG_4CH_DEFAULTS;

// Initialize DATALOG module
dlog.iptr1 = &DlogCh1;
dlog.iptr2 = &DlogCh2;
dlog.iptr3 = &DlogCh3;
dlog.iptr4 = &DlogCh4;
dlog.trig_value = 0x1;
dlog.size = 0x00c8;
dlog.prescalar = 5;
dlog.init(&dlog);

DlogCh1 = (int16)_IQtoIQ15(svgen1.Ta);
DlogCh2 = (int16)_IQtoIQ15(svgen1.Tb);
DlogCh3 = (int16)_IQtoIQ15(svgen1.Tc);
DlogCh4 = (int16)_IQtoIQ15(svgen1.Tb-svgen1.Tc);

Regards,

  • Hello Rasit,

    Please try to add new section in your F28027.cmd file:

    SECTIONS
    {
        DLOG: > DRAML0,PAGE=1
    }

    Hope this helps.

    Best regards,

    Maria

  • Hello Maria,

    Your recommendation solved the problem about placing DLOG buffer to RAM memory. The warning  "#10247-D: creating output section "DLOG" without a SECTIONS" is not seen anymore.

    In CMD file is written as given below for DLOG buffer.

    DRAML0      : origin = 0x008800, length = 0x000800     /* on-chip RAM block L0 */

    {
    DLOG: > DRAML0,PAGE=1
    }

    After compiling and running the program I check the dual time graph. But random signals magnitude of which is between -1 and 1is appeared in the graph. I was expecting rg1.out (sawtooth), and other duty values (svgen1.Ta, Tb) values while motor running. Graps settings is written below

    Acquisition Buffer Size: 200;

    Dsp data type: 16 bit signed integer

    Index Increment: 1

    Q Value: 15

    Sampling Rate Hz: 1

    Start Adress A : DLOG_4CH_buff1

     Start Adress B : DLOG_4CH_buff2

    Display Data Size: 200

    What can be problem?

    Regards,

    Raşit GÖKALAN

  • Hello Rasit,

    Did you put this line after assigning DlogCh1, DlogCh2, DlogCh3, DlogCh4 in your code?

    // ------------------------------------------------------------------------------
    //    Call the DATALOG update function.
    // ------------------------------------------------------------------------------
        dlog.update(&dlog);

    Best regards,

    Maria

  • Maria,

    You are right. This solved problem. Graph seems as expected.

    Last question, Is it possible to see DualTimeA and DualTimeB graph on the same window?

    Raşit GÖKALAN 

  • Hello Rasit,

    That's good to hear.

    I am afraid that it is not possible to put the graphic together. But I am not sure.

    Maybe you can post this question to CCS forum. If they don't have this feature, maybe they will consider to make this option next time.

    Best regards,

    Maria