F28035 simulink example file: "c28x_LedBlink_ert" After the program was loaded, I clicked on the "Open project in Code Composer Studio" in the simulink "Diagnostic Viewer". In the CCS watch window, I was going through the register values and had a few questions:
1) In the CCS watch window for "c28x_LedBlink_ert" "GPAPUD" by default has a value 0x00000FFF (pull up disabled for GPIOs 0 to 11, which are PWMs), similarly "GPBPUD" has a default value of 0x00000300 (pull up disabled for GPIO 40 & 41, again these are PWMs). However I can't seem to find the file that initializes the registers with the mentioned values, the only file initializing the "GPxPUD" register is in fact the "DSP280x_Gpio.c" file which initializes the pull ups using the following two lines:
GpioCtrlRegs.GPAPUD.all = 0x0000; GpioCtrlRegs.GPBPUD.all = 0x0000;
So there has to be another file overwriting these registers, could I be directed to that file/function?
2) The "c28x_LedBlink_ert" toggles the GPIO pins 31 & 34, so that means that those GPIOs should be set as outputs, again looking at the watch window I observe that "GPADIR" has a value of 0x80000000 (i.e. GPIO 31 = output) and "GPBDIR" has a value of 0x00000004 (i.e. GPIO 34 = output), so things are fine. However shouldn't the pull ups be disbaled since these are outputs? Shouldn't "GPAPUD" be 0x80000FFF and "GPBPUD" be 0x00000304?
Thanks in advance