Im using the TM4C123G6HPM along with the kentec display EB-LM4F120-L35. below is a section of code im using for push buttons. the idea is when a button is pressed a uart signal is sent through a port pin. how can i get a signal through these port pins. everything works fine when i use PA0 and PA1 i can get a signal to display using putty, but with this nothng happens
void
OnButtonPress(tWidget *pWidget)
{
uint32_t ulIdx;
uint32_t ui32ADC0Value[4];
volatile uint32_t ui32TempAvg;
volatile uint32_t ui32TempValueC;
volatile uint32_t ui32TempValueF;
//
SysCtlClockSet(SYSCTL_SYSDIV_4 | SYSCTL_USE_PLL | SYSCTL_OSC_MAIN | SYSCTL_XTAL_16MHZ);
SysCtlPeripheralEnable(SYSCTL_PERIPH_UART2);
SysCtlPeripheralEnable(SYSCTL_PERIPH_GPIOD);
GPIOPinConfigure(GPIO_PD6_U2RX);
GPIOPinConfigure(GPIO_PD7_U2TX);
GPIOPinTypeUART(GPIO_PORTD_BASE, GPIO_PIN_6 | GPIO_PIN_7);
UARTConfigSetExpClk(UART2_BASE, SysCtlClockGet(),115200,
(UART_CONFIG_WLEN_8 | UART_CONFIG_STOP_ONE | UART_CONFIG_PAR_NONE));
// Find the index of this push button.
//
for(ulIdx = 0; ulIdx < NUM_PUSH_BUTTONS; ulIdx++)
{
if(pWidget == (tWidget *)(g_psPushButtons + ulIdx))
{
break;
}
}
//
// Return if the push button could not be found.
//
if(ulIdx == NUM_PUSH_BUTTONS)
{
return;
}
else if(ulIdx == 0)
{
UARTCharPut(UART2_BASE, 'E');
}
else if(ulIdx == 1)
{
UARTCharPut(UART2_BASE, 'N');
}
else if(ulIdx == 2)
{
UARTCharPut(UART2_BASE, 't');
}
else if(ulIdx == 3)
{
UARTCharPut(UART2_BASE, 'e');
}
else if(ulIdx == 4)
{
UARTCharPut(UART2_BASE, 'g');
}
else if(ulIdx == 5)
{
UARTCharPut(UART2_BASE, 'f');
}
//
// Toggle the state of this push button indicator.
//
g_ulButtonState ^= 1 << ulIdx;
// Set the matching indicator based on the selected state of the check box.
//
CanvasImageSet(g_psPushButtonIndicators + ulIdx,
(g_ulButtonState & (1 << ulIdx)) ? g_pucLightOn :
g_pucLightOff);
WidgetPaint((tWidget *)(g_psPushButtonIndicators + ulIdx));
}