2016-10-05 09:30 PM
is there any way so that i can know whether my uart is active or not ,i wanna send an AT Command to a gsm module such as ''AT+CCLK?'' in return of this command the GSM module will give the time and date from nearest gsm tower as reply to that AT Command, actually i want a function just like Serial.available()>0 in arduino. I'm using Keil 5 and a beginner so please help me out.
2016-10-06 05:15 AM
You'll need to accumulate characters in a USART RXNE interrupt, and count them.
ie buffer[available++] = USART_ReadData