in reply to Request for help in method naming

Uh... Maybe have two different poll() methods, one that returns a metric set, other for imperial? You can return an object with the measurements at a specific point in time, while the gps object has the device config and parameters.

Replies are listed 'Best First'.
Re^2: Request for help in method naming
by stevieb (Canon) on May 18, 2017 at 19:08 UTC

    That's a decent approach, but I'm thinking more along the lines of something so that the values themselves can be sent in, so the methods can operate outside of the core data storage.

    This way, parts of this module can be used without having to actually generate or used stored organized data to do some translations.

    This would definitely work though, and I hadn't thought about such an approach. It would be trivial to have poll() accept another parameter, and on each call, even an interrupt via a button could set this param (or unset it).

    I appreciate the feedback. I will keep it in mind and play around for sure.