心理

當前位置 /首頁/完美生活/心理/列表

51串口通信指令如何發送

51串口通信指令如何發送

#include "reg52.h"

void UartConfiguration(void)

{

}

const unsigned char codeData[] = {"AT%IPSEND=�"

"}

void UartSendString(unsigned char *string)

{

while(*string != '')

{

SBUF = *(string++)

while(!TI)

TI = 0

}

}

void main(void)

{

UartConfiguration()

UartSendString(codeData)

while(1)

}

串口初始化的函數沒寫

TAG標籤:通信 指令 串口 發送 #