Firefox OS get device information

371 Views Asked by At

I'm trying to get general device information (e.g. Name, Brand etc..) on Firefox OS but i'm struggling with the "Settings API"https://developer.mozilla.org/en-US/Firefox_OS/Platform/Settings_list and this set of API is available only for certified apps.

Is this the only way? How can I access to Device Name?

1

There are 1 best solutions below

3
On BEST ANSWER

You can use navigator.userAgent [1] to see name and brand of some devices without any permission.

For Alcatel One Touch Fire, for example, you will get: Mozilla/5.0 (Mobile; ALCATEL ONE TOUCH 4012A; rv:18.1) Gecko/18.1 Firefox/18.1

Keon and Peak, unfortunately, will only return a generic UA. You can see more UA strings at [2].

[1] http://w3schools.com/js/tryit.asp?filename=try_nav_all [2] ZTE Open userAgent String