Skip to content

Commit

Permalink
yolo
Browse files Browse the repository at this point in the history
  • Loading branch information
ahupowerdns committed Jul 24, 2019
1 parent be82279 commit e793f44
Show file tree
Hide file tree
Showing 3 changed files with 262 additions and 50 deletions.
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
CXXFLAGS:= -std=gnu++17 -Wall -O3 -MMD -MP -ggdb -fno-omit-frame-pointer -Iext/fmt-5.2.1/include/

PROGRAMS = ubxparse
PROGRAMS = ubxparse minread

all: $(PROGRAMS)

Expand All @@ -10,5 +10,5 @@ clean:
rm -f *~ *.o *.d ext/*/*.o $(PROGRAMS)

ubxparse: ubxparse.o ext/fmt-5.2.1/src/format.o
g++ -std=gnu++17 $^ -o $@ -pthread
g++ -std=gnu++17 $^ -o $@ -pthread -lncurses

3 changes: 2 additions & 1 deletion minread.cc
Original file line number Diff line number Diff line change
Expand Up @@ -41,11 +41,12 @@ int main()
tcsetattr(fd,TCSANOW,&newtio);

for(;;) {
res = read(fd, buf, 255);
res = read(fd, buf, 25);
if(res < 0)
break;
for(int n=0; n < res; ++n)
printf("%c", buf[n]);
fflush(stdout);
}
tcsetattr(fd,TCSANOW,&oldtio);
}
Expand Down
Loading

0 comments on commit e793f44

Please sign in to comment.