Hey everyone,
I got myself LCDK OMAP-L138 and XDS100V2 debugger.
I try to run the blinking led project on the ARM processor but I can't seem to make the LEDs blink.
I guess I don't understand the multiplexing process but even when I use the sample as is, it doesn't work.
I tried altering the program to use the user buttons as triggers.
The buttons do trigger but the LEDs still don' turn off.
Here is my code:
int main(void)
{
/* The Local PSC number for GPIO is 3. GPIO belongs to PSC1 module.*/
PSCModuleControl(SOC_PSC_1_REGS, HW_PSC_GPIO, PSC_POWERDOMAIN_ALWAYS_ON,
PSC_MDCTL_NEXT_ENABLE);
/* Pin Multiplexing of pin 12 of GPIO Bank 6.*/
GPIOBank6Pin12PinMuxSetup();
/* Sets the pin 109 (GP6[12]) as input.*/
GPIODirModeSet(SOC_GPIO_0_REGS, 109, GPIO_DIR_OUTPUT);
/* Sets the pin 110 (GP6[13]) as input.*/
GPIODirModeSet(SOC_GPIO_0_REGS, 110, GPIO_DIR_OUTPUT);
GPIODirModeSet(SOC_GPIO_0_REGS, 37, GPIO_DIR_INPUT);
GPIODirModeSet(SOC_GPIO_0_REGS, 38, GPIO_DIR_INPUT);
while(1)
{
if(GPIOPinRead(SOC_GPIO_0_REGS, 37) == GPIO_PIN_LOW)
{
GPIOPinWrite(SOC_GPIO_0_REGS, 109, GPIO_PIN_HIGH);
GPIOPinWrite(SOC_GPIO_0_REGS, 110, GPIO_PIN_HIGH);
}
if(GPIOPinRead(SOC_GPIO_0_REGS, 38) == GPIO_PIN_LOW)
{
GPIOPinWrite(SOC_GPIO_0_REGS, 109, GPIO_PIN_LOW);
GPIOPinWrite(SOC_GPIO_0_REGS, 110, GPIO_PIN_LOW);
}
}
}
Help, anyone?
Thanks,
Joel