[Ovmsdev] Issue with Open Chargemap on iOS, newest Xcode and SDK

Christopher Cook christopher.cook at webprofusion.com
Mon Dec 14 08:23:15 HKT 2015

Yes it sounds like the iOS sdk has gotten stricter parsing JSON. Assuming this is the OCM reference data being parsed nothing significant has changed there. 
Connections Types will be an array of 20-30 connection type items (j1772 etc). The parent Json object will have entries for CountryList, ConnectionTypes, UsageTypes etc

Sent from my Samsung Galaxy smartphone.-------- Original message --------From: Geir Øyvind Vælidalo <geir at validalo.net> Date: 14/12/2015  6:16 am  (GMT+08:00) To: ovmsdev at lists.teslaclub.hk Subject: [Ovmsdev] Issue with Open Chargemap on iOS, newest Xcode and SDK 
Hi guys,
I have problems with OCM when I compile with the newest Xcode and SDK. The JSON-response from OCM looks fine, but the data-object containing the JSON-response might be different from the old SDK. Trying to fetch data from the JSON-object fails.
This is the first code that fails:
- (void)syncAction:(NSDictionary *)data {    ...	    [self parseConnectionTypes:NULL_TO_NIL(data[@"ConnectionTypes"])];
The watch tells me data[@"ConnectionTypes”] is an "invalid expression”, which is understandable since data is an NSCFArray with 100 entries of NSCFDictionary, so data simply do not contain any keys. Shouldn't data have been a dictionary instead? Any ideas, guys?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openvehicles.com/pipermail/ovmsdev/attachments/20151214/fca8e082/attachment.htm>

More information about the OvmsDev mailing list