Character driver finished

This commit is contained in:
2025-02-24 14:18:48 +00:00
parent 5500b9dc74
commit 3681dbfaac
12 changed files with 340 additions and 1 deletions

View File

@@ -20,7 +20,7 @@ int main(){
FD_ZERO(&read_set);
FD_SET(fd1, &read_set);
FD_SET(fd2, &read_set);
n = select(FD_SETSIZE, &read_set, NULL, NULL, &timeout);
if( n < 0 ){
perror("select ");
@@ -40,6 +40,9 @@ int main(){
n = read(fd2, buf, 10);
printf(" read data = %s from ptwo \n", buf);
}
// close(fd1);
// close(fd2);
return 0;