You're probably doing it wrong if you need this. You are going to get into trouble if you need to read the file and the nmea receiver needs to write to it at the same time for example. If you're running on a Pi with a responsive application you might find that things are buffered sufficiently for you to process them.
There are several GPS utilities for Linux, the most common being gpsd. gpsd will manage the GPS for you, and your client software can just ask it what's going on.
You could also try something simple like tee, which could open the GPS port, pass the data through to stdout, and log it to a file. But this will log everything, which sounds like not what you want.
There are several GPS utilities for Linux, the most common being gpsd. gpsd will manage the GPS for you, and your client software can just ask it what's going on.
You could also try something simple like tee, which could open the GPS port, pass the data through to stdout, and log it to a file. But this will log everything, which sounds like not what you want.
Statistics: Posted by ame — Wed Jun 11, 2025 2:15 am