I am trying to write firmware for the 244110 module. I have the dev board and the 042 programming board.
I have the BLE stuff all working. I am having trouble with the UART.
There are 2 example project for the 244110 when I create a new project. One is for transmitting and one is for receiving. Not sure why there isn't a single example that shows both, but ok. These examples use the LCD, which I don't have either, so I took that out.
I am trying to just send any data transmitted out back into the receive. I do this by just having a wire go from the TX pin to the RX pin. I am using pin P1.0 for RX and P1.1 for TX.
That is my first question. Should I have any trouble using those pins like that? Can I just connect them together and have the bytes go out one pin and come right in the other? I don't have an easy way to connect a serial port to my laptop, so I was hoping this would work.
I took the RX example and TX example and smashed them together and then modified the main.c to simply be this:
char8 ch; /* Data received from the Serial port */
CyGlobalIntEnable; /* Enable all interrupts by the processor. */
isr_1_Start(); /* Initializing the ISR */
ch = 0;
UART_1_WriteTxData(ch); /* Sending the data */
/* Check the UART status */
ch2 = UART_1_GetChar();
/* If byte received */
if(ch2 > 0u)
As you can see I just transmit a character and then try to receive it. Nothing ever comes in. I set a break point inside the if (ch2 > 0u) and it never hits the break point. This is similar to what I am seeing in my BLE firmware that tries to do the same thing.
I have attached a zip file to this post with the simple example project. Please tell me what I am doing wrong so I can get this working.
UART_Rx01.cydsn_.zip 2.2 MB