📜 ⬆️ ⬇️

There is something magical in Firefox OS

Over the past year and a half, I have spent more and more time working on a new Mozilla project - Firefox OS. During this time, I literally fell in love with him and his idea, having experienced something that I had not experienced before.


Screenshot Firefox OS


')
To be honest, Firefox OS is the beginning of something incredible. This is a pending revolution. Breath of fresh air. The culmination of the latest technology. It is magical and it will change everything.

What is Firefox OS?


For those who do not know what I am talking about, here is a short description.

Firefox OS is a new mobile operating system developed by Mozilla as part of the project Boot to Gecko (B2G). The OS uses the Linux kernel and is loaded into Gecko, a web engine that allows users to run applications created on HTML, JS and any other Open Web API applications.
- Mozilla Developer Network


In short, the Firefox OS project has gathered all the web technologies to create a full-fledged mobile operating system. Stop for a second and think about it - this is a mobile OS created with JavaScript!

For this, Gecko has been modified (Firefox engine), which provides a set of new JavaScript APIs needed to create functionality similar to that existing in modern mobile OS. WebTelephony for phone calls, WebSMS for sending text messages and the Vibration API for, hmm ... to vibrate.



Firefox OS is much more than the idea of ​​using the latest web technologies in a way that nobody has done before. It is also a combination of many other Mozilla projects as the only vision - the Web as a platform. The Open Web Apps initiative and Persona are some of these projects, our solution in the field of identification and authorization on the Internet (known under the official name "BrowserID"). It's amazing to see how a large number of Mozilla projects merge into one.

I will no longer go into small details, more information can be found on the MDN pages on Firefox OS . I highly recommend reading.

Why Firefox OS?


You probably think: “It sounds great, but why JavaScript?” This is a really good question. There are many reasons why the best solution was the development of a mobile OS in JavaScript.

Two main reasons are that Firefox OS fills the gap and creates an alternative to current proprietaryity and restrictions on the market for mobile platforms.

Filling the gap in the market of mobile platforms

It's no secret that smartphones are often ridiculously expensive, even in countries where income levels are quite high. But if you think that such prices exist only in rich countries, then you are deeply mistaken. 16GB iPhone 4S in Brazil costs about 615 pounds , which is 100 pounds more expensive than the same phone in England!

Such prices in Brazil are due to high import taxes. Apparently, Apple is already working to eliminate this problem, planning to build local production lines in the country. Despite this, this case perfectly makes it clear that many people cannot afford a good smartphone. Not to mention the fact that in some countries you better not swing the smartphone, the cost of which is equal to the cost of a small car .

So what to do if you want to get a good smartphone and not spend a huge amount on it? You can buy a cheap smartphone on Android, but these, as a rule, work poorly and constantly slow down.

Fortunately, we now have Firefox OS ...

The goal of Firefox OS is not to create competition for high-end devices, but to offer entry-level and mid-level smartphones at the price of a regular mobile phone.
- Bonnie Cha


Firefox OS is great for this. This OS can offer you a full-fledged smartphone based on a low-performance device, which is comparable to Android on a middle-class device. And it's not a joke.

For example, currently I am testing a javascript game on a 50 pound phone. You should not expect much from the device at this price, but in fact these games not only work faster than on the same Android phone running in a browser (Firefox or Chrome), but just as quickly, if not faster than on Android devices whose price is 4-5 times more.

Why is there such a performance increase in comparison with the results of work in the Android browser on the same devices? The secret is in fast data exchange between Gecko and iron, which allows JavaScript to work very quickly.

The high performance of JavaScript on cheap devices was one of the reasons why I’m sure that Firefox OS is the beginning of something huge.

I should note that Mozilla will not necessarily run the OS with phones costing 50 pounds, this device we use for development and testing.

Alternative and open platform

The second reason “Why Firefox OS?” Is an attempt not only to create an alternative and open mobile platform, but also to resist and try to influence the major market players.

Since Mozilla was founded in 1998 as a software developer and later as a company and organization, our mission has been to create open technologies that can compete with dominant corporate products.
- Steve Lohr


Mozilla is trying to replicate its success with Firefox, which literally broke into the browser market and showed users that there is an alternative that they can control how they use the web.

Now this mobile web is at risk. And the threat does not come from Microsoft, but from Apple and Google, manufacturers of leading mobile platforms. Their applications, proprietary platforms, proprietary application stores, and highly capricious rules for developers. Apple and Google only exacerbate the position of web technology.
- Thomas Claburn


One of the main areas that needs development is application portability ...

All the hype around mobile applications, in a sense, is a step backwards: they chain users to a specific OS and devices that support it. The web has evolved and came to the conclusion that on any hardware it can be perceived in the same way.
Mozilla, the creator of the Firefox web browser, is determined to do the same for mobile devices.
- Don Clark


Firefox OS aims to use the ubiquity of web technologies to enable you to use the same applications on your smartphone, PC, tablet, and any other device with a browser. Wouldn't you like to be able to continue playing Angry Birds on the desktop from the place where you finished it on your smartphone? I would really like that!

Developer's dream

Another reason why we need Firefox OS is that there is no OS that can be easily edited (you can change Android a little, but this is not so easy).

Firefox OS is built entirely on HTML, JavaScript and CSS. With basic web development skills, you can completely change the entire OS. Editing a single CSS line can affect the way the icons are positioned or their shape, or you can change the JS that handles phone calls.

This platform is unique to developers, and I am very interested to know what they will do with it and what it will lead to.

Good moment


Working for half a year in Mozilla, I realized how lucky I was to be here at the very moment of the birth of Firefox OS. If I remember everything correctly, the project was announced (as Boot to Gecko) in the first few weeks of my work in the company.

Everything was amazing, but over time it became even more amazing. Firefox OS is the number one priority in my work at the moment, and to be honest, I like it. It is a great honor to be part of such a project.

I wondered many times: this is a wonderful feeling - is it similar to what you experience working in Mozilla during the launch of Firefox? Excitement, passion, nervousness and inability to explain how amazing it all is, and why it should bother someone.

Honestly, I don’t think that many fully understand what it really means for everyone to launch Firefox OS. Just like Firefox, I suppose.

At the moment I am happy to work in Mozilla, in such an interesting period in the life of the company.

Admired


People who have realized the importance of this project are the developers. They were holding Mozilla demo devices at our events. And little can be as exciting as the opportunity to observe these people while they explore the device and experience various emotions ...

  1. It all starts with a slight loss - “Did you give me an Android? This is very similar to Android. ”
  2. Then comes the sudden realization that this is not Android and that the system is built on JS.
  3. After a short pause, something like “Your mother!”
  4. A little more and the person is completely immersed in the system, studying all its corners.
  5. The last stage is the reluctance to part with the device when I ask him back and the final “This is very good, I'm surprised!”


You might think that I was just praising the project so that it would seem to everyone that this is very exciting. But in fact, so many responded. It was funny to watch it.

From what I saw how people reacted to Firefox OS, I realized that it would change a lot. Everyone is so excited that, I think, no one needs to explain anything to anyone.

Problems


It would be unfair all the time to praise Firefox OS without mentioning some of the problems that we need to solve.

There are common issues, such as creating an open ecosystem of applications or fragmentation of devices that happens with Android. This is important, but ultimately completely uninteresting to me.

I am most interested in the problem of HTML5 games on mobile devices - perception and performance, which developers often complain about. This problem does not belong solely to Firefox OS (Android and iOS are just as bad at this), but now I'm completely focused on it and on the problem of performance.

Most of the previously created mobile HTML5 games run very slowly (0–20FPS), or slightly faster (20–30FPS). Often, these games have unstable FPS, which significantly impairs the gameplay.

Interestingly, many problems are not necessarily related to device or javascript. There are some heavy games like the Biolab Disaster . This game is excellent even on the same phone for 50 pounds (40-60FPS).

For me, it is clear that sometimes the device and the platform can cause poor performance in games (not as often as some think). We can learn a lot from games that work fine on weak devices. Explore the techniques and techniques that developers used, and tell about them to those who are going to work with HTML5 games for the mobile platform.

I truly believe that heavy HTML5 games can work fine on any device, even the weakest. Why am I so sure? Because people are already doing such games. There are two things that I trust the most in my life ... my eyes.

Not only mobile phones


Most of all, I am excited not about the fact that Firefox OS will be installed on a mobile device, which we will release next year, but about what will happen in the future. I touched on this topic earlier when I talked about the “developer's dream”, how others can expand the boundaries of using the OS.



And this is happening today. We already have Firefox OS ported to Raspberry Pi and Pandaboard . They are not perfect, but what's cool (I tried very hard to avoid that word) is the fact that all this happens long before the first release.

Already have the opportunity to try out Firefox OS on Mac, Windows and Linux . Of course, you will not have access to all the functions that are in the smartphone, but still you can try something (for example, applications running in parallel). The installation of the system is quite simple.

I can only imagine the near day when the Gamepad API will appear in Gecko and will be available on the desktop Firefox OS client. What's the big deal? Well, it's not so difficult to imagine a device connected to a TV set with an operating system configured to work with a gamepad instead of a mouse or a sensor (and this is all JavaScript, remember).

This will be the beginning of the console-era for HTML5 games, and this is what I work on during my “free” time outside of Mozilla.

I want to say that we are approaching the moment when many devices can work on the same technologies that we usually use to create websites. So what can we do with a world full of technology-based devices that can access and share data everywhere using the same API?

I desperately want to see this world!

Translated and published with the permission of the author.

The author will be happy to answer all questions about Firefox OS. Write to this thread .

Useful links:

Source: https://habr.com/ru/post/151548/


All Articles