Tool/software: Code Composer Studio
I've been working through the example files and trying to adapt them for use on a customer's PCB that has (unhelpfully) scrambled the pin usage - I've edited the set_pinout_f28m35x.x /.h files and am mstarting to get somewhere (I think). The idea is that I can take examples and compile them for my changed pin utilization, however, some of the examples configure additional pins. I'm looking at the adc_soc_c28.c program and it has the following lines in it which I think set up PortA pins in some way. Can someone please help me decipher what these lines (lines 62-71) do...
// Step 2. Initialize GPIO:
// This example function is found in the F28M35x_Gpio.c file and
// illustrates how to set the GPIO to it's default state.
// InitGpio(); // Skipped for this example
EALLOW;
GpioG1CtrlRegs.GPADIR.bit.GPIO0 = 1; //Set as output
GpioG1CtrlRegs.GPADIR.bit.GPIO8 = 1; //Set as output
GpioG1CtrlRegs.GPAMUX1.bit.GPIO0 = 1; //Set mux to EPWM1A
GpioG1CtrlRegs.GPAMUX1.bit.GPIO8 = 3; //Set mux to ADCSOCAn
EDIS;