uart串口打开和读写

时间:2020-12-03 16:56:41
【文件属性】:
文件名称:uart串口打开和读写
文件大小:4KB
文件格式:ZIP
更新时间:2020-12-03 16:56:41
linux uart uart串口应用开发,串口打开,串口的读写,我自己调试过是可以的,可以互相学习。int UartRead(int uartFd,char *buff,int bufLen) { int nRead = 0; if(uartFd<0) return -1; nRead = read(uartFd, buff,bufLen); if(nRead > 0){ buff[nRead]=0x0; } return nRead; }
【文件预览】:
uart
----uart_api.h(857B)
----uart_api.c(5KB)
----Makefile(584B)
----uart_main.c(2KB)

网友评论