Joke Collection Website - Public benefit messages - Zet6 sends short messages
Zet6 sends short messages
USART_IT_TXE? This is the interrupt that happened.
Static electricity Charles? DTs[5 12]; //Send buffer space
Static electricity Variable? uint 16_t? DTCursorTop = 0;
Static electricity Variable? uint 16_t? DTCursorEnd = 0;
Invalid? UART5_IRQHandler(void)
{?
//Receive register is not empty.
if(USART_GetITStatus(UART5,? USART_IT_RXNE)? ! =? Reset)
{
Charles? Data? =? UART 5->; DR; //Sorry, I don't like function calls. If interruption can save running time, then save running time.
}
//Send register is empty.
if(USART_GetITStatus(UART5,? USART_IT_TXE? )? ! =? Reset)
{
if(DTCursorTop? ==? DTCursorEnd){
open _ USARTx-& gt; CR 1? & amp=? 0xff7f// After the transmission is completed, clear the interrupt transmission flag bit.
}
Otherwise {
UART 5->; DR=? DTs[(DTCursorTop ++) & amp; 0x 1ff]; //=? 0x03
//USART_SendData(UART5,? 0x 03);
//The two statements have the same function, and the latter one will generate redundant instructions, occupying more stack space.
}
}?
}
int? sendchar(int? ch){
while((((DTCursorTop-DTCursorEnd))& amp; 0x 1ff)? == 1)){
//? UART 5->; CR 1? |=? 0x80//λ ж? ; // ? νáβ
}
DTs[(DTCursorEnd ++) & amp; 0x 1ff]? =? ch;
UART 5->; CR 1? |=? USART _ Cr 1 _ tx eie; //Set the trigger transmission interrupt.
Return? 0;
}/*? Are you online? Serial.c? */You used the wrong parameter. It's handwritten, not copied and pasted online.
- Previous article:Why is Xiaomi's coquettish SMS interception useless?
- Next article:How about Runjian Big Data Precision Teaching Platform?
- Related articles
- Congratulations to the students on their graduation from college are brief.
- Which fan has two classic SMS jokes?
- What does your girlfriend mean by texting 12?
- What is Alibaba Cloud? What can ordinary users do?
- Samsung T 108 free ringtone download
- What will happen if you tell your name, ID number and phone number when you encounter phone fraud?
- What about SMS bombing?
- Content of SMS reminder for CCB credit card overdue for 5 days.
- How to say "I'm home" in English?
- What is Zhao's WeChat account number?