mickeyl / LTSupportAutomotive

An iOS / watchOS / macOS support library for OBD2, VIN-Decoding, and more.
MIT License
212 stars 59 forks source link

PIDs: Add support for compute-friendly API (NSUnit and NSNumber) #12

Open mickeyl opened 6 years ago

mickeyl commented 6 years ago

Right now, the main command class LTOBD2Command provides the formattedResponse call that returns an NSString for displaying the result of a command.

To allow more sophisticated processing of the returned value (like, putting values into a database, comparing different runs, drawing graphs, etc.), it would be beneficial to add API that returns the actual units and values of a command, e.g.:

+(NSUnit)unit;
-(NSNumber)value;

Subsequently, the implementation of formattedResponse would then be rewritten to utilize these functions leveraging a (customizable?) NSUnitFormatter.

lygialiem commented 1 year ago

Hi Mickey, is this feature available now?

mickeyl commented 1 year ago

Unfortunately not. What was planned as 2.0 didn't emerge, much because of this. Hence, this library has been put into critical-bugfixes-only mode.

There has been an enormous amount of work done on an async-Swift-first successor library which features many protocols (UDS, KWP, CCP, XCP, HSFZ, …), but unfortunately economic reasons have dictated that this is going to be a proprietary closed source library. A corresponding commercial SDK is planned to be offered in the near future.

lygialiem commented 1 year ago

Hi Mickey. Thank you for your response.