DavidEGrayson / minimu9-ahrs

Program for reading data from the Pololu MinIMU-9 over I²C. Works on the Raspberry Pi and other embedded ARM Linux boards.
Other
167 stars 68 forks source link

ahrsd (like gpsd) anyone? #6

Closed ssokol closed 10 years ago

ssokol commented 11 years ago

David,

Thank you very much for all the hard work that must have gone into this. I was able to set it up and make it work with Pololu's AltiMU-10 - the next generation of their sensor board that includes barometric pressure. If I can muster up enough C++ skill I will be adding the altimeter function to the ahrs (which makes it a half-baked adahrs, I suppose).

Have you given any thought to baking this into a daemon like gpsd? Exposing the data over sockets (both Unix domain and network) would be powerful. For the moment I'm faking it by piping all the data into a Redis pub/sub channel, but an actual daemon would be lighter / cleaner.

Cheers,

-S

DavidEGrayson commented 11 years ago

Hello, S. That sounds cool. For maximum flexibility, I think you should find or make a program that can accept input from minum9-ahrs on its standard input and expose that data to other programs via a socket.

minimu9-ahrs | socket-thingd

You would have to think carefully about what to do about buffering. When there are no listeners on the socket, or a slowly-reading listener the program should probably still read data from minimu9-ahrs at full speed to avoid affecting its calculations.

DavidEGrayson commented 10 years ago

I am closing this because it is a general issue with all programs that output real-time data on their standard output, and someone should make a generic solution that doesn't involve changing minimu9-ahrs, as I suggested in the last post.