Hi, I need to use all three usarts on my 4809 40 pin dip. I picked up the following code from the Microchip help files
void USART1_sendChar(char c) { while (!(USART1.STATUS & USART_DREIF_bm)) { ; } USART1.TXDATAL = c; }
which is very helpful, I can send chars, and strings of chars to my PC serial monitor. I undersatand the code.
However, I need to reuse this code depending upon which USART I'm writing to, so I'd like to pass the USART to this function as an argument. My problem is I don't know how to type the parameter in the function definition.
Could someone help me with that please?
thanks
Paul (not a very good programmer at present...) or more positively (still learning programming) :)