Le 28/01/2014 14:45, Adrian Custer a écrit : > Hey all, > > The page: > > https://developer.mozilla.org/en-US/docs/Web/API/MozMobileConnectionInfo.type > > lists some of the possible connection types, ending with 'etc.'. > > Unfortunately, coding against an 'etc.' is kindda hard. Working from: > > navigator.mozMobileConnection.voice.type > > I need to make a lookup object like: > > var cell_type_lookup = { > 'type': ['celltype', 'itemtype'],//Header field > > 'gsm': ['gsm', 'gsm'], > 'edge': ['gsm', 'gsm'], > 'gprs': ['gsm', 'gsm'], > 'umts': ['umts', 'gsm'], > 'hspa': ['umts', 'gsm'], > 'hsdpa': ['umts', 'gsm'], > 'hspap': ['umts', 'gsm'],//check name > 'hsupa': ['umts', 'gsm'], > > 'cdma': ['cdma', 'cdma'], > 'evdo': ['cdma', 'cdma'], > 'ehrpd': ['cdma', 'cdma'], > > 'lte': ['lte', 'gsm'] > } > > which I build from the info on: > https://mozilla-ichnaea.readthedocs.org/en/latest/cell.html > but the result is that I have to guess at values (e.g. what hspa+ might > have been converted to) and don't know how accurate or comprehensive the > lookup object might be. > > Could one of you in the know could point to the place in the code where > these values are actually defined? Thanks.
You can probably have a look in Gecko's implementation of this API :) > > > ~adrian > _______________________________________________ > dev-b2g mailing list > [email protected] > https://lists.mozilla.org/listinfo/dev-b2g _______________________________________________ dev-b2g mailing list [email protected] https://lists.mozilla.org/listinfo/dev-b2g
