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.

TMS320F28027: TMS320F28027

Part Number: TMS320F28027


Hi

I am working on TMS320F28027 and I am using software drive code while coding it. I could not have found software drive code to access comparator pins and I have written direct access code for comparator pins. Before that, to be sure, I have change GPIO_setMode code with register access code and checked and have observed that gpio_mux register could not be written. when I have rewrittensoftware drive code, it is writing down to related register again. 

Here is a screenshot of the code.

Could somebody tell me what I am doing wrong please?

Regards

Fahri

  • Hi,

    One quick question did you put a breakpoint at the above Mux line? Does the code reach there?

    Regards,
    Gautam
  • Hi

    Thank you for your answer.

    Yes I put a breakpoint thee is no problem about breakpoint and I followed f28027 peripheral driver library user guide pp:8 but I could not link the file. I got an error message like that: couldn't link file:drivelib.lib

    I am still struggling with the same problem.

  • Hi
    I have overcome the problem but now there is another step.

    When I code with software driver model, it works in both Active Ram and Active Flash mode.

    Software drive model;
    GPIO_setMode(myGpio, GPIO_Number_0, GPIO_0_Mode_EPWM1A);

    However, When I code with direct access register model, it works in Active Ram mode but, it does not work Active Flash mode.

    Direct access model;
    EALLOW;
    GpioCtrlRegs.GPAMUX1.bit.GPIO0 = 1; // GPIO0 = PWM1A
    EDIS;

    Regards

    Fahri